for_each_compatible_node() is defined in a CONFIG_OF condition on older kernel versions. Now some drivers are use it when CONFIG_OF is not set, add it always when it is not already there. Signed-off-by: Hauke Mehrtens <hauke@xxxxxxxxxx> --- backport/backport-include/linux/of.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/backport/backport-include/linux/of.h b/backport/backport-include/linux/of.h index f2a8ab4..6d0be53 100644 --- a/backport/backport-include/linux/of.h +++ b/backport/backport-include/linux/of.h @@ -114,4 +114,10 @@ static inline void of_node_put(struct device_node *node) { } #endif /* CONFIG_OF */ #endif /* of_match_ptr */ +#ifndef for_each_compatible_node +#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)) +#endif /* for_each_compatible_node */ + #endif /* _COMPAT_LINUX_OF_H */ -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe backports" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html