From: Jacek Anaszewski Date: Fri, 8 Aug 2014 07:09:44 +0000 (-0700) Subject: leds: lp3944: fix sparse warning X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=7f14e6b9c36f6696eb937bc0cf86a7732aa89904;p=linux-beck.git leds: lp3944: fix sparse warning Fix sparse warning appeared after changing brightness type in the leds.h from int to enum led_brightness. Signed-off-by: Jacek Anaszewski Acked-by: Kyungmin Park Cc: Richard Purdie Signed-off-by: Bryan Wu --- diff --git a/drivers/leds/leds-lp3944.c b/drivers/leds/leds-lp3944.c index 8e1abdcd4c9d..53144fb96167 100644 --- a/drivers/leds/leds-lp3944.c +++ b/drivers/leds/leds-lp3944.c @@ -335,7 +335,8 @@ static int lp3944_configure(struct i2c_client *client, } /* to expose the default value to userspace */ - led->ldev.brightness = led->status; + led->ldev.brightness = + (enum led_brightness) led->status; /* Set the default led status */ err = lp3944_led_set(led, led->status);