2015-06-17 06:57:37

by Fengguang Wu

[permalink] [raw]
Subject: [next:master 11893/11947] drivers/leds/leds-aat1290.c:397:21: sparse: symbol 'aat1290_intensity_to_brightness' was not declared. Should it be static?

tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: ca3cfaa9e7db530b14e4a2d98a9310130152fdb8
commit: 1da60a5e7198c716990ac6fa508e45e27e7067c0 [11893/11947] Merge remote-tracking branch 'leds/for-next'
reproduce:
# apt-get install sparse
git checkout 1da60a5e7198c716990ac6fa508e45e27e7067c0
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

drivers/leds/leds-aat1290.c:334:5: sparse: symbol 'init_mm_current_scale' was not declared. Should it be static?
>> drivers/leds/leds-aat1290.c:397:21: sparse: symbol 'aat1290_intensity_to_brightness' was not declared. Should it be static?
>> drivers/leds/leds-aat1290.c:412:5: sparse: symbol 'aat1290_brightness_to_intensity' was not declared. Should it be static?

Please review and possibly fold the followup patch.

---
0-DAY kernel test infrastructure Open Source Technology Center
http://lists.01.org/mailman/listinfo/kbuild Intel Corporation


2015-06-17 06:57:49

by Fengguang Wu

[permalink] [raw]
Subject: [PATCH next] Merge remote-tracking branch 'leds/for-next':: aat1290_intensity_to_brightness() can be static


Signed-off-by: Fengguang Wu <[email protected]>
---
leds-aat1290.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/leds/leds-aat1290.c b/drivers/leds/leds-aat1290.c
index 1ac525b4..fd7c25f 100644
--- a/drivers/leds/leds-aat1290.c
+++ b/drivers/leds/leds-aat1290.c
@@ -394,7 +394,7 @@ static void aat1290_init_flash_timeout(struct aat1290_led *led,
}

#if IS_ENABLED(CONFIG_V4L2_FLASH_LED_CLASS)
-enum led_brightness aat1290_intensity_to_brightness(
+static enum led_brightness aat1290_intensity_to_brightness(
struct v4l2_flash *v4l2_flash,
s32 intensity)
{
@@ -409,7 +409,7 @@ enum led_brightness aat1290_intensity_to_brightness(
return 1;
}

-s32 aat1290_brightness_to_intensity(struct v4l2_flash *v4l2_flash,
+static s32 aat1290_brightness_to_intensity(struct v4l2_flash *v4l2_flash,
enum led_brightness brightness)
{
struct led_classdev_flash *fled_cdev = v4l2_flash->fled_cdev;

2015-06-17 15:22:07

by Jacek Anaszewski

[permalink] [raw]
Subject: Re: [next:master 11893/11947] drivers/leds/leds-aat1290.c:397:21: sparse: symbol 'aat1290_intensity_to_brightness' was not declared. Should it be static?

On 06/17/2015 08:56 AM, kbuild test robot wrote:
> tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
> head: ca3cfaa9e7db530b14e4a2d98a9310130152fdb8
> commit: 1da60a5e7198c716990ac6fa508e45e27e7067c0 [11893/11947] Merge remote-tracking branch 'leds/for-next'
> reproduce:
> # apt-get install sparse
> git checkout 1da60a5e7198c716990ac6fa508e45e27e7067c0
> make ARCH=x86_64 allmodconfig
> make C=1 CF=-D__CHECK_ENDIAN__
>
>
> sparse warnings: (new ones prefixed by >>)
>
> drivers/leds/leds-aat1290.c:334:5: sparse: symbol 'init_mm_current_scale' was not declared. Should it be static?
>>> drivers/leds/leds-aat1290.c:397:21: sparse: symbol 'aat1290_intensity_to_brightness' was not declared. Should it be static?
>>> drivers/leds/leds-aat1290.c:412:5: sparse: symbol 'aat1290_brightness_to_intensity' was not declared. Should it be static?
>
> Please review and possibly fold the followup patch.

These should be statics. I'll send fixed patches tomorrow.

--
Best Regards,
Jacek Anaszewski