Patchwork [1/1] net: rfkill: Fix sparse warning in rfkill-regulator.c

login
register
mail settings
Submitter Sachin Kamat
Date Feb. 19, 2013, 9:57 a.m.
Message ID <1361267868-2316-1-git-send-email-sachin.kamat@linaro.org>
Download mbox | patch
Permalink /patch/221653/
State Not Applicable
Delegated to: David Miller
Headers show

Comments

Sachin Kamat - Feb. 19, 2013, 9:57 a.m.
'rfkill_regulator_ops' is used only in this file. Hence make it static.
Silences the following warning:
net/rfkill/rfkill-regulator.c:54:19: warning:
symbol 'rfkill_regulator_ops' was not declared. Should it be static?

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 net/rfkill/rfkill-regulator.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Johannes Berg - Feb. 20, 2013, 10:08 a.m.
On Tue, 2013-02-19 at 15:27 +0530, Sachin Kamat wrote:
> 'rfkill_regulator_ops' is used only in this file. Hence make it static.
> Silences the following warning:
> net/rfkill/rfkill-regulator.c:54:19: warning:
> symbol 'rfkill_regulator_ops' was not declared. Should it be static?

I'll take this, but it isn't going anywhere until the merge window opens
again.

johannes

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Johannes Berg - Feb. 20, 2013, 10:09 a.m.
On Wed, 2013-02-20 at 11:08 +0100, Johannes Berg wrote:
> On Tue, 2013-02-19 at 15:27 +0530, Sachin Kamat wrote:
> > 'rfkill_regulator_ops' is used only in this file. Hence make it static.
> > Silences the following warning:
> > net/rfkill/rfkill-regulator.c:54:19: warning:
> > symbol 'rfkill_regulator_ops' was not declared. Should it be static?
> 
> I'll take this, but it isn't going anywhere until the merge window opens
> again.

Err, I mean closes, and we open -next.

johannes

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/net/rfkill/rfkill-regulator.c b/net/rfkill/rfkill-regulator.c
index 4b5ab21..d11ac79 100644
--- a/net/rfkill/rfkill-regulator.c
+++ b/net/rfkill/rfkill-regulator.c
@@ -51,7 +51,7 @@  static int rfkill_regulator_set_block(void *data, bool blocked)
 	return 0;
 }
 
-struct rfkill_ops rfkill_regulator_ops = {
+static struct rfkill_ops rfkill_regulator_ops = {
 	.set_block = rfkill_regulator_set_block,
 };