On Wed, Sep 19, 2012 at 03:39:57PM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote: > This will allow reduce the number of driver and device to search on. > > Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@xxxxxxxxxxxx> > --- > drivers/base/driver.c | 9 +++++---- > include/driver.h | 12 ++++++++++++ > 2 files changed, 17 insertions(+), 4 deletions(-) > [...] > > +/* Iterate over all devices of a bus > + */ > +#define for_each_bus_device(bus, dev) list_for_each_entry(dev, &bus->device_list, list) > + > +/* Iterate over all drivers of a bus > + */ > +#define for_each_bus_driver(bus, drv) list_for_each_entry(drv, &bus->driver_list, list) > + bus_for_each_* please. Sascha -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox