diff options
author | Scott Wood <scottwood@freescale.com> | 2007-08-20 12:36:59 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-08-22 01:21:47 -0400 |
commit | 804ace8881d211ac448082e871dd312132393049 (patch) | |
tree | f1207f6b942cc6cb05ef916152101b3ce07a1a05 /include | |
parent | 12cdac34c6e90d887de23ab9747185731cba254a (diff) |
[POWERPC] Use strcasecmp() rather than strncasecmp() when determining device node compatibility
The current code assumes "foo-bar" must always be compatible with a node
compatible with "foo", which breaks device trees where this is not so.
The "case" part is also wrong according to Open Firmware, but it's more
likely to have drivers and/or device trees depending on it, and thus
needs to be handled more carefully.
Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-powerpc/prom.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/asm-powerpc/prom.h b/include/asm-powerpc/prom.h index 920b75620f74..925e2d384bb3 100644 --- a/include/asm-powerpc/prom.h +++ b/include/asm-powerpc/prom.h | |||
@@ -24,7 +24,7 @@ | |||
24 | #define OF_ROOT_NODE_ADDR_CELLS_DEFAULT 1 | 24 | #define OF_ROOT_NODE_ADDR_CELLS_DEFAULT 1 |
25 | #define OF_ROOT_NODE_SIZE_CELLS_DEFAULT 1 | 25 | #define OF_ROOT_NODE_SIZE_CELLS_DEFAULT 1 |
26 | 26 | ||
27 | #define of_compat_cmp(s1, s2, l) strncasecmp((s1), (s2), (l)) | 27 | #define of_compat_cmp(s1, s2, l) strcasecmp((s1), (s2)) |
28 | #define of_prop_cmp(s1, s2) strcmp((s1), (s2)) | 28 | #define of_prop_cmp(s1, s2) strcmp((s1), (s2)) |
29 | #define of_node_cmp(s1, s2) strcasecmp((s1), (s2)) | 29 | #define of_node_cmp(s1, s2) strcasecmp((s1), (s2)) |
30 | 30 | ||