[PATCH] powerpc/85xx: Get twr_p102x to compile again

Subsystems: linux for powerpc (32-bit and 64-bit), linux for powerpc embedded ppc85xx, the rest

STALE2398d LANDED

Landed in mainline as 3a9d970f17e0 on 2020-01-06.

3 messages, 3 authors, 2020-01-06 · open the first message on its own page

[PATCH] powerpc/85xx: Get twr_p102x to compile again

From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Date: 2019-12-19 15:18:58

With CONFIG_QUICC_ENGINE enabled and CONFIG_UCC_GETH + CONFIG_SERIAL_QE
disabled we have an unused variable (np). The code won't compile with
-Werror.

Move the np variable to the block where it is actually used.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
 arch/powerpc/platforms/85xx/twr_p102x.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/arch/powerpc/platforms/85xx/twr_p102x.c b/arch/powerpc/platforms/85xx/twr_p102x.c
index 6c3c0cdaee9ad..b301ef9d6ce75 100644
--- a/arch/powerpc/platforms/85xx/twr_p102x.c
+++ b/arch/powerpc/platforms/85xx/twr_p102x.c
@@ -60,10 +60,6 @@ static void __init twr_p1025_pic_init(void)
  */
 static void __init twr_p1025_setup_arch(void)
 {
-#ifdef CONFIG_QUICC_ENGINE
-	struct device_node *np;
-#endif
-
 	if (ppc_md.progress)
 		ppc_md.progress("twr_p1025_setup_arch()", 0);
 
@@ -77,6 +73,7 @@ static void __init twr_p1025_setup_arch(void)
 #if IS_ENABLED(CONFIG_UCC_GETH) || IS_ENABLED(CONFIG_SERIAL_QE)
 	if (machine_is(twr_p1025)) {
 		struct ccsr_guts __iomem *guts;
+		struct device_node *np;
 
 		np = of_find_compatible_node(NULL, NULL, "fsl,p1021-guts");
 		if (np) {
-- 
2.24.0

Re: [PATCH] powerpc/85xx: Get twr_p102x to compile again

From: Scott Wood <oss@buserror.net>
Date: 2019-12-19 23:58:04

On Thu, 2019-12-19 at 16:16 +0100, Sebastian Andrzej Siewior wrote:
With CONFIG_QUICC_ENGINE enabled and CONFIG_UCC_GETH + CONFIG_SERIAL_QE
disabled we have an unused variable (np). The code won't compile with
-Werror.

Move the np variable to the block where it is actually used.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
 arch/powerpc/platforms/85xx/twr_p102x.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
Acked-by: Scott Wood <oss@buserror.net>

-Scott

Re: [PATCH] powerpc/85xx: Get twr_p102x to compile again

From: Michael Ellerman <hidden>
Date: 2020-01-06 23:52:46

On Thu, 2019-12-19 at 15:16:02 UTC, Sebastian Andrzej Siewior wrote:
With CONFIG_QUICC_ENGINE enabled and CONFIG_UCC_GETH + CONFIG_SERIAL_QE
disabled we have an unused variable (np). The code won't compile with
-Werror.

Move the np variable to the block where it is actually used.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/3a9d970f17e05a7b26f782beb8f7f2118d1741ea

cheers
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help