mbox series

[0/2] Remove HID_LENOVO's dependency on ACPI

Message ID 20250518-hid_lenovo_acpi_dependency-v1-0-afdb93b5d1a6@jannau.net
Headers show
Series Remove HID_LENOVO's dependency on ACPI | expand

Message

Janne Grunau via B4 Relay May 18, 2025, 10:18 a.m. UTC
hid-lenovo supports external generic USB and Bluetooth devices and
should be buildable and usable on non-ACPI kernels and systems. Commit
84c9d2a968c82 ("HID: lenovo: Support for ThinkPad-X12-TAB-1/2 Kbd Fn
keys") added a hot key to cycle through power profiles using ACPI's
platform_profile. This resulted in adding a dependency on ACPI and
selecting CONFIG_ACPI_PLATFORM_PROFILE to fix build an link errors in
commit 52572cde8b4a ("HID: lenovo: select
CONFIG_ACPI_PLATFORM_PROFILE"). This is undesirable for HID drivers
supporting generic USB and Bluetooth devices. So instead stub the only
used function platform_profile_cycle() and relax the dependency.

Signed-off-by: Janne Grunau <j@jannau.net>
---
Janne Grunau (2):
      ACPI: platform_profile: Stub platform_profile_cycle
      HID: lenovo: Remove CONFIG_ACPI dependency

 drivers/hid/Kconfig              |  4 ++--
 include/linux/platform_profile.h | 11 +++++++++++
 2 files changed, 13 insertions(+), 2 deletions(-)
---
base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
change-id: 20250518-hid_lenovo_acpi_dependency-0ea78a6bd740

Best regards,