VEXPRESS: Fix VEXPRESS implicit declarations dependence errors.
PATCH 1/1 VEXPRESS: Fix VEXPRESS implicit declarations dependence errors.
This patch adds a of_find_node_by_phandle() and of_get_next_parent() function declaration dependence on"#ifdef CONFIG_OF" in "include/linux/of.h" else part return inline dummy implementations (returning NULL). Without this patch,build system can lead to issues. This was discovered during randconfig testing,in which VEXPRESS_CONFIG was enabled w/o CONFIG_OF being enabled,leading to the following error:
CC drivers/mfd/vexpress-config.odrivers/mfd/vexpress-config.c: In function ?__vexpress_config_func_get?:drivers/mfd/vexpress-config.c:117:4: error: implicit declaration of function ?of_find_node_by_phandle? [-Werror=implicit-function-declaration]
bridge_node = of_find_node_by_phandle(
^
drivers/mfd/vexpress-config.c:117:16: warning: assignment makes pointer from
integer without a cast [enabled by default]
bridge_node = of_find_node_by_phandle(--- include/linux/of.h | 9 +++++++++ 1 file changed, 9 insertions(+)
include/linux/of.h +9 -0
@@ -340,6 +340,15 @@ int of_device_is_stdout_path(struct device_node *dn);#else /* CONFIG_OF */ +static inline struct device_node *of_find_node_by_phandle (phandle handle) +{ +return NULL ; +} +static inline struct device_node *of_get_next_parent (struct device_node *node) +{ +return NULL ; +} +static inline const char *of_node_full_name (struct device_node *np) {return "<no-node>" ;
Signature · 1 line
1.7.9.5
Quoted 6 lines · Majunath Goudar
This patch adds a
of_find_node_by_phandle()andof_get_next_parent()function declaration dependence on"#ifdefCONFIG_OF" in "include/linux/of.h" else part return inline dummy implementations (returning NULL). Without this patch,build system can lead to issues. This was discovered during randconfig testing,in whichVEXPRESS_CONFIGwas enabled w/oCONFIG_OFbeing enabled,leading to the following error:
What is blocking making VExpress DT only?
The subject should reflect the subsystem you are changing and the description is missing spaces at a minimum.
Rob
Quoted 44 lines
CC
drivers/mfd/vexpress-config.odrivers/mfd/vexpress-config.c: In function ?__vexpress_config_func_get?:drivers/mfd/vexpress-config.c:117:4: error: implicit declaration of function ?of_find_node_by_phandle? [-Werror=implicit-function-declaration]bridge_node = of_find_node_by_phandle( ^ drivers/mfd/vexpress-config.c:117:16: warning: assignment makes pointer from integer without a cast [enabled by default] bridge_node = of_find_node_by_phandle(Signed-off-by Manjunath Goudar <[email protected]>Cc Grant Likely <[email protected]>Cc Rob Herring <[email protected]>Cc Pawel Moll <[email protected]>Cc Samuel Ortiz <[email protected]>Cc Lee Jones <[email protected]>Cc devicetree at vger.kernel.orgCc linux-kernel at vger.kernel.org--- include/linux/of.h | 9 +++++++++ 1 file changed, 9 insertions(+)include/linux/of.h +9
-0@@ -340,6 +340,15 @@ int of_device_is_stdout_path(struct device_node *dn);#else /* CONFIG_OF */ +static inline struct device_node *of_find_node_by_phandle (phandle handle) +{ +return NULL ; +} +static inline struct device_node *of_get_next_parent (struct device_node *node) +{ +return NULL ; +} +static inline const char *of_node_full_name (struct device_node *np) {return "<no-node>" ;
PATCH 1/1 VEXPRESS: Fix VEXPRESS implicit declarations dependence errors.
In reply to Majunath GoudarThis patch adds a inline dummy implementations of_find_node_by_phandle() and of_get_next_parent() in "#ifdef CONFIG_OF" else part. Without this patch,build system can lead to issues. This was discovered during randconfig testing,in which VEXPRESS_CONFIG was enabled w/o CONFIG_OF being enabled,leading to the following error:
CC drivers/mfd/vexpress-config.odrivers/mfd/vexpress-config.c: In function ?__vexpress_config_func_get?:drivers/mfd/vexpress-config.c:117:4: error: implicit declaration of function ?of_find_node_by_phandle? [-Werror=implicit-function-declaration]
bridge_node = of_find_node_by_phandle(
^
drivers/mfd/vexpress-config.c:117:16: warning: assignment makes pointer from
integer without a cast [enabled by default]
bridge_node = of_find_node_by_phandle(--- include/linux/of.h | 9 +++++++++ 1 file changed, 9 insertions(+)
include/linux/of.h +9 -0
@@ -340,6 +340,15 @@ int of_device_is_stdout_path(struct device_node *dn);#else /* CONFIG_OF */ +static inline struct device_node *of_find_node_by_phandle (phandle handle) +{ +return NULL ; +} +static inline struct device_node *of_get_next_parent (struct device_node *node) +{ +return NULL ; +} +static inline const char *of_node_full_name (struct device_node *np) {return "<no-node>" ;
Signature · 1 line
1.7.9.5