Skip to contentSkip to conversation

ARM: s3c64xx: avoid warning about 'struct device_node'

PATCH In review Arnd Bergmann 2 participants 5 messages Jun 27, 2016 – Jul 14, 2016

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: s3c64xx: avoid warning about 'struct device_node'

The change to simplify of_platform_populate() had an unintended side-effect of introducing a build warning on s3c64xx:

In file included from arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c:18:0:
arch/arm/mach-s3c64xx/common.h:27:30: error: 'struct device_node' declared inside parameter list will not be visible outside of this definition or declaration [-Werror]

This adds a forward-declaration for the structure name in the header to avoid the warning.

Fixes 850bea2335e4 ("arm: Remove unnecessary of_platform_populate with default match table")

---
Rob, can you apply this on top of the devicetree git so we don't have to coordinate the merges?

---
 arch/arm/mach-s3c64xx/common.h | 1 +
 1 file changed, 1 insertion(+)
arch/arm/mach-s3c64xx/common.h +1 -0
index 9eb864412911..4f204668f00e 100644
@@ -24,6 +24,7 @@ void s3c64xx_init_io(struct map_desc *mach_desc, int size);
 
 void s3c64xx_restart(enum reboot_mode mode, const char *cmd);
 
+struct device_node;
 void s3c64xx_clk_init(struct device_node *np, unsigned long xtal_f,
 	unsigned long xusbxti_f, bool is_s3c6400, void __iomem *reg_base);
 void s3c64xx_set_xtal_freq(unsigned long freq);
Signature · 1 line
2.9.0
Acked-by on v1 1/1
#1 lore raw
Quoted 6 lines · Arnd Bergmann

The change to simplify of_platform_populate() had an unintended side-effect of introducing a build warning on s3c64xx:

In file included from arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c:18:0:
arch/arm/mach-s3c64xx/common.h:27:30: error: 'struct device_node' declared inside parameter list will not be visible outside of this definition or declaration [-Werror]

Quoted 8 lines

This adds a forward-declaration for the structure name in the header to avoid the warning.

Fixes 850bea2335e4 ("arm: Remove unnecessary of_platform_populate with default match table")

---
Rob, can you apply this on top of the devicetree git so we don't have to coordinate the merges?

BR,
Krzysztof

#2 lore raw
Quoted 10 lines · CEST Krzysztof Kozlowski
Quoted 9 lines · Arnd Bergmann

The change to simplify of_platform_populate() had an unintended side-effect of introducing a build warning on s3c64xx:

In file included from arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c:18:0:
arch/arm/mach-s3c64xx/common.h:27:30: error: 'struct device_node' declared inside parameter list will not be visible outside of this definition or declaration [-Werror]

This adds a forward-declaration for the structure name in the header to avoid the warning.

Quoted 7 lines
Quoted 5 lines
Fixes 850bea2335e4 ("arm: Remove unnecessary of_platform_populate with default match table")

---
Rob, can you apply this on top of the devicetree git so we don't have to coordinate the merges?

Hi Rob,

I still get the warning in every linux-next build, do you plan to pick up the fix for the commit you merged, or should I try to work around it in arm-soc and leave this as a bisection problem?

Arnd

#3 lore raw
Quoted 17 lines · CEST Arnd Bergmann
Quoted 16 lines · CEST Krzysztof Kozlowski
Quoted 14 lines · Arnd Bergmann

The change to simplify of_platform_populate() had an unintended side-effect of introducing a build warning on s3c64xx:

In file included from arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c:18:0:
arch/arm/mach-s3c64xx/common.h:27:30: error: 'struct device_node' declared inside parameter list will not be visible outside of this definition or declaration [-Werror]

This adds a forward-declaration for the structure name in the header to avoid the warning.

Fixes 850bea2335e4 ("arm: Remove unnecessary of_platform_populate with default match table")

---
Rob, can you apply this on top of the devicetree git so we don't have to coordinate the merges?

Quoted 8 lines
Quoted 1 line

Hi Rob,

I still get the warning in every linux-next build, do you plan to pick up the fix for the commit you merged, or should I try to work around it in arm-soc and leave this as a bisection problem?

Now with Rob back on Cc.

Arnd

#4 lore raw
Quoted 20 lines · CEST Arnd Bergmann
Quoted 19 lines · CEST Arnd Bergmann
Quoted 17 lines · CEST Krzysztof Kozlowski
Quoted 6 lines · Arnd Bergmann

The change to simplify of_platform_populate() had an unintended side-effect of introducing a build warning on s3c64xx:

In file included from arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c:18:0:
arch/arm/mach-s3c64xx/common.h:27:30: error: 'struct device_node' declared inside parameter list will not be visible outside of this definition or declaration [-Werror]

Quoted 8 lines

This adds a forward-declaration for the structure name in the header to avoid the warning.

Fixes 850bea2335e4 ("arm: Remove unnecessary of_platform_populate with default match table")

---
Rob, can you apply this on top of the devicetree git so we don't have to coordinate the merges?

Quoted 8 lines
Quoted 6 lines

Hi Rob,

I still get the warning in every linux-next build, do you plan to pick up the fix for the commit you merged, or should I try to work around it in arm-soc and leave this as a bisection problem?

Now with Rob back on Cc.

I've applied it to arm-soc/next/cleanup now, so we can avoid the warning in linux-next and in 4.8, though it is still present in the devicetree git.

Arnd