public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] platform/x86: yt2-1380: add CONFIG_EXTCON dependency
@ 2024-05-28 11:59 Arnd Bergmann
  2024-06-03  9:44 ` Hans de Goede
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2024-05-28 11:59 UTC (permalink / raw)
  To: Hans de Goede, Ilpo Järvinen
  Cc: Arnd Bergmann, Armin Wolf, SungHwan Jung, Henning Schild, Ai Chao,
	Robert Joslyn, Heiner Kallweit, platform-driver-x86, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

This driver uses the extcon subsystem and fails to build
when it cannot call into that subsystem:

x86_64-linux-ld: vmlinux.o: in function `yt2_1380_fc_worker':
lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9d819): undefined reference to `extcon_get_state'
x86_64-linux-ld: lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9d853): undefined reference to `extcon_get_state'
x86_64-linux-ld: vmlinux.o: in function `yt2_1380_fc_serdev_probe':
lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9da22): undefined reference to `extcon_get_extcon_dev'
x86_64-linux-ld: lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9dc0c): undefined reference to `devm_extcon_register_notifier_all'

Add a Kconfig dependency to make it it always builds correctly.

Fixes: b2ed33e8d486 ("platform/x86: Add lenovo-yoga-tab2-pro-1380-fastcharger driver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/platform/x86/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig
index 809888e4c1e7..9f850e4617bf 100644
--- a/drivers/platform/x86/Kconfig
+++ b/drivers/platform/x86/Kconfig
@@ -136,6 +136,7 @@ config YOGABOOK
 config YT2_1380
 	tristate "Lenovo Yoga Tablet 2 1380 fast charge driver"
 	depends on SERIAL_DEV_BUS
+	depends on EXTCON
 	depends on ACPI
 	help
 	  Say Y here to enable support for the custom fast charging protocol
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] platform/x86: yt2-1380: add CONFIG_EXTCON dependency
  2024-05-28 11:59 [PATCH] platform/x86: yt2-1380: add CONFIG_EXTCON dependency Arnd Bergmann
@ 2024-06-03  9:44 ` Hans de Goede
  0 siblings, 0 replies; 2+ messages in thread
From: Hans de Goede @ 2024-06-03  9:44 UTC (permalink / raw)
  To: Arnd Bergmann, Ilpo Järvinen
  Cc: Arnd Bergmann, Armin Wolf, SungHwan Jung, Henning Schild, Ai Chao,
	Robert Joslyn, Heiner Kallweit, platform-driver-x86, linux-kernel

Hi,

On 5/28/24 1:59 PM, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> This driver uses the extcon subsystem and fails to build
> when it cannot call into that subsystem:
> 
> x86_64-linux-ld: vmlinux.o: in function `yt2_1380_fc_worker':
> lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9d819): undefined reference to `extcon_get_state'
> x86_64-linux-ld: lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9d853): undefined reference to `extcon_get_state'
> x86_64-linux-ld: vmlinux.o: in function `yt2_1380_fc_serdev_probe':
> lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9da22): undefined reference to `extcon_get_extcon_dev'
> x86_64-linux-ld: lenovo-yoga-tab2-pro-1380-fastcharger.c:(.text+0xa9dc0c): undefined reference to `devm_extcon_register_notifier_all'
> 
> Add a Kconfig dependency to make it it always builds correctly.
> 
> Fixes: b2ed33e8d486 ("platform/x86: Add lenovo-yoga-tab2-pro-1380-fastcharger driver")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Thank you for your patch, I've applied this patch to my review-hans 
branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=review-hans

Note it will show up in my review-hans branch once I've pushed my
local branch there, which might take a while.

I will include this patch in my next fixes pull-req to Linus
for the current kernel development cycle.

Regards,

Hans




> ---
>  drivers/platform/x86/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig
> index 809888e4c1e7..9f850e4617bf 100644
> --- a/drivers/platform/x86/Kconfig
> +++ b/drivers/platform/x86/Kconfig
> @@ -136,6 +136,7 @@ config YOGABOOK
>  config YT2_1380
>  	tristate "Lenovo Yoga Tablet 2 1380 fast charge driver"
>  	depends on SERIAL_DEV_BUS
> +	depends on EXTCON
>  	depends on ACPI
>  	help
>  	  Say Y here to enable support for the custom fast charging protocol


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-06-03  9:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-28 11:59 [PATCH] platform/x86: yt2-1380: add CONFIG_EXTCON dependency Arnd Bergmann
2024-06-03  9:44 ` Hans de Goede

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox