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

Configure Feed

Select the types of activity you want to include in your feed.

iio: imu: st_lsm6dsx: don't always auto-enable I2C, I3C and SPI interface drivers

This patch makes I2C, I3C and SPI interface drivers for ST lsm6dsx
individually selectable via Kconfig.

The default is kept unchanged - I2C, I3C and SPI interface drivers are
still selected by default if the corresponding bus support is available.

However, the patch makes it possible to explicitly disable drivers
that are not needed for a particular target.

Signed-off-by: Sean Nyekjaer <sean@geanix.com>
Link: https://patch.msgid.link/20241203-lsm6dsx-v1-1-6d7893443bc8@geanix.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Sean Nyekjaer and committed by
Jonathan Cameron
804eb393 c3084fad

+9 -9
+9 -9
drivers/iio/imu/st_lsm6dsx/Kconfig
··· 6 6 select IIO_BUFFER 7 7 select IIO_TRIGGERED_BUFFER 8 8 select IIO_KFIFO_BUF 9 - select IIO_ST_LSM6DSX_I2C if (I2C) 10 - select IIO_ST_LSM6DSX_SPI if (SPI_MASTER) 11 - select IIO_ST_LSM6DSX_I3C if (I3C) 12 9 help 13 10 Say yes here to build support for STMicroelectronics LSM6DSx imu 14 11 sensor. ··· 39 42 will be called st_lsm6dsx. 40 43 41 44 config IIO_ST_LSM6DSX_I2C 42 - tristate 43 - depends on IIO_ST_LSM6DSX 45 + tristate "ST_LSM6DSx driver for STM 6-axis IMU MEMS sensors I2C Interface" 46 + depends on I2C && IIO_ST_LSM6DSX 47 + default I2C && IIO_ST_LSM6DSX 44 48 select REGMAP_I2C 45 49 46 50 config IIO_ST_LSM6DSX_SPI 47 - tristate 48 - depends on IIO_ST_LSM6DSX 51 + tristate "ST_LSM6DSx driver for STM 6-axis IMU MEMS sensors SPI Interface" 52 + depends on SPI_MASTER && IIO_ST_LSM6DSX 53 + default SPI_MASTER && IIO_ST_LSM6DSX 49 54 select REGMAP_SPI 50 55 51 56 config IIO_ST_LSM6DSX_I3C 52 - tristate 53 - depends on IIO_ST_LSM6DSX 57 + tristate "ST_LSM6DSx driver for STM 6-axis IMU MEMS sensors I3C Interface" 58 + depends on I3C && IIO_ST_LSM6DSX 59 + default I3C && IIO_ST_LSM6DSX 54 60 select REGMAP_I3C