[patch 4/5] sparse: leds-h1940.c: make non-exported symbols static

From: Ben Dooks
Date: Sat Jun 07 2008 - 11:37:27 EST


We do not need to export any of the routines inside
drivers/leds/leds-h1940.c, so make them all static to
quieten the sparse output for this driver.

Fixes the following sparse errors:
drivers/leds/leds-h1940.c:26:6: warning: symbol 'h1940_greenled_set' was not declared. Should it be static?
drivers/leds/leds-h1940.c:55:6: warning: symbol 'h1940_redled_set' was not declared. Should it be static?
drivers/leds/leds-h1940.c:85:6: warning: symbol 'h1940_blueled_set' was not declared. Should it be static?

CC: Richard Purdie <rpurdie@xxxxxxxxx>
CC: Linux Kernel <linux-kernel@xxxxxxxxxxxxxxx>
CC: Arnaud Patard <arnaud.patard@xxxxxxxxxxx>
Signed-off-by: Ben Dooks <ben-linux@xxxxxxxxx>

Index: linux-2.6.26-rc5/drivers/leds/leds-h1940.c
===================================================================
--- linux-2.6.26-rc5.orig/drivers/leds/leds-h1940.c 2008-06-07 16:12:19.000000000 +0100
+++ linux-2.6.26-rc5/drivers/leds/leds-h1940.c 2008-06-07 16:13:18.000000000 +0100
@@ -23,7 +23,8 @@
/*
* Green led.
*/
-void h1940_greenled_set(struct led_classdev *led_dev, enum led_brightness value)
+static void h1940_greenled_set(struct led_classdev *led_dev,
+ enum led_brightness value)
{
switch (value) {
case LED_HALF:
@@ -52,7 +53,8 @@ static struct led_classdev h1940_greenle
/*
* Red led.
*/
-void h1940_redled_set(struct led_classdev *led_dev, enum led_brightness value)
+static void h1940_redled_set(struct led_classdev *led_dev,
+ enum led_brightness value)
{
switch (value) {
case LED_HALF:
@@ -82,7 +84,8 @@ static struct led_classdev h1940_redled
* Blue led.
* (it can only be blue flashing led)
*/
-void h1940_blueled_set(struct led_classdev *led_dev, enum led_brightness value)
+static void h1940_blueled_set(struct led_classdev *led_dev,
+ enum led_brightness value)
{
if (value) {
/* flashing Blue */

--
Ben (ben@xxxxxxxxx, http://www.fluff.org/)

'a smiley only costs 4 bytes'
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/