diff options
Diffstat (limited to 'drivers/of/base.c')
-rw-r--r-- | drivers/of/base.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/of/base.c b/drivers/of/base.c index aa805250de76..632ebae7f17a 100644 --- a/drivers/of/base.c +++ b/drivers/of/base.c | |||
@@ -33,7 +33,7 @@ DEFINE_RWLOCK(devtree_lock); | |||
33 | 33 | ||
34 | int of_n_addr_cells(struct device_node *np) | 34 | int of_n_addr_cells(struct device_node *np) |
35 | { | 35 | { |
36 | const int *ip; | 36 | const __be32 *ip; |
37 | 37 | ||
38 | do { | 38 | do { |
39 | if (np->parent) | 39 | if (np->parent) |
@@ -49,7 +49,7 @@ EXPORT_SYMBOL(of_n_addr_cells); | |||
49 | 49 | ||
50 | int of_n_size_cells(struct device_node *np) | 50 | int of_n_size_cells(struct device_node *np) |
51 | { | 51 | { |
52 | const int *ip; | 52 | const __be32 *ip; |
53 | 53 | ||
54 | do { | 54 | do { |
55 | if (np->parent) | 55 | if (np->parent) |
@@ -496,6 +496,9 @@ EXPORT_SYMBOL(of_find_node_with_property); | |||
496 | const struct of_device_id *of_match_node(const struct of_device_id *matches, | 496 | const struct of_device_id *of_match_node(const struct of_device_id *matches, |
497 | const struct device_node *node) | 497 | const struct device_node *node) |
498 | { | 498 | { |
499 | if (!matches) | ||
500 | return NULL; | ||
501 | |||
499 | while (matches->name[0] || matches->type[0] || matches->compatible[0]) { | 502 | while (matches->name[0] || matches->type[0] || matches->compatible[0]) { |
500 | int match = 1; | 503 | int match = 1; |
501 | if (matches->name[0]) | 504 | if (matches->name[0]) |