Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1543249 > unrolled thread

[PATCH mac80211-next] rfkill: hide unused goto label

Started byArnd Bergmann <arnd@arndb.de>
First post2016-12-16 09:50 +0100
Last post2016-12-16 10:10 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH mac80211-next] rfkill: hide unused goto label Arnd Bergmann <arnd@arndb.de> - 2016-12-16 09:50 +0100
    Re: [PATCH mac80211-next] rfkill: hide unused goto label Johannes Berg <johannes@sipsolutions.net> - 2016-12-16 10:10 +0100

#1543249 — [PATCH mac80211-next] rfkill: hide unused goto label

FromArnd Bergmann <arnd@arndb.de>
Date2016-12-16 09:50 +0100
Subject[PATCH mac80211-next] rfkill: hide unused goto label
Message-ID<sOWnf-16h-13@gated-at.bofh.it>
A cleanup introduced a harmless warning in some configurations:

net/rfkill/core.c: In function 'rfkill_init':
net/rfkill/core.c:1350:1: warning: label 'error_input' defined but not used [-Wunused-label]

This adds another #ifdef around the label to match that around the
caller.

Fixes: 6124c53edeea ("rfkill: Cleanup error handling in rfkill_init()")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 net/rfkill/core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/rfkill/core.c b/net/rfkill/core.c
index f6b01f3616e5..b7adaee69756 100644
--- a/net/rfkill/core.c
+++ b/net/rfkill/core.c
@@ -1347,8 +1347,10 @@ static int __init rfkill_init(void)
 
 	return 0;
 
+#ifdef CONFIG_RFKILL_INPUT
 error_input:
 	rfkill_any_led_trigger_unregister();
+#endif
 error_led_trigger:
 	misc_deregister(&rfkill_miscdev);
 error_misc:
-- 
2.9.0

[toc] | [next] | [standalone]


#1543274

FromJohannes Berg <johannes@sipsolutions.net>
Date2016-12-16 10:10 +0100
Message-ID<sOWGC-1t7-13@gated-at.bofh.it>
In reply to#1543249
On Fri, 2016-12-16 at 09:44 +0100, Arnd Bergmann wrote:
> A cleanup introduced a harmless warning in some configurations:
> 
> net/rfkill/core.c: In function 'rfkill_init':
> net/rfkill/core.c:1350:1: warning: label 'error_input' defined but
> not used [-Wunused-label]
> 
> This adds another #ifdef around the label to match that around the
> caller.

Applied, thanks.

johannes

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web