diff options
author | Jonathan Cameron <jic23@kernel.org> | 2013-02-27 23:30:36 +0400 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2013-03-17 23:49:35 +0400 |
commit | e1865aa17049f168bf566d6648be851d40588a87 (patch) | |
tree | 61716a5614683a3e60b5246f58609b3491d20071 /drivers/iio | |
parent | 98bfb6e3727bd11089ca4c126248a4481bbe07c2 (diff) | |
download | linux-e1865aa17049f168bf566d6648be851d40588a87.tar.xz |
iio:gyro:itg3200_core move to info_mask_(shared_by_type/separate)
The original info_mask is going away in favour of the broken out versions.
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
cc: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Diffstat (limited to 'drivers/iio')
-rw-r--r-- | drivers/iio/gyro/itg3200_core.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/drivers/iio/gyro/itg3200_core.c b/drivers/iio/gyro/itg3200_core.c index df2e6aa5d73b..d66605d2629d 100644 --- a/drivers/iio/gyro/itg3200_core.c +++ b/drivers/iio/gyro/itg3200_core.c @@ -248,12 +248,6 @@ err_ret: return ret; } -#define ITG3200_TEMP_INFO_MASK (IIO_CHAN_INFO_OFFSET_SHARED_BIT | \ - IIO_CHAN_INFO_SCALE_SHARED_BIT | \ - IIO_CHAN_INFO_RAW_SEPARATE_BIT) -#define ITG3200_GYRO_INFO_MASK (IIO_CHAN_INFO_SCALE_SHARED_BIT | \ - IIO_CHAN_INFO_RAW_SEPARATE_BIT) - #define ITG3200_ST \ { .sign = 's', .realbits = 16, .storagebits = 16, .endianness = IIO_BE } @@ -261,7 +255,8 @@ err_ret: .type = IIO_ANGL_VEL, \ .modified = 1, \ .channel2 = IIO_MOD_ ## _mod, \ - .info_mask = ITG3200_GYRO_INFO_MASK, \ + .info_mask_separate = BIT(IIO_CHAN_INFO_RAW), \ + .info_mask_shared_by_type = BIT(IIO_CHAN_INFO_SCALE), \ .address = ITG3200_REG_GYRO_ ## _mod ## OUT_H, \ .scan_index = ITG3200_SCAN_GYRO_ ## _mod, \ .scan_type = ITG3200_ST, \ @@ -271,7 +266,9 @@ static const struct iio_chan_spec itg3200_channels[] = { { .type = IIO_TEMP, .channel2 = IIO_NO_MOD, - .info_mask = ITG3200_TEMP_INFO_MASK, + .info_mask_separate = BIT(IIO_CHAN_INFO_RAW), + .info_mask_shared_by_type = BIT(IIO_CHAN_INFO_OFFSET) | + BIT(IIO_CHAN_INFO_SCALE), .address = ITG3200_REG_TEMP_OUT_H, .scan_index = ITG3200_SCAN_TEMP, .scan_type = ITG3200_ST, |