Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio: hid-sensors: respect CONFIG_IIO_TRIGGER

Not much to say, without that change, hid-sensor-trigger will be
always compiled if HID_SENSOR_IIO_COMMON is selected which fails if
CONFIG_IIO_TRIGGER is not set because CONFIG_IIO_CONSUMERS_PER_TRIGGER
will not be defined.

Signed-off-by: Alexander Holler <holler@ahsoftware.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>

authored by

Alexander Holler and committed by
Jonathan Cameron
9541cc39 11679767

+18 -2
+1
drivers/iio/accel/Kconfig
··· 8 8 select IIO_BUFFER 9 9 select IIO_TRIGGERED_BUFFER 10 10 select HID_SENSOR_IIO_COMMON 11 + select HID_SENSOR_IIO_TRIGGER 11 12 tristate "HID Accelerometers 3D" 12 13 help 13 14 Say yes here to build support for the HID SENSOR
+12 -1
drivers/iio/common/hid-sensors/Kconfig
··· 6 6 config HID_SENSOR_IIO_COMMON 7 7 tristate "Common modules for all HID Sensor IIO drivers" 8 8 depends on HID_SENSOR_HUB 9 - select IIO_TRIGGER if IIO_BUFFER 9 + select HID_SENSOR_IIO_TRIGGER if IIO_BUFFER 10 10 help 11 11 Say yes here to build support for HID sensor to use 12 12 HID sensor common processing for attributes and IIO triggers. 13 13 There are many attributes which can be shared among multiple 14 14 HID sensor drivers, this module contains processing for those 15 15 attributes. 16 + 17 + config HID_SENSOR_IIO_TRIGGER 18 + tristate "Common module (trigger) for all HID Sensor IIO drivers" 19 + depends on HID_SENSOR_HUB && HID_SENSOR_IIO_COMMON 20 + select IIO_TRIGGER 21 + help 22 + Say yes here to build trigger support for HID sensors. 23 + Triggers will be send if all requested attributes were read. 24 + 25 + If this driver is compiled as a module, it will be named 26 + hid-sensor-trigger. 16 27 17 28 config HID_SENSOR_ENUM_BASE_QUIRKS 18 29 bool "ENUM base quirks for HID Sensor IIO drivers"
+2 -1
drivers/iio/common/hid-sensors/Makefile
··· 3 3 # 4 4 5 5 obj-$(CONFIG_HID_SENSOR_IIO_COMMON) += hid-sensor-iio-common.o 6 - hid-sensor-iio-common-y := hid-sensor-attributes.o hid-sensor-trigger.o 6 + obj-$(CONFIG_HID_SENSOR_IIO_TRIGGER) += hid-sensor-trigger.o 7 + hid-sensor-iio-common-y := hid-sensor-attributes.o
+1
drivers/iio/gyro/Kconfig
··· 17 17 select IIO_BUFFER 18 18 select IIO_TRIGGERED_BUFFER 19 19 select HID_SENSOR_IIO_COMMON 20 + select HID_SENSOR_IIO_TRIGGER 20 21 tristate "HID Gyroscope 3D" 21 22 help 22 23 Say yes here to build support for the HID SENSOR
+1
drivers/iio/light/Kconfig
··· 47 47 select IIO_BUFFER 48 48 select IIO_TRIGGERED_BUFFER 49 49 select HID_SENSOR_IIO_COMMON 50 + select HID_SENSOR_IIO_TRIGGER 50 51 tristate "HID ALS" 51 52 help 52 53 Say yes here to build support for the HID SENSOR
+1
drivers/iio/magnetometer/Kconfig
··· 8 8 select IIO_BUFFER 9 9 select IIO_TRIGGERED_BUFFER 10 10 select HID_SENSOR_IIO_COMMON 11 + select HID_SENSOR_IIO_TRIGGER 11 12 tristate "HID Magenetometer 3D" 12 13 help 13 14 Say yes here to build support for the HID SENSOR