mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson
synced 2025-09-01 15:14:52 +00:00

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>
81 lines
2.4 KiB
Plaintext
81 lines
2.4 KiB
Plaintext
# SPDX-License-Identifier: GPL-2.0-only
|
|
menuconfig I2C_HID
|
|
tristate "I2C HID support"
|
|
default y
|
|
depends on I2C
|
|
|
|
if I2C_HID
|
|
|
|
config I2C_HID_ACPI
|
|
tristate "HID over I2C transport layer ACPI driver"
|
|
depends on ACPI
|
|
depends on DRM || !DRM
|
|
select I2C_HID_CORE
|
|
help
|
|
Say Y here if you use a keyboard, a touchpad, a touchscreen, or any
|
|
other HID based devices which is connected to your computer via I2C.
|
|
This driver supports ACPI-based systems.
|
|
|
|
If unsure, say N.
|
|
|
|
This support is also available as a module. If so, the module
|
|
will be called i2c-hid-acpi. It will also build/depend on the
|
|
module i2c-hid.
|
|
|
|
config I2C_HID_OF
|
|
tristate "HID over I2C transport layer Open Firmware driver"
|
|
# No "depends on OF" because this can also be used for manually
|
|
# (board-file) instantiated "hid-over-i2c" type i2c-clients.
|
|
depends on DRM || !DRM
|
|
select I2C_HID_CORE
|
|
help
|
|
Say Y here if you use a keyboard, a touchpad, a touchscreen, or any
|
|
other HID based devices which is connected to your computer via I2C.
|
|
This driver supports Open Firmware (Device Tree)-based systems as
|
|
well as binding to manually (board-file) instantiated i2c-hid-clients.
|
|
|
|
If unsure, say N.
|
|
|
|
This support is also available as a module. If so, the module
|
|
will be called i2c-hid-of. It will also build/depend on the
|
|
module i2c-hid.
|
|
|
|
config I2C_HID_OF_ELAN
|
|
tristate "Driver for Elan hid-i2c based devices on OF systems"
|
|
depends on OF
|
|
depends on DRM || !DRM
|
|
select I2C_HID_CORE
|
|
help
|
|
Say Y here if you want support for Elan i2c devices that use
|
|
the i2c-hid protocol on Open Firmware (Device Tree)-based
|
|
systems.
|
|
|
|
If unsure, say N.
|
|
|
|
This support is also available as a module. If so, the module
|
|
will be called i2c-hid-of-elan. It will also build/depend on
|
|
the module i2c-hid.
|
|
|
|
config I2C_HID_OF_GOODIX
|
|
tristate "Driver for Goodix hid-i2c based devices on OF systems"
|
|
depends on OF
|
|
depends on DRM || !DRM
|
|
select I2C_HID_CORE
|
|
help
|
|
Say Y here if you want support for Goodix i2c devices that use
|
|
the i2c-hid protocol on Open Firmware (Device Tree)-based
|
|
systems.
|
|
|
|
If unsure, say N.
|
|
|
|
This support is also available as a module. If so, the module
|
|
will be called i2c-hid-of-goodix. It will also build/depend on
|
|
the module i2c-hid.
|
|
|
|
config I2C_HID_CORE
|
|
tristate
|
|
# We need to call into panel code so if DRM=m, this can't be 'y'
|
|
depends on DRM || !DRM
|
|
endif
|
|
|