Skip to contentSkip to conversation

x86: apuv2: remove unused variable

PATCH In review Arnd Bergmann 3 participants 4 messages Mar 4, 2019 – Mar 8, 2019

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

PATCH 1/3 x86: apuv2: remove unused variable

The driver was newly introduced but the version that got merged produces a harmless compiler warning:

drivers/platform/x86/pcengines-apuv2.c: In function 'apu_board_init':
drivers/platform/x86/pcengines-apuv2.c:211:6: error: unused variable 'rc' [-Werror=unused-variable]

Remove the evidently useless variable.

Fixes f8eb0235f659 ("x86: pcengines apuv2 gpio/leds/keys platform driver")
---
 drivers/platform/x86/pcengines-apuv2.c | 1 -
 1 file changed, 1 deletion(-)
drivers/platform/x86/pcengines-apuv2.c +0 -1
index dcb084f6b892..c1ca931e1fab 100644
@@ -208,7 +208,6 @@ static struct platform_device * __init apu_create_pdev(
 
 static int __init apu_board_init(void)
 {
-	int rc;
 	const struct dmi_system_id *id;
 
 	id = dmi_first_match(apu_gpio_dmi_table);
Signature · 1 line
2.20.0
#1 lore raw
Quoted 10 lines · Arnd Bergmann

The driver was newly introduced but the version that got merged produces a harmless compiler warning:

drivers/platform/x86/pcengines-apuv2.c: In function 'apu_board_init':
drivers/platform/x86/pcengines-apuv2.c:211:6: error: unused variable 'rc' [-Werror=unused-variable]

Remove the evidently useless variable.

Fixes f8eb0235f659 ("x86: pcengines apuv2 gpio/leds/keys platform driver")

As Torvalds did not yet pull the GPIO tree (maybe because of this and other bugs, who knows) I applied this to my GPIO tree for now.

Yours,
Linus Walleij

#2 lore raw
Quoted 3 lines · Linus Walleij

As Torvalds did not yet pull the GPIO tree (maybe because of this and other bugs, who knows) I applied this to my GPIO tree for now.

Great. I actually like it better this way, so his pull will be clean and consistent.

Did you also apply the kconfig fixes ?

--mtx

Signature · 3 lines
Enrico Weigelt, metux IT consult
Free software and Linux embedded engineering
[email protected] -- +49-151-27565287
#3 lore raw
Quoted 10 lines · metux IT consult
Quoted 3 lines · Linus Walleij

As Torvalds did not yet pull the GPIO tree (maybe because of this and other bugs, who knows) I applied this to my GPIO tree for now.

Great. I actually like it better this way, so his pull will be clean and consistent.

Did you also apply the kconfig fixes ?

Yep!

Yours,
Linus Walleij