Skip to content

Commit c9c1d6d

Browse files
vladimirolteanjic23
authored andcommitted
iio: imu: st_lsm6dsx: fix build when CONFIG_IIO_TRIGGERED_BUFFER=m
The following kernel linkage error: st_lsm6dsx_core.o: in function `st_lsm6dsx_sw_buffers_setup': st_lsm6dsx_core.c:2578: undefined reference to `devm_iio_triggered_buffer_setup_ext' is caused by the fact that the object owning devm_iio_triggered_buffer_setup_ext() (drivers/iio/buffer/industrialio-triggered-buffer.o) is allowed to be built as module when its user (drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c) is built-in. The st_lsm6dsx driver already has a "select IIO_BUFFER", so add another select for IIO_TRIGGERED_BUFFER, to make that option follow what is set for the st_lsm6dsx driver. This is similar to what other iio drivers do. Fixes: 2cfb218 ("iio: imu: st_lsm6dsx: introduce sw trigger support") Signed-off-by: Vladimir Oltean <[email protected]> Link: https://lore.kernel.org/r/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
1 parent bffb7d9 commit c9c1d6d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/iio/imu/st_lsm6dsx/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ config IIO_ST_LSM6DSX
44
tristate "ST_LSM6DSx driver for STM 6-axis IMU MEMS sensors"
55
depends on (I2C || SPI || I3C)
66
select IIO_BUFFER
7+
select IIO_TRIGGERED_BUFFER
78
select IIO_KFIFO_BUF
89
select IIO_ST_LSM6DSX_I2C if (I2C)
910
select IIO_ST_LSM6DSX_SPI if (SPI_MASTER)

0 commit comments

Comments
 (0)