Skip to contentSkip to conversation

platform/x86: int3472/discrete: add LEDS_CLASS dependency

PATCH In review Arnd Bergmann 3 participants 3 messages Feb 8, 2023 – Feb 10, 2023

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 platform/x86: int3472/discrete: add LEDS_CLASS dependency

From: Arnd Bergmann <[email protected]>

int3472 now fails to link when the LED support is disabled:

x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_register_pled':
led.c:(.text+0xf4): undefined reference to `led_classdev_register_ext'
x86_64-linux-ld: led.c:(.text+0x131): undefined reference to `led_add_lookup'
x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_unregister_pled':
led.c:(.text+0x16b): undefined reference to `led_remove_lookup'
x86_64-linux-ld: led.c:(.text+0x177): undefined reference to `led_classdev_unregister'

Add an explicit Kconfig dependency.

Fixes 5ae20a8050d0 ("platform/x86: int3472/discrete: Create a LED class device for the privacy LED")
---
 drivers/platform/x86/intel/int3472/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/platform/x86/intel/int3472/Kconfig +1 -0
index 62e5d4cf9ee5..17ae997f93ea 100644
@@ -4,6 +4,7 @@ config INTEL_SKL_INT3472
 	depends on COMMON_CLK
 	depends on I2C
 	depends on GPIOLIB
+	depends on LEDS_CLASS
 	depends on REGULATOR
 	select MFD_CORE
 	select REGMAP_I2C
Signature · 1 line
2.39.1
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 11 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

int3472 now fails to link when the LED support is disabled:

x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_register_pled':
led.c:(.text+0xf4): undefined reference to `led_classdev_register_ext'
x86_64-linux-ld: led.c:(.text+0x131): undefined reference to `led_add_lookup'
x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_unregister_pled':
led.c:(.text+0x16b): undefined reference to `led_remove_lookup'
x86_64-linux-ld: led.c:(.text+0x177): undefined reference to `led_classdev_unregister'

Quoted 4 lines

Add an explicit Kconfig dependency.

Fixes 5ae20a8050d0 ("platform/x86: int3472/discrete: Create a LED class device for the privacy LED")
Signature · 1 line
Sakari Ailus
#2 lore raw
In reply to Arnd Bergmann

Hi,

Quoted 11 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

int3472 now fails to link when the LED support is disabled:

x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_register_pled':
led.c:(.text+0xf4): undefined reference to `led_classdev_register_ext'
x86_64-linux-ld: led.c:(.text+0x131): undefined reference to `led_add_lookup'
x86_64-linux-ld: drivers/platform/x86/intel/int3472/led.o: in function `skl_int3472_unregister_pled':
led.c:(.text+0x16b): undefined reference to `led_remove_lookup'
x86_64-linux-ld: led.c:(.text+0x177): undefined reference to `led_classdev_unregister'

Quoted 4 lines

Add an explicit Kconfig dependency.

Fixes 5ae20a8050d0 ("platform/x86: int3472/discrete: Create a LED class device for the privacy LED")

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

Regards,

Hans

Quoted 16 lines
---
 drivers/platform/x86/intel/int3472/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/platform/x86/intel/int3472/Kconfig +1 -0
index 62e5d4cf9ee5..17ae997f93ea 100644
@@ -4,6 +4,7 @@ config INTEL_SKL_INT3472
 	depends on COMMON_CLK
 	depends on I2C
 	depends on GPIOLIB
+	depends on LEDS_CLASS
 	depends on REGULATOR
 	select MFD_CORE
 	select REGMAP_I2C