6731ca3999
We can utilize separate drivers for accelerometer and magnetometer, so here is the glue driver to enable LSM9DS0 IMU support. The idea was suggested by Crestez Dan Leonard in [1]. The proposed change was sent as RFC due to race condition concerns, which are indeed possible. In order to amend the initial change, I went further by providing a specific multi-instantiate probe driver that reuses existing accelerometer and magnetometer. [1]: https://lore.kernel.org/patchwork/patch/670353/ Suggested-by: Crestez Dan Leonard <leonard.crestez@intel.com> Cc: mr.lahorde@laposte.net Cc: Matija Podravec <matija_podravec@fastmail.fm> Cc: Sergey Borishchenko <borischenko.sergey@gmail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20210414195454.84183-6-andriy.shevchenko@linux.intel.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
29 lines
748 B
Plaintext
29 lines
748 B
Plaintext
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
config IIO_ST_LSM9DS0
|
|
tristate "STMicroelectronics LSM9DS0 IMU driver"
|
|
depends on (I2C || SPI_MASTER) && SYSFS
|
|
depends on !SENSORS_LIS3_I2C
|
|
depends on !SENSORS_LIS3_SPI
|
|
select IIO_ST_LSM9DS0_I2C if I2C
|
|
select IIO_ST_LSM9DS0_SPI if SPI_MASTER
|
|
select IIO_ST_ACCEL_3AXIS
|
|
select IIO_ST_MAGN_3AXIS
|
|
|
|
help
|
|
Say yes here to build support for STMicroelectronics LSM9DS0 IMU
|
|
sensor. Supported devices: accelerometer/magnetometer of lsm9ds0.
|
|
|
|
To compile this driver as a module, choose M here: the module
|
|
will be called st_lsm9ds0.
|
|
|
|
config IIO_ST_LSM9DS0_I2C
|
|
tristate
|
|
depends on IIO_ST_LSM9DS0
|
|
select REGMAP_I2C
|
|
|
|
config IIO_ST_LSM9DS0_SPI
|
|
tristate
|
|
depends on IIO_ST_LSM9DS0
|
|
select REGMAP_SPI
|