mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] parent fixups
@ 2011-08-15  8:46 Sascha Hauer
  2011-08-15  8:46 ` [PATCH 1/7] mci: embed mci_dev into mci_host instead of allocating it seperately Sascha Hauer
                   ` (11 more replies)
  0 siblings, 12 replies; 19+ messages in thread
From: Sascha Hauer @ 2011-08-15  8:46 UTC (permalink / raw)
  To: barebox

Hi,

We have a nice devinfo command which can print the devices as a tree.
Let's make more use of it and make spi/network/console devices children
of the corresponding hardware devices.
Also, when a file under /dev/ is associated to a device, print the
start and end with the information.

On a i.MX51 babbage board we change from:

devices:
|----imx_serial0
|----cs0
|----mem0 (ram0)
|----imx_iim0 (imx_iim_bank0, imx_iim_bank1, imx_iim_bank2, imx_iim_bank3, imx_iim_bank4, imx_iim_bank5, imx_iim_bank6, imx_iim_bank7)
|----ramfs0
|----devfs0
|----mem1 (defaultenv)
|----mem2 (mem)
|----fec_imx0
|----miidev0 (phy0)
|----eth0
|----imx-esdhc0
|----mci0
|----disk0
|----imx_spi0
|----mc13892-spi0 (mc13892)

to this:

devices:
`---- imx_serial0
     `---- cs0
`---- mem0
     `---- 0x00000000-0x1fffffff: /dev/ram0
`---- imx_iim0
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank0
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank1
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank2
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank3
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank4
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank5
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank6
     `---- 0x00000000-0x0000001f: /dev/imx_iim_bank7
`---- ramfs0
`---- devfs0
`---- mem1
     `---- 0x00000000-0x00001e08: /dev/defaultenv
`---- mem2
     `---- 0x00000000-0xfffffffe: /dev/mem
`---- fec_imx0
     `---- miidev0
          `---- 0x00000000-0x0000003f: /dev/phy0
     `---- eth0
`---- imx-esdhc0
     `---- mci0
          `---- disk0
`---- imx_spi0
     `---- mc13892-spi0
          `---- 0x00000000-0x000000ff: /dev/mc13892


Sascha Hauer (7):
      mci: embed mci_dev into mci_host instead of allocating it seperately
      net: make the ethernet device a child of the hardware device
      net mii: add a parent pointer to miidevs and set it to the hardware device
      console: make console device a child of the hardware device
      mci: parent fixups
      spi: make the spi devices children of the parent bus
      devinfo: beautify output

 common/console.c           |    2 ++
 drivers/base/driver.c      |   27 ++++++++++++++-------------
 drivers/mci/atmel_mci.c    |    1 +
 drivers/mci/imx-esdhc.c    |    1 +
 drivers/mci/imx.c          |    1 +
 drivers/mci/mci-core.c     |    9 +++++----
 drivers/mci/omap_hsmmc.c   |    1 +
 drivers/net/altera_tse.c   |    2 ++
 drivers/net/at91_ether.c   |    1 +
 drivers/net/cs8900.c       |    1 +
 drivers/net/dm9000.c       |    2 ++
 drivers/net/ep93xx.c       |    2 ++
 drivers/net/fec_imx.c      |    2 ++
 drivers/net/fec_mpc5200.c  |    2 ++
 drivers/net/macb.c         |    2 ++
 drivers/net/miidev.c       |    2 ++
 drivers/net/netx_eth.c     |    2 ++
 drivers/net/smc91111.c     |    2 ++
 drivers/net/smc911x.c      |    2 ++
 drivers/net/usb/asix.c     |    1 +
 drivers/net/usb/smsc95xx.c |    1 +
 drivers/net/usb/usbnet.c   |    1 +
 drivers/spi/spi.c          |    1 +
 include/mci.h              |    1 +
 include/miidev.h           |    1 +
 include/net.h              |    1 +
 net/eth.c                  |    4 ++++
 27 files changed, 58 insertions(+), 17 deletions(-)

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2011-08-18  6:46 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-15  8:46 [PATCH] parent fixups Sascha Hauer
2011-08-15  8:46 ` [PATCH 1/7] mci: embed mci_dev into mci_host instead of allocating it seperately Sascha Hauer
2011-08-15  8:46 ` [PATCH 2/7] net: make the ethernet device a child of the hardware device Sascha Hauer
2011-08-15  8:46 ` [PATCH 3/7] net mii: add a parent pointer to miidevs and set it to " Sascha Hauer
2011-08-15  8:46 ` [PATCH 4/7] console: make console device a child of " Sascha Hauer
2011-08-15  8:46 ` [PATCH 5/7] mci: parent fixups Sascha Hauer
2011-08-16 15:39   ` Jean-Christophe PLAGNIOL-VILLARD
2011-08-15  8:46 ` [PATCH 6/7] spi: make the spi devices children of the parent bus Sascha Hauer
2011-08-15  8:46 ` [PATCH 7/7] devinfo: beautify output Sascha Hauer
2011-08-15  9:14 ` [PATCH] parent fixups Jean-Christophe PLAGNIOL-VILLARD
2011-08-15 15:50   ` Sascha Hauer
2011-08-16  5:29     ` Jean-Christophe PLAGNIOL-VILLARD
2011-08-16  5:36 ` [PATCH 1/4] device: update id support to allow device without id Jean-Christophe PLAGNIOL-VILLARD
2011-08-18  5:26   ` Sascha Hauer
2011-08-18  6:27     ` Jean-Christophe PLAGNIOL-VILLARD
2011-08-16  5:36 ` [PATCH 2/4] add bus registration support Jean-Christophe PLAGNIOL-VILLARD
2011-08-18  5:14   ` Sascha Hauer
2011-08-16  5:36 ` [PATCH 3/4] platform_bus: add registrattion to bus Jean-Christophe PLAGNIOL-VILLARD
2011-08-16  5:36 ` [PATCH 4/4] switch all device/driver to platform_device/driver_(un)register Jean-Christophe PLAGNIOL-VILLARD

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox