diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2010-10-30 11:49:09 -0400 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2011-01-01 15:03:25 -0500 |
commit | a4f740cf33f7f6c164bbde3c0cdbcc77b0c4997c (patch) | |
tree | 62d061939000c65d91cf760a51509d388270f4c9 /include/linux/of_fdt.h | |
parent | 73930a85cf38d72851305fcf640c07b4c13aa405 (diff) |
of/flattree: Add of_flat_dt_match() helper function
This patch adds of_flat_dt_match() which tests a node for
compatibility with a list of values and converts the relevant powerpc
platform code to use it. This approach simplifies the board support
code a bit.
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Reviewed-by: Stephen Neuendorffer <stephen.neuendorffer@xilinx.com>
Diffstat (limited to 'include/linux/of_fdt.h')
-rw-r--r-- | include/linux/of_fdt.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/of_fdt.h b/include/linux/of_fdt.h index 9ce5dfd2186a..ee96091f7d25 100644 --- a/include/linux/of_fdt.h +++ b/include/linux/of_fdt.h | |||
@@ -68,6 +68,8 @@ extern void *of_fdt_get_property(struct boot_param_header *blob, | |||
68 | extern int of_fdt_is_compatible(struct boot_param_header *blob, | 68 | extern int of_fdt_is_compatible(struct boot_param_header *blob, |
69 | unsigned long node, | 69 | unsigned long node, |
70 | const char *compat); | 70 | const char *compat); |
71 | extern int of_fdt_match(struct boot_param_header *blob, unsigned long node, | ||
72 | const char **compat); | ||
71 | extern void of_fdt_unflatten_tree(unsigned long *blob, | 73 | extern void of_fdt_unflatten_tree(unsigned long *blob, |
72 | struct device_node **mynodes); | 74 | struct device_node **mynodes); |
73 | 75 | ||
@@ -84,6 +86,7 @@ extern int of_scan_flat_dt(int (*it)(unsigned long node, const char *uname, | |||
84 | extern void *of_get_flat_dt_prop(unsigned long node, const char *name, | 86 | extern void *of_get_flat_dt_prop(unsigned long node, const char *name, |
85 | unsigned long *size); | 87 | unsigned long *size); |
86 | extern int of_flat_dt_is_compatible(unsigned long node, const char *name); | 88 | extern int of_flat_dt_is_compatible(unsigned long node, const char *name); |
89 | extern int of_flat_dt_match(unsigned long node, const char **matches); | ||
87 | extern unsigned long of_get_flat_dt_root(void); | 90 | extern unsigned long of_get_flat_dt_root(void); |
88 | 91 | ||
89 | extern int early_init_dt_scan_chosen(unsigned long node, const char *uname, | 92 | extern int early_init_dt_scan_chosen(unsigned long node, const char *uname, |