From: Hauke Mehrtens Date: Sun, 8 Jun 2014 20:52:18 +0000 (+0200) Subject: backports: add of_node_put() X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=59de821df9ea030d6cd878aab371b7429ddee05f;p=openwrt%2Fstaging%2Fblogic.git backports: add of_node_put() Signed-off-by: Hauke Mehrtens --- diff --git a/backport/backport-include/linux/of.h b/backport/backport-include/linux/of.h index c1ce91c518cf..69664de75226 100644 --- a/backport/backport-include/linux/of.h +++ b/backport/backport-include/linux/of.h @@ -94,4 +94,16 @@ static inline int of_property_count_u32_elems(const struct device_node *np, } #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,15,0) */ +#if LINUX_VERSION_CODE < KERNEL_VERSION(3,3,0) +#ifndef CONFIG_OF +#define of_node_get LINUX_BACKPORT(of_node_get) +/* Dummy ref counting routines - to be implemented later */ +static inline struct device_node *of_node_get(struct device_node *node) +{ + return node; +} +static inline void of_node_put(struct device_node *node) { } +#endif /* CONFIG_OF */ +#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,3,0) */ + #endif /* _COMPAT_LINUX_OF_H */