9
0
Fork 0

bus_for_each_device/bus_for_each_driver: add () to allow use &bus

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Jean-Christophe PLAGNIOL-VILLARD 2012-11-03 16:11:04 +01:00 committed by Sascha Hauer
parent 543cf11ad4
commit 7ce8a13c26
1 changed files with 2 additions and 2 deletions

View File

@ -408,11 +408,11 @@ extern struct list_head bus_list;
/* Iterate over all devices of a bus
*/
#define bus_for_each_device(bus, dev) list_for_each_entry(dev, &bus->device_list, bus_list)
#define bus_for_each_device(bus, dev) list_for_each_entry(dev, &(bus)->device_list, bus_list)
/* Iterate over all drivers of a bus
*/
#define bus_for_each_driver(bus, drv) list_for_each_entry(drv, &bus->driver_list, bus_list)
#define bus_for_each_driver(bus, drv) list_for_each_entry(drv, &(bus)->driver_list, bus_list)
extern struct bus_type platform_bus;