* [PATCH] HID: mcp2221: add gpiolib dependency
@ 2020-04-28 21:30 Arnd Bergmann
2020-04-29 3:11 ` rishi gupta
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Arnd Bergmann @ 2020-04-28 21:30 UTC (permalink / raw)
To: Jiri Kosina, Benjamin Tissoires, Rishi Gupta, Linus Walleij
Cc: Arnd Bergmann, Jiri Kosina, Bastien Nocera, Dmitry Torokhov,
Wolfram Sang, linux-input, linux-kernel
Without gpiolib, this driver fails to link:
arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp2221_probe':
hid-mcp2221.c:(.text+0x1b0): undefined reference to `devm_gpiochip_add_data'
arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp_gpio_get':
hid-mcp2221.c:(.text+0x30c): undefined reference to `gpiochip_get_data'
Fixes: 328de1c519c5 ("HID: mcp2221: add GPIO functionality support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/hid/Kconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
index 008bf44bc2c3..d54e7ae80de5 100644
--- a/drivers/hid/Kconfig
+++ b/drivers/hid/Kconfig
@@ -1155,6 +1155,7 @@ config HID_ALPS
config HID_MCP2221
tristate "Microchip MCP2221 HID USB-to-I2C/SMbus host support"
depends on USB_HID && I2C
+ depends on GPIOLIB
---help---
Provides I2C and SMBUS host adapter functionality over USB-HID
through MCP2221 device.
--
2.26.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] HID: mcp2221: add gpiolib dependency
2020-04-28 21:30 [PATCH] HID: mcp2221: add gpiolib dependency Arnd Bergmann
@ 2020-04-29 3:11 ` rishi gupta
2020-04-29 12:22 ` Linus Walleij
2020-04-29 19:47 ` Jiri Kosina
2 siblings, 0 replies; 4+ messages in thread
From: rishi gupta @ 2020-04-29 3:11 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Jiri Kosina, Benjamin Tissoires, Linus Walleij, Jiri Kosina,
Bastien Nocera, Dmitry Torokhov, Wolfram Sang,
open list:HID CORE LAYER, lkml
Thanks Arnd, How about one liner:
depends on USB_HID && I2C && GPIOLIB
Reviewed-by: Rishi Gupta <gupt21@gmail.com>
On Wed, Apr 29, 2020 at 3:00 AM Arnd Bergmann <arnd@arndb.de> wrote:
>
> Without gpiolib, this driver fails to link:
>
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp2221_probe':
> hid-mcp2221.c:(.text+0x1b0): undefined reference to `devm_gpiochip_add_data'
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp_gpio_get':
> hid-mcp2221.c:(.text+0x30c): undefined reference to `gpiochip_get_data'
>
> Fixes: 328de1c519c5 ("HID: mcp2221: add GPIO functionality support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/hid/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
> index 008bf44bc2c3..d54e7ae80de5 100644
> --- a/drivers/hid/Kconfig
> +++ b/drivers/hid/Kconfig
> @@ -1155,6 +1155,7 @@ config HID_ALPS
> config HID_MCP2221
> tristate "Microchip MCP2221 HID USB-to-I2C/SMbus host support"
> depends on USB_HID && I2C
> + depends on GPIOLIB
> ---help---
> Provides I2C and SMBUS host adapter functionality over USB-HID
> through MCP2221 device.
> --
> 2.26.0
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] HID: mcp2221: add gpiolib dependency
2020-04-28 21:30 [PATCH] HID: mcp2221: add gpiolib dependency Arnd Bergmann
2020-04-29 3:11 ` rishi gupta
@ 2020-04-29 12:22 ` Linus Walleij
2020-04-29 19:47 ` Jiri Kosina
2 siblings, 0 replies; 4+ messages in thread
From: Linus Walleij @ 2020-04-29 12:22 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Jiri Kosina, Benjamin Tissoires, Rishi Gupta, Jiri Kosina,
Bastien Nocera, Dmitry Torokhov, Wolfram Sang, Linux Input,
linux-kernel
On Tue, Apr 28, 2020 at 11:30 PM Arnd Bergmann <arnd@arndb.de> wrote:
> Without gpiolib, this driver fails to link:
>
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp2221_probe':
> hid-mcp2221.c:(.text+0x1b0): undefined reference to `devm_gpiochip_add_data'
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp_gpio_get':
> hid-mcp2221.c:(.text+0x30c): undefined reference to `gpiochip_get_data'
>
> Fixes: 328de1c519c5 ("HID: mcp2221: add GPIO functionality support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
> config HID_MCP2221
> tristate "Microchip MCP2221 HID USB-to-I2C/SMbus host support"
> depends on USB_HID && I2C
> + depends on GPIOLIB
These days we can even do select GPIOLIB, but I suppose
that would make the driver selectable on platforms with no
native GPIO support at all (like UM) so I suppose this
is better.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] HID: mcp2221: add gpiolib dependency
2020-04-28 21:30 [PATCH] HID: mcp2221: add gpiolib dependency Arnd Bergmann
2020-04-29 3:11 ` rishi gupta
2020-04-29 12:22 ` Linus Walleij
@ 2020-04-29 19:47 ` Jiri Kosina
2 siblings, 0 replies; 4+ messages in thread
From: Jiri Kosina @ 2020-04-29 19:47 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Benjamin Tissoires, Rishi Gupta, Linus Walleij, Bastien Nocera,
Dmitry Torokhov, Wolfram Sang, linux-input, linux-kernel
On Tue, 28 Apr 2020, Arnd Bergmann wrote:
> Without gpiolib, this driver fails to link:
>
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp2221_probe':
> hid-mcp2221.c:(.text+0x1b0): undefined reference to `devm_gpiochip_add_data'
> arm-linux-gnueabi-ld: drivers/hid/hid-mcp2221.o: in function `mcp_gpio_get':
> hid-mcp2221.c:(.text+0x30c): undefined reference to `gpiochip_get_data'
>
> Fixes: 328de1c519c5 ("HID: mcp2221: add GPIO functionality support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Applied, thanks Arnd.
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-04-29 19:47 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-28 21:30 [PATCH] HID: mcp2221: add gpiolib dependency Arnd Bergmann
2020-04-29 3:11 ` rishi gupta
2020-04-29 12:22 ` Linus Walleij
2020-04-29 19:47 ` Jiri Kosina
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).