iio: magnetometer: st_magn: add SPI-3wire support to LIS3MDL
authorLorenzo Bianconi <lorenzo.bianconi83@gmail.com>
Sun, 17 Sep 2017 15:20:46 +0000 (17:20 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Tue, 10 Oct 2017 19:36:33 +0000 (20:36 +0100)
Add SPI Serial Interface Mode (SIM) register information to
LIS3MDL magn sensor

Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@st.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/magnetometer/st_magn_core.c

index 8745686f233cb891536830b49d63389de30726b4..72f6d1335a04d363c030a3167e3032794b05f888 100644 (file)
@@ -322,6 +322,10 @@ static const struct st_sensor_settings st_magn_sensors_settings[] = {
                                .mask = 0x07,
                        },
                },
+               .sim = {
+                       .addr = 0x22,
+                       .value = BIT(2),
+               },
                .multi_read_bit = true,
                .bootime = 2,
        },