TEST EMAIL - PLEASE IGNORE

From: Rahul Tanwar
Date: Tue Mar 16 2021 - 04:50:26 EST


On 15/3/2021 5:44 pm, Rahul Tanwar wrote:
> From: Arnd Bergmann<arnd@xxxxxxxxxx>
> To: Pavel Machek<pavel@xxxxxx>,
> Amireddy Mallikarjuna reddy
> <mallikarjunax.reddy@xxxxxxxxxxxxxxx>
> Cc: Arnd Bergmann<arnd@xxxxxxxx>, Dan Murphy<dmurphy@xxxxxx>,
> linux-leds@xxxxxxxxxxxxxxx,linux-kernel@xxxxxxxxxxxxxxx
> Subject:[PATCH] leds: lgm: fix gpiolib dependency <https://lore.kernel.org/lkml/20210308153052.2353885-1-arnd@xxxxxxxxxx/#r>
> Date: Mon, 8 Mar 2021 16:30:46 +0100
> Message-ID:<20210308153052.2353885-1-arnd@xxxxxxxxxx> (raw <https://lore.kernel.org/lkml/20210308153052.2353885-1-arnd@xxxxxxxxxx/raw>)
>
> From: Arnd Bergmann<arnd@xxxxxxxx>
>
> Without gpiolib, the driver fails to build:
>
> drivers/leds/blink/leds-lgm-sso.c:123:19: error: field has incomplete type 'struct gpio_chip'
> struct gpio_chip chip;
> ^
> include/linux/gpio.h:107:8: note: forward declaration of 'struct gpio_chip'
> struct gpio_chip;
> ^
> drivers/leds/blink/leds-lgm-sso.c:263:3: error: implicit declaration of function 'gpiod_set_value' [-Werror,-Wimplicit-function-declaration]
> gpiod_set_value(led->gpiod, val);
> ^
> drivers/leds/blink/leds-lgm-sso.c:263:3: note: did you mean 'gpio_set_value'?
> include/linux/gpio.h:168:20: note: 'gpio_set_value' declared here
> static inline void gpio_set_value(unsigned gpio, int value)
> ^
> drivers/leds/blink/leds-lgm-sso.c:345:3: error: implicit declaration of function 'gpiod_set_value' [-Werror,-Wimplicit-function-declaration]
> gpiod_set_value(led->gpiod, 1);
> ^
>
> Add the dependency in Kconfig.
>
> Fixes: c3987cd2bca3 ("leds: lgm: Add LED controller driver for LGM SoC")
> Signed-off-by: Arnd Bergmann<arnd@xxxxxxxx>
> ---
> drivers/leds/blink/Kconfig <https://lore.kernel.org/lkml/20210308153052.2353885-1-arnd@xxxxxxxxxx/#Z30drivers:leds:blink:Kconfig> | 1 +
> 1 file changed, 1 insertion(+)
>
> diff
> <https://lore.kernel.org/lkml/20210308153052.2353885-1-arnd@xxxxxxxxxx/#iZ30drivers:leds:blink:Kconfig>
> --git a/drivers/leds/blink/Kconfig b/drivers/leds/blink/Kconfig index
> 265b53476a80..6dedc58c47b3 100644 --- a/drivers/leds/blink/Kconfig +++
> b/drivers/leds/blink/Kconfig @@ -9,6 +9,7 @@ if LEDS_BLINK
> config LEDS_BLINK_LGM
> tristate "LED support for Intel LGM SoC series"
> + depends on GPIOLIB depends on LEDS_CLASS
> depends on MFD_SYSCON
> depends on OF
> --
> 2.29.2
>


Acked-by: Rahul Tanwar <rtanwar@xxxxxxxxxxxxx>