Re: [PATCH 2/2] driver: search device and driver based on the bus instead of all

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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


[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux