aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/of
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2011-12-12 11:26:00 -0500
committerGrant Likely <grant.likely@secretlab.ca>2011-12-12 16:41:45 -0500
commitf88e1ae8acb8affac29034ed79d4fff95ac8c29d (patch)
tree9cf86d756358df4b48dfd09b8c8820a887077a71 /drivers/of
parentdc47ce90c3a822cd7c9e9339fe4d5f61dcb26b50 (diff)
dt/device: Fix auxdata matching to handle entries without a name override
There is no requirement to override name entries in auxdata. Fix the entry matching to use .compatible instead of .name to find the end of the list. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/of')
-rw-r--r--drivers/of/platform.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/of/platform.c b/drivers/of/platform.c
index cbd5d701c7e0..63b3ec48c203 100644
--- a/drivers/of/platform.c
+++ b/drivers/of/platform.c
@@ -314,7 +314,7 @@ static const struct of_dev_auxdata *of_dev_lookup(const struct of_dev_auxdata *l
314 if (!lookup) 314 if (!lookup)
315 return NULL; 315 return NULL;
316 316
317 for(; lookup->name != NULL; lookup++) { 317 for(; lookup->compatible != NULL; lookup++) {
318 if (!of_device_is_compatible(np, lookup->compatible)) 318 if (!of_device_is_compatible(np, lookup->compatible))
319 continue; 319 continue;
320 if (of_address_to_resource(np, 0, &res)) 320 if (of_address_to_resource(np, 0, &res))