From: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
To: barebox@lists.infradead.org
Subject: [PATCH 1/2] bus_for_each_device/bus_for_each_driver: add () to allow use &bus
Date: Sat, 3 Nov 2012 16:11:04 +0100 [thread overview]
Message-ID: <1351955465-12206-1-git-send-email-plagnioj@jcrosoft.com> (raw)
In-Reply-To: <20121103150823.GY29599@game.jcrosoft.org>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
---
include/driver.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/driver.h b/include/driver.h
index 4918054..dd22c77 100644
--- a/include/driver.h
+++ b/include/driver.h
@@ -393,11 +393,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;
--
1.7.10.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2012-11-03 15:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-03 15:08 [PATCH 0/2 v2] add bus device Jean-Christophe PLAGNIOL-VILLARD
2012-11-03 15:11 ` Jean-Christophe PLAGNIOL-VILLARD [this message]
2012-11-03 15:11 ` [PATCH 2/2] bus: " Jean-Christophe PLAGNIOL-VILLARD
2012-11-15 10:11 ` [PATCH 0/2 v2] " Jean-Christophe PLAGNIOL-VILLARD
2012-11-19 10:36 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1351955465-12206-1-git-send-email-plagnioj@jcrosoft.com \
--to=plagnioj@jcrosoft.com \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox