Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=e3855fa5540617877907ca61c36d28e18d0f2473
Commit:     e3855fa5540617877907ca61c36d28e18d0f2473
Parent:     ee51de5645edee4124db6a479d2e135ebe436748
Author:     Michael Ellerman <[EMAIL PROTECTED]>
AuthorDate: Mon Jun 4 23:00:02 2007 +1000
Committer:  Paul Mackerras <[EMAIL PROTECTED]>
CommitDate: Mon Jun 25 17:02:08 2007 +1000

    [POWERPC] Add for_each_compatible_node()
    
    Signed-off-by: Michael Ellerman <[EMAIL PROTECTED]>
    Acked-by: Benjamin Herrenschmidt <[EMAIL PROTECTED]>
    Signed-off-by: Paul Mackerras <[EMAIL PROTECTED]>
---
 include/asm-powerpc/prom.h |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/include/asm-powerpc/prom.h b/include/asm-powerpc/prom.h
index 6845af9..1122a92 100644
--- a/include/asm-powerpc/prom.h
+++ b/include/asm-powerpc/prom.h
@@ -124,6 +124,9 @@ extern struct device_node *of_find_node_by_type(struct 
device_node *from,
             dn = of_find_node_by_type(dn, type))
 extern struct device_node *of_find_compatible_node(struct device_node *from,
        const char *type, const char *compat);
+#define for_each_compatible_node(dn, type, compatible) \
+       for (dn = of_find_compatible_node(NULL, type, compatible); dn; \
+            dn = of_find_compatible_node(dn, type, compatible))
 extern struct device_node *of_find_node_by_path(const char *path);
 extern struct device_node *of_find_node_by_phandle(phandle handle);
 extern struct device_node *of_find_all_nodes(struct device_node *prev);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to