diff options
| author | Denis CIOCCA <denis.ciocca@st.com> | 2013-06-03 10:58:00 -0400 |
|---|---|---|
| committer | Jonathan Cameron <jic23@kernel.org> | 2013-06-04 13:53:56 -0400 |
| commit | 762011d6193f8b9af9b491ded87dde3221d0600a (patch) | |
| tree | dcb4407f84566ab08c12ee739ab77954a4af8057 /include/linux/iio/common | |
| parent | 0a4510a6cbee270820871e60ab0cac7058b2f394 (diff) | |
iio:common: ST_SENSORS_LSM_CHANNELS macro changed
Signed-off-by: Denis Ciocca <denis.ciocca@st.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'include/linux/iio/common')
| -rw-r--r-- | include/linux/iio/common/st_sensors.h | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/include/linux/iio/common/st_sensors.h b/include/linux/iio/common/st_sensors.h index 172c5b23cb84..5ffd763702dc 100644 --- a/include/linux/iio/common/st_sensors.h +++ b/include/linux/iio/common/st_sensors.h | |||
| @@ -30,8 +30,6 @@ | |||
| 30 | #define ST_SENSORS_SCAN_X 0 | 30 | #define ST_SENSORS_SCAN_X 0 |
| 31 | #define ST_SENSORS_SCAN_Y 1 | 31 | #define ST_SENSORS_SCAN_Y 1 |
| 32 | #define ST_SENSORS_SCAN_Z 2 | 32 | #define ST_SENSORS_SCAN_Z 2 |
| 33 | #define ST_SENSORS_DEFAULT_12_REALBITS 12 | ||
| 34 | #define ST_SENSORS_DEFAULT_16_REALBITS 16 | ||
| 35 | #define ST_SENSORS_DEFAULT_POWER_ON_VALUE 0x01 | 33 | #define ST_SENSORS_DEFAULT_POWER_ON_VALUE 0x01 |
| 36 | #define ST_SENSORS_DEFAULT_POWER_OFF_VALUE 0x00 | 34 | #define ST_SENSORS_DEFAULT_POWER_OFF_VALUE 0x00 |
| 37 | #define ST_SENSORS_DEFAULT_WAI_ADDRESS 0x0f | 35 | #define ST_SENSORS_DEFAULT_WAI_ADDRESS 0x0f |
| @@ -42,20 +40,20 @@ | |||
| 42 | #define ST_SENSORS_MAX_NAME 17 | 40 | #define ST_SENSORS_MAX_NAME 17 |
| 43 | #define ST_SENSORS_MAX_4WAI 7 | 41 | #define ST_SENSORS_MAX_4WAI 7 |
| 44 | 42 | ||
| 45 | #define ST_SENSORS_LSM_CHANNELS(device_type, index, mod, endian, bits, addr) \ | 43 | #define ST_SENSORS_LSM_CHANNELS(device_type, mask, index, mod, \ |
| 44 | ch2, s, endian, rbits, sbits, addr) \ | ||
| 46 | { \ | 45 | { \ |
| 47 | .type = device_type, \ | 46 | .type = device_type, \ |
| 48 | .modified = 1, \ | 47 | .modified = mod, \ |
| 49 | .info_mask_separate = BIT(IIO_CHAN_INFO_RAW) | \ | 48 | .info_mask_separate = mask, \ |
| 50 | BIT(IIO_CHAN_INFO_SCALE), \ | ||
| 51 | .scan_index = index, \ | 49 | .scan_index = index, \ |
| 52 | .channel2 = mod, \ | 50 | .channel2 = ch2, \ |
| 53 | .address = addr, \ | 51 | .address = addr, \ |
| 54 | .scan_type = { \ | 52 | .scan_type = { \ |
| 55 | .sign = 's', \ | 53 | .sign = s, \ |
| 56 | .realbits = bits, \ | 54 | .realbits = rbits, \ |
| 57 | .shift = 16 - bits, \ | 55 | .shift = sbits - rbits, \ |
| 58 | .storagebits = 16, \ | 56 | .storagebits = sbits, \ |
| 59 | .endianness = endian, \ | 57 | .endianness = endian, \ |
| 60 | }, \ | 58 | }, \ |
| 61 | } | 59 | } |
