lkml.org 
[lkml]   [2011]   [May]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 2/3] ARM: mxs: add gpio-mxs platform devices
Date
On Friday 27 May 2011, Shawn Guo wrote:
> On Fri, May 20, 2011 at 04:23:40PM +0200, Arnd Bergmann wrote:
> [...]
> > No, this would put all gpio devices below the top-level /sys/devices/platform
> > directory, where they certainly don't belong. Please find a proper
> > place and put them there.
> >
> To make it clear, which one is the best to have all gpio devices below?
>
> * /sys/devices/platform/gpio-mxs
> * /sys/devices/platform/mxs
> * /sys/devices/platform/mxs/gpio

I would say the third one is closes to how it should be.

The (sysfs) device tree, like the of device tree, should ideally be
modeled after the high-level block diagram of the machine.

In case of i.MX23, that could look like

/sys/devices/system \
/ahb
/apbh
/gpio0
/gpio1
/gpmi
/usb0
/apbx
/i2c
/uart0
/pwm
/spi
/mmc
/ethernet
/usb
/rtc
/...


You can argue on whether it makes sense to include the top level, or if you
also want to model the various levels of ahb buses, so there is some freedom
here.

Arnd


\
 
 \ /
  Last update: 2011-05-27 13:13    [W:0.050 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site