linux-loongson/drivers/hid/surface-hid/Kconfig
Arnd Bergmann a5a056c8d2 HID: intel-thc: fix CONFIG_HID dependency
In drivers/hid/, most drivers depend on CONFIG_HID, while a couple of the
drivers in subdirectories instead depend on CONFIG_HID_SUPPORT and use
'select HID'. With the newly added INTEL_THC_HID, this causes a build
warning for a circular dependency:

WARNING: unmet direct dependencies detected for HID
  Depends on [m]: HID_SUPPORT [=y] && INPUT [=m]
  Selected by [y]:
  - INTEL_THC_HID [=y] && HID_SUPPORT [=y] && X86_64 [=y] && PCI [=y] && ACPI [=y]

WARNING: unmet direct dependencies detected for INPUT_FF_MEMLESS
  Depends on [m]: INPUT [=m]
  Selected by [y]:
  - HID_MICROSOFT [=y] && HID_SUPPORT [=y] && HID [=y]
  - GREENASIA_FF [=y] && HID_SUPPORT [=y] && HID [=y] && HID_GREENASIA [=y]
  - HID_WIIMOTE [=y] && HID_SUPPORT [=y] && HID [=y] && LEDS_CLASS [=y]
  - ZEROPLUS_FF [=y] && HID_SUPPORT [=y] && HID [=y] && HID_ZEROPLUS [=y]
  Selected by [m]:
  - HID_ACRUX_FF [=y] && HID_SUPPORT [=y] && HID [=y] && HID_ACRUX [=m]
  - HID_EMS_FF [=m] && HID_SUPPORT [=y] && HID [=y]
  - HID_GOOGLE_STADIA_FF [=m] && HID_SUPPORT [=y] && HID [=y]
  - PANTHERLORD_FF [=y] && HID_SUPPORT [=y] && HID [=y] && HID_PANTHERLORD [=m]

It's better to be consistent and always use 'depends on HID' for HID
drivers. The notable exception here is USB_KBD/USB_MOUSE, which are
alternative implementations that do not depend on the HID subsystem.

Do this by extending the "if HID" section below, which means that a few
of the duplicate "depends on HID" and "depends on INPUT" statements
can be removed in the process.

Fixes: 1b2d05384c ("HID: intel-thc-hid: Add basic THC driver skeleton")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Reviewed-by: Maximilian Luz <luzmaximilian@gmail.com>
Reviewed-by: Even Xu <even.xu@intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.com>
2025-02-03 10:56:43 +01:00

41 lines
1.4 KiB
Plaintext

# SPDX-License-Identifier: GPL-2.0+
menu "Surface System Aggregator Module HID support"
depends on SURFACE_AGGREGATOR
config SURFACE_HID
tristate "HID transport driver for Surface System Aggregator Module"
depends on SURFACE_AGGREGATOR_REGISTRY
select SURFACE_HID_CORE
help
Driver to support integrated HID devices on newer Microsoft Surface
models.
This driver provides support for the HID transport protocol provided
by the Surface Aggregator Module (i.e. the embedded controller) on
7th-generation Microsoft Surface devices, i.e. Surface Book 3 and
Surface Laptop 3. On those models, it is mainly used to connect the
integrated touchpad and keyboard.
Say M or Y here, if you want support for integrated HID devices, i.e.
integrated touchpad and keyboard, on 7th generation Microsoft Surface
models.
config SURFACE_KBD
tristate "HID keyboard transport driver for Surface System Aggregator Module"
select SURFACE_HID_CORE
help
Driver to support HID keyboards on Surface Laptop 1 and 2 devices.
This driver provides support for the HID transport protocol provided
by the Surface Aggregator Module (i.e. the embedded controller) on
Microsoft Surface Laptops 1 and 2. It is used to connect the
integrated keyboard on those devices.
Say M or Y here, if you want support for the integrated keyboard on
Microsoft Surface Laptops 1 and 2.
endmenu
config SURFACE_HID_CORE
tristate