diff mbox series

[V2,RESEND] input: adp5589: Initialize GPIO controller parent device

Message ID 20190709135558.4542-1-alexandru.ardelean@analog.com (mailing list archive)
State Mainlined
Commit b8374b85529d9fb974be80c0809c070398aa8cb2
Headers show
Series [V2,RESEND] input: adp5589: Initialize GPIO controller parent device | expand

Commit Message

Alexandru Ardelean July 9, 2019, 1:55 p.m. UTC
From: Lars-Peter Clausen <lars@metafoo.de>

While not strictly required for normal operation setting the GPIO parent
device allows the GPIO framework to generate more verbose debug output for
the GPIO chip.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
---
 drivers/input/keyboard/adp5589-keys.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Dmitry Torokhov July 14, 2019, 9:30 p.m. UTC | #1
On Tue, Jul 09, 2019 at 04:55:58PM +0300, Alexandru Ardelean wrote:
> From: Lars-Peter Clausen <lars@metafoo.de>
> 
> While not strictly required for normal operation setting the GPIO parent
> device allows the GPIO framework to generate more verbose debug output for
> the GPIO chip.
> 
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>

Applied, thank you.

> ---
>  drivers/input/keyboard/adp5589-keys.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/input/keyboard/adp5589-keys.c b/drivers/input/keyboard/adp5589-keys.c
> index 4c05c70a8cf3..4f96a4a99e5b 100644
> --- a/drivers/input/keyboard/adp5589-keys.c
> +++ b/drivers/input/keyboard/adp5589-keys.c
> @@ -505,6 +505,7 @@ static int adp5589_gpio_add(struct adp5589_kpad *kpad)
>  	if (!gpio_data)
>  		return 0;
>  
> +	kpad->gc.parent = dev;
>  	kpad->gc.ngpio = adp5589_build_gpiomap(kpad, pdata);
>  	if (kpad->gc.ngpio == 0) {
>  		dev_info(dev, "No unused gpios left to export\n");
> -- 
> 2.20.1
>
diff mbox series

Patch

diff --git a/drivers/input/keyboard/adp5589-keys.c b/drivers/input/keyboard/adp5589-keys.c
index 4c05c70a8cf3..4f96a4a99e5b 100644
--- a/drivers/input/keyboard/adp5589-keys.c
+++ b/drivers/input/keyboard/adp5589-keys.c
@@ -505,6 +505,7 @@  static int adp5589_gpio_add(struct adp5589_kpad *kpad)
 	if (!gpio_data)
 		return 0;
 
+	kpad->gc.parent = dev;
 	kpad->gc.ngpio = adp5589_build_gpiomap(kpad, pdata);
 	if (kpad->gc.ngpio == 0) {
 		dev_info(dev, "No unused gpios left to export\n");