Skip to contentSkip to conversation

IIO break info_mask into a pair of masks

PATCH Superseded Jonathan Cameron 7 participants 75 messages Feb 27, 2013 – Feb 28, 2013

Subsystems (11)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Jonathan Cameron

author maintainer
#0 lore raw

cover IIO break info_mask into a pair of masks

Hi All,

This has been on my todo list for a while. I'm not sure how we ever ended up with the mess that is the current info_mask bitmap of which properties exist for a given channel. Anyhow currently you have two types of bit in there, IIO_CHAN_INFO_SHARED_BIT (even) and IIO_CHAN_INFO_SEPARATE_BIT (odd). Whether we have odd or even elements is used to indicate whether we want an associated attribute specific to the channel, or one that is shared. E.g.

in_accel_x_scale (for just the x accel channel)
or
in_accel_scale (for all accel channels)

in_illuminance0_calibbias
or
in_illuminance_calibbias

This led to a horrible mess in iio.h where we had macros for each option of every element added to the info_mask. Also, a while back it became apparent that sometimes we have attributes shared across all channels irrespective of their type (sampling_frequency for example). Now the obvious solution to this would be to add a third type of info_mask element, but then things are getting rather silly.

Hence the proposed solution. Have separate info_mask elements for each of the two types of bit we had previously (others may follow).

Advantages:

1) More consise naming of elements
2) Drop all those hideous macros
3) More space (admitedly there are lots of other ways we could have gotten that).

Can't immediately think of any disadvantages other than the fact that we now have so many drivers this was rather time consuming to actually put together and almost certainly has some errors somewhere.

Jonathan

Jonathan Cameron (67):
iio: Add broken out info_mask fields for shared_by_type and separate iio:adc:max1363 move to info_mask_(shared_by_type/separate) staging:iio:dummy move to info_mask_(shared_by_type/separate) iio:hid_sensors move to info_mask_(shared_by_type/separate) iio:accel:kxsd9 move to info_mask_(shared_by_type/separate) iio:st_sensors move to info_mask_(shared_by_type/separate) iio:adc:ad_sigma_delta move to info_mask_(shared_by_type/separate) iio:adc:ad7266 move to info_mask_(shared_by_type/separate) iio:adc:ad7298 move to info_mask_(shared_by_type/separate) iio:adc:ad7476 move to info_mask_(shared_by_type/separate) iio:adc:ad7887 move to info_mask_(shared_by_type/separate) iio:adc:at91_adc move to info_mask_(shared_by_type/separate) iio:adc:lp8778_adc move to info_mask_(shared_by_type/separate) iio:adc:ti-adc081 move to info_mask_(shared_by_type/separate) iio:adc:ti_am335x_adc move to info_mask_(shared_by_type/separate) iio:adc:viperboard_adc move to info_mask_(shared_by_type/separate) iio:amplifiers:ad8366 move to info_mask_(shared_by_type/separate) iio:dac:ad5064 move to info_mask_(shared_by_type/separate) iio:dac:ad5360 move to info_mask_(shared_by_type/separate) iio:dac:ad5380 move to info_mask_(shared_by_type/separate) iio:dac:ad5421 move to info_mask_(shared_by_type/separate) iio:dac:ad5446 move to info_mask_(shared_by_type/separate) iio:dac:ad5449 move to info_mask_(shared_by_type/separate) iio:dac:ad5504 move to info_mask_(shared_by_type/separate) iio:dac:ad5624r move to info_mask_(shared_by_type/separate) iio:dac:ad5686 move to info_mask_(shared_by_type/separate) iio:dac:ad5755 move to info_mask_(shared_by_type/separate) iio:dac:ad5764 move to info_mask_(shared_by_type/separate) iio:dac:ad5791 move to info_mask_(shared_by_type/separate) iio:dac:max517 move to info_mask_(shared_by_type/separate) iio:dac:mcp4725 move to info_mask_(shared_by_type/separate) iio:freq:ad9523 move to info_mask_(shared_by_type/separate) iio:gyro:adis16080 move to info_mask_(shared_by_type/separate) iio:gyro:adis16136 move to info_mask_(shared_by_type/separate) iio:gyro:adxrs450 move to info_mask_(shared_by_type/separate) iio:gyro:itg3200_core move to info_mask_(shared_by_type/separate) iio:imu:adis16400 move to info_mask_(shared_by_type/separate) iio:imu:adis16480 move to info_mask_(shared_by_type/separate) iio:imu:mpu6050 move to info_mask_(shared_by_type/separate) iio:light:adjd_s311 move to info_mask_(shared_by_type/separate) iio:light:lm3533 move to info_mask_(shared_by_type/separate) iio:light:tsl2563 move to info_mask_(shared_by_type/separate) iio:light:vcnl4000 move to info_mask_(shared_by_type/separate) staging:iio:accel:adis move to info_mask_(shared_by_type/separate) staging:iio:accel:adis16220 move to
info_mask_(shared_by_type/separate)
staging:iio:accel:lis3l02dq move to
info_mask_(shared_by_type/separate)
staging:iio:accel:sca3000 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad7280a move to info_mask_(shared_by_type/separate) staging:iio:ad7291 move to info_mask_(shared_by_type/separate) staging:iio:ad7606 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad799x move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7746 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16060 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16130 move to info_mask_(shared_by_type/separate) staging:iio:impedance:ad5933 move to
info_mask_(shared_by_type/separate)
staging:iio:light:isl29018 move to info_mask_(shared_by_type/separate) staging:iio:isl29028 move to info_mask_(shared_by_type/separate) staging:iio:light:tsl2x7x move to info_mask_(shared_by_type/separate) staging:iio:mag:ak8975 move to info_mask_(shared_by_type/separate) staging:iio:hmc5843 move to info_mask_(shared_by_type/separate) staging:iio:meter:ade7758 move to info_mask_(shared_by_type/separate) staging:iio:resolver:ad2s1200 move to
info_mask_(shared_by_type/separate)
staging:iio:resolver:ad2s1210 move to
info_mask_(shared_by_type/separate)
staging:iio:ad2s90 move to info_mask_(shared_by_type/separate) iio:core drop info_mask from struct iio_info

 drivers/iio/accel/hid-sensor-accel-3d.c         | 24 ++++----
 drivers/iio/accel/kxsd9.c                       |  6 +-
 drivers/iio/adc/ad7266.c                        | 12 ++--
 drivers/iio/adc/ad7298.c                        | 10 ++--
 drivers/iio/adc/ad7476.c                        | 10 ++--
 drivers/iio/adc/ad7887.c                        |  8 +--
 drivers/iio/adc/at91_adc.c                      |  4 +-
 drivers/iio/adc/lp8788_adc.c                    |  4 +-
 drivers/iio/adc/max1363.c                       |  9 +--
 drivers/iio/adc/ti-adc081c.c                    |  4 +-
 drivers/iio/adc/ti_am335x_adc.c                 |  2 +-
 drivers/iio/adc/viperboard_adc.c                |  2 +-
 drivers/iio/amplifiers/ad8366.c                 |  2 +-
 drivers/iio/dac/ad5064.c                        |  4 +-
 drivers/iio/dac/ad5360.c                        | 10 ++--
 drivers/iio/dac/ad5380.c                        |  8 +--
 drivers/iio/dac/ad5421.c                        | 10 ++--
 drivers/iio/dac/ad5446.c                        |  4 +-
 drivers/iio/dac/ad5449.c                        |  4 +-
 drivers/iio/dac/ad5504.c                        |  4 +-
 drivers/iio/dac/ad5624r_spi.c                   |  4 +-
 drivers/iio/dac/ad5686.c                        |  6 +-
 drivers/iio/dac/ad5755.c                        | 10 ++--
 drivers/iio/dac/ad5764.c                        | 10 ++--
 drivers/iio/dac/ad5791.c                        |  6 +-
 drivers/iio/dac/max517.c                        |  4 +-
 drivers/iio/dac/mcp4725.c                       |  4 +-
 drivers/iio/frequency/ad9523.c                  |  8 +--
 drivers/iio/gyro/adis16080.c                    | 22 +++----
 drivers/iio/gyro/adis16136.c                    | 13 ++--
 drivers/iio/gyro/adxrs450.c                     | 22 +++----
 drivers/iio/gyro/hid-sensor-gyro-3d.c           | 24 ++++----
 drivers/iio/gyro/itg3200_core.c                 | 13 ++--
 drivers/iio/imu/adis16400_core.c                | 44 +++++++-------
 drivers/iio/imu/adis16480.c                     | 32 +++++-----
 drivers/iio/imu/inv_mpu6050/inv_mpu_core.c      | 10 ++--
 drivers/iio/industrialio-core.c                 | 27 ++++++---
 drivers/iio/light/adjd_s311.c                   |  4 +-
 drivers/iio/light/hid-sensor-als.c              |  8 +--
 drivers/iio/light/lm3533-als.c                  |  6 +-
 drivers/iio/light/tsl2563.c                     | 10 ++--
 drivers/iio/light/vcnl4000.c                    |  6 +-
 drivers/iio/magnetometer/hid-sensor-magn-3d.c   | 24 ++++----
 drivers/staging/iio/accel/adis16201_core.c      |  8 +--
 drivers/staging/iio/accel/adis16203_core.c      |  2 +-
 drivers/staging/iio/accel/adis16204_core.c      |  8 +--
 drivers/staging/iio/accel/adis16209_core.c      |  4 +-
 drivers/staging/iio/accel/adis16220_core.c      | 21 +++----
 drivers/staging/iio/accel/adis16240_core.c      |  9 +--
 drivers/staging/iio/accel/lis3l02dq_core.c      | 11 ++--
 drivers/staging/iio/accel/sca3000_core.c        |  5 +-
 drivers/staging/iio/adc/ad7280a.c               | 12 ++--
 drivers/staging/iio/adc/ad7291.c                | 10 ++--
 drivers/staging/iio/adc/ad7606_core.c           |  4 +-
 drivers/staging/iio/adc/ad799x_core.c           | 76 ++++++++++++------------
 drivers/staging/iio/cdc/ad7150.c                |  8 +--
 drivers/staging/iio/cdc/ad7152.c                | 32 +++++-----
 drivers/staging/iio/cdc/ad7746.c                | 48 +++++++--------
 drivers/staging/iio/gyro/adis16060_core.c       | 11 ++--
 drivers/staging/iio/gyro/adis16130_core.c       |  4 +-
 drivers/staging/iio/gyro/adis16260_core.c       |  4 +-
 drivers/staging/iio/iio_simple_dummy.c          | 33 +++++------
 drivers/staging/iio/impedance-analyzer/ad5933.c |  8 +--
 drivers/staging/iio/light/isl29018.c            |  8 +--
 drivers/staging/iio/light/isl29028.c            | 10 ++--
 drivers/staging/iio/light/tsl2x7x_core.c        | 40 ++++++-------
 drivers/staging/iio/magnetometer/ak8975.c       |  4 +-
 drivers/staging/iio/magnetometer/hmc5843.c      |  4 +-
 drivers/staging/iio/meter/ade7758_core.c        | 60 +++++++++----------
 drivers/staging/iio/resolver/ad2s1200.c         |  4 +-
 drivers/staging/iio/resolver/ad2s1210.c         |  4 +-
 drivers/staging/iio/resolver/ad2s90.c           |  2 +-
 include/linux/iio/adc/ad_sigma_delta.h          |  6 +-
 include/linux/iio/common/st_sensors.h           |  4 +-
 include/linux/iio/iio.h                         | 79 +++----------------------
 include/linux/iio/imu/adis.h                    | 34 +++++------
 76 files changed, 478 insertions(+), 557 deletions(-)
Signature · 1 line
1.8.1.1
author maintainer
#1 lore raw

PATCH 1/67 iio: Add broken out info_mask fields for shared_by_type and separate

This simplifies the code, removes an extensive layer of 'helper' macros and gives us twice as much room to play with in these masks before we have any need to be clever.

---
 drivers/iio/industrialio-core.c | 30 ++++++++++++++++++++++++++++++
 include/linux/iio/iio.h         | 10 +++++++++-
 2 files changed, 39 insertions(+), 1 deletion(-)
drivers/iio/industrialio-core.c +30 -0
index 8848f16..bfb9ccb 100644
@@ -708,6 +708,36 @@ static int iio_device_add_channel_sysfs(struct iio_dev *indio_dev,
 			goto error_ret;
 		attrcount++;
 	}
+	for_each_set_bit(i, &chan->info_mask_separate, sizeof(long)*8) {
+		ret = __iio_add_chan_devattr(iio_chan_info_postfix[i],
+					     chan,
+					     &iio_read_channel_info,
+					     &iio_write_channel_info,
+					     i,
+					     1,
+					     &indio_dev->dev,
+					     &indio_dev->channel_attr_list);
+		if (ret < 0)
+			goto error_ret;
+		attrcount++;
+	}
+	for_each_set_bit(i, &chan->info_mask_shared_by_type, sizeof(long)*8) {
+		ret = __iio_add_chan_devattr(iio_chan_info_postfix[i],
+					     chan,
+					     &iio_read_channel_info,
+					     &iio_write_channel_info,
+					     i,
+					     0,
+					     &indio_dev->dev,
+					     &indio_dev->channel_attr_list);
+		if (ret == -EBUSY) {
+			ret = 0;
+			continue;
+		} else if (ret < 0) {
+			goto error_ret;
+		}
+		attrcount++;
+	}
 
 	if (chan->ext_info) {
 		unsigned int i = 0;
include/linux/iio/iio.h +9 -1
index da8c776..7697650 100644
@@ -218,6 +218,10 @@ ssize_t iio_enum_write(struct iio_dev *indio_dev,
  *			endianness:	little or big endian
  * @info_mask:		What information is to be exported about this channel.
  *			This includes calibbias, scale etc.
+ * @info_mask_separate: What information is to be exported that is specific to
+ *			this channel.
+ * @info_mask_shared_by_type: What information is to be exported that is shared
+*			by all channels of the same type.
  * @event_mask:		What events can this channel produce.
  * @ext_info:		Array of extended info attributes for this channel.
  *			The array is NULL terminated, the last element should
@@ -253,6 +257,8 @@ struct iio_chan_spec {
 		enum iio_endian endianness;
 	} scan_type;
 	long			info_mask;
+	long			info_mask_separate;
+	long			info_mask_shared_by_type;
 	long			event_mask;
 	const struct iio_chan_spec_ext_info *ext_info;
 	const char		*extend_name;
@@ -275,7 +281,9 @@ struct iio_chan_spec {
 static inline bool iio_channel_has_info(const struct iio_chan_spec *chan,
 	enum iio_chan_info_enum type)
 {
-	return chan->info_mask & IIO_CHAN_INFO_BITS(type);
+	return (chan->info_mask & IIO_CHAN_INFO_BITS(type)) |
+	       (chan->info_mask_separate & type) |
+	       (chan->info_mask_shared_by_type & type);
 }
 
 #define IIO_ST(si, rb, sb, sh)						\
Signature · 1 line
1.8.1.1
author maintainer
#2 lore raw

PATCH 2/67 iio:adc:max1363 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/max1363.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/iio/adc/max1363.c +5 -4
index 6c1cfb7..c8b8819 100644
@@ -427,15 +427,15 @@ static const enum max1363_modes max1363_mode_list[] = {
 #define MAX1363_EV_M						\
 	(IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING)	\
 	 | IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_FALLING))
-#define MAX1363_INFO_MASK (IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-			   IIO_CHAN_INFO_SCALE_SHARED_BIT)
+
 #define MAX1363_CHAN_U(num, addr, si, bits, evmask)			\
 	{								\
 		.type = IIO_VOLTAGE,					\
 		.indexed = 1,						\
 		.channel = num,						\
 		.address = addr,					\
-		.info_mask = MAX1363_INFO_MASK,				\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.datasheet_name = "AIN"#num,				\
 		.scan_type = {						\
 			.sign = 'u',					\
@@ -456,7 +456,8 @@ static const enum max1363_modes max1363_mode_list[] = {
 		.channel = num,						\
 		.channel2 = num2,					\
 		.address = addr,					\
-		.info_mask = MAX1363_INFO_MASK,				\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.datasheet_name = "AIN"#num"-AIN"#num2,			\
 		.scan_type = {						\
 			.sign = 's',					\
Signature · 1 line
1.8.1.1
author maintainer
#3 lore raw

PATCH 3/67 staging:iio:dummy move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/iio_simple_dummy.c | 33 +++++++++++++++------------------
 1 file changed, 15 insertions(+), 18 deletions(-)
drivers/staging/iio/iio_simple_dummy.c +15 -18
index aee76c7..abfee6d 100644
@@ -71,25 +71,25 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		/* What other information is available? */
-		.info_mask =
+		.info_mask_separate =
 		/*
 		 * in_voltage0_raw
 		 * Raw (unscaled no bias removal etc) measurement
 		 * from the device.
 		 */
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT |
+		IIO_CHAN_INFO_RAW |
 		/*
 		 * in_voltage0_offset
 		 * Offset for userspace to apply prior to scale
 		 * when converting to standard units (microvolts)
 		 */
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
+		IIO_CHAN_INFO_OFFSET |
 		/*
 		 * in_voltage0_scale
 		 * Multipler for userspace to apply post offset
 		 * when converting to standard units (microvolts)
 		 */
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		IIO_CHAN_INFO_SCALE,
 		/* The ordering of elements in the buffer via an enum */
 		.scan_index = voltage0,
 		.scan_type = { /* Description of storage in buffer */
@@ -118,19 +118,18 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.channel2 = 2,
-		.info_mask =
 		/*
 		 * in_voltage1-voltage2_raw
 		 * Raw (unscaled no bias removal etc) measurement
 		 * from the device.
 		 */
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT |
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		/*
 		 * in_voltage-voltage_scale
 		 * Shared version of scale - shared by differential
 		 * input channels of type IIO_VOLTAGE.
 		 */
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.scan_index = diffvoltage1m2,
 		.scan_type = { /* Description of storage in buffer */
 			.sign = 's', /* signed */
@@ -146,9 +145,8 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
 		.indexed = 1,
 		.channel = 3,
 		.channel2 = 4,
-		.info_mask =
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.scan_index = diffvoltage3m4,
 		.scan_type = {
 			.sign = 's',
@@ -166,15 +164,14 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
 		.modified = 1,
 		/* Channel 2 is use for modifiers */
 		.channel2 = IIO_MOD_X,
-		.info_mask =
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT |
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
 		/*
 		 * Internal bias correction value. Applied
 		 * by the hardware or driver prior to userspace
 		 * seeing the readings. Typically part of hardware
 		 * calibration.
 		 */
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,
+		IIO_CHAN_INFO_CALIBBIAS,
 		.scan_index = accelx,
 		.scan_type = { /* Description of storage in buffer */
 			.sign = 's', /* signed */
@@ -191,7 +188,7 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
 	/* DAC channel out_voltage0_raw */
 	{
 		.type = IIO_VOLTAGE,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.output = 1,
 		.indexed = 1,
 		.channel = 0,
@@ -204,8 +201,8 @@ static const struct iio_chan_spec iio_dummy_channels[] = {
  * @chan:	the channel whose data is to be read
  * @val:	first element of returned value (typically INT)
  * @val2:	second element of returned value (typically MICRO)
- * @mask:	what we actually want to read. 0 is the channel, everything else
- *		is as per the info_mask in iio_chan_spec.
+ * @mask:	what we actually want to read as per the info_mask_*
+ *		in iio_chan_spec.
  */
 static int iio_dummy_read_raw(struct iio_dev *indio_dev,
 			      struct iio_chan_spec const *chan,
@@ -287,8 +284,8 @@ static int iio_dummy_read_raw(struct iio_dev *indio_dev,
  * @chan:	the channel whose data is to be written
  * @val:	first element of value to set (typically INT)
  * @val2:	second element of value to set (typically MICRO)
- * @mask:	what we actually want to write. 0 is the channel, everything else
- *		is as per the info_mask in iio_chan_spec.
+ * @mask:	what we actually want to write as per the info_mask_*
+ *		in iio_chan_spec.
  *
  * Note that all raw writes are assumed IIO_VAL_INT and info mask elements
  * are assumed to be IIO_INT_PLUS_MICRO unless the callback write_raw_get_fmt
Signature · 1 line
1.8.1.1
author maintainer
#4 lore raw

PATCH 4/67 iio:hid_sensors move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc srinivas pandruvada <[email protected]>
---
 drivers/iio/accel/hid-sensor-accel-3d.c       | 24 ++++++++++++------------
 drivers/iio/gyro/hid-sensor-gyro-3d.c         | 24 ++++++++++++------------
 drivers/iio/light/hid-sensor-als.c            |  8 ++++----
 drivers/iio/magnetometer/hid-sensor-magn-3d.c | 24 ++++++++++++------------
 4 files changed, 40 insertions(+), 40 deletions(-)
drivers/iio/accel/hid-sensor-accel-3d.c +12 -12
index dd8ea42..7be0482 100644
@@ -60,28 +60,28 @@ static const struct iio_chan_spec accel_3d_channels[] = {
 		.type = IIO_ACCEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_X,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_X,
 	}, {
 		.type = IIO_ACCEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Y,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Y,
 	}, {
 		.type = IIO_ACCEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Z,
 	}
 };
drivers/iio/gyro/hid-sensor-gyro-3d.c +12 -12
index fcfc83a..3a324ae 100644
@@ -60,28 +60,28 @@ static const struct iio_chan_spec gyro_3d_channels[] = {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_X,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_X,
 	}, {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Y,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Y,
 	}, {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Z,
 	}
 };
drivers/iio/light/hid-sensor-als.c +4 -4
index 3d7e8c9..482dcff 100644
@@ -49,10 +49,10 @@ static const struct iio_chan_spec als_channels[] = {
 		.type = IIO_INTENSITY,
 		.modified = 1,
 		.channel2 = IIO_MOD_LIGHT_BOTH,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_ILLUM,
 	}
 };
drivers/iio/magnetometer/hid-sensor-magn-3d.c +12 -12
index d8d0126..950dab5 100644
@@ -60,28 +60,28 @@ static const struct iio_chan_spec magn_3d_channels[] = {
 		.type = IIO_MAGN,
 		.modified = 1,
 		.channel2 = IIO_MOD_X,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_X,
 	}, {
 		.type = IIO_MAGN,
 		.modified = 1,
 		.channel2 = IIO_MOD_Y,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Y,
 	}, {
 		.type = IIO_MAGN,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SHARED_BIT |
-		IIO_CHAN_INFO_HYSTERESIS_SHARED_BIT,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE |
+		IIO_CHAN_INFO_SAMP_FREQ |
+		IIO_CHAN_INFO_HYSTERESIS,
 		.scan_index = CHANNEL_SCAN_INDEX_Z,
 	}
 };
Signature · 1 line
1.8.1.1
author maintainer
#5 lore raw

PATCH 5/67 iio:accel:kxsd9 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/accel/kxsd9.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/iio/accel/kxsd9.c +3 -3
index c2229a5..c0902d6 100644
@@ -177,8 +177,8 @@ error_ret:
 		.type = IIO_ACCEL,					\
 		.modified = 1,						\
 		.channel2 = IIO_MOD_##axis,				\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-			IIO_CHAN_INFO_SCALE_SHARED_BIT,			\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.address = KXSD9_REG_##axis,				\
 	}
 
@@ -186,7 +186,7 @@ static const struct iio_chan_spec kxsd9_channels[] = {
 	KXSD9_ACCEL_CHAN(X), KXSD9_ACCEL_CHAN(Y), KXSD9_ACCEL_CHAN(Z),
 	{
 		.type = IIO_VOLTAGE,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.indexed = 1,
 		.address = KXSD9_REG_AUX,
 	}
Signature · 1 line
1.8.1.1
author maintainer
#6 lore raw

PATCH 6/67 iio:st_sensors move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 include/linux/iio/common/st_sensors.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
include/linux/iio/common/st_sensors.h +2 -2
index 1f86a97..0894b3e 100644
@@ -45,8 +45,8 @@
 { \
 	.type = device_type, \
 	.modified = 1, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_SCALE, \
 	.scan_index = index, \
 	.channel2 = mod, \
 	.address = addr, \
Signature · 1 line
1.8.1.1
Acked-by on v1 6/67
#7 lore raw

Re: [PATCH 06/67] iio:st_sensors move to info_mask_(shared_by_type/separate)

Quoted 1 line · Jonathan Cameron

The original info_mask is going away in favour of the broken out versions=

.

include/linux/iio/co=

Quoted 8 lines
---
  include/linux/iio/common/st_sensors.h | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
include/linux/iio/co= renamed from include/linux/iio/common/st_sensors.h +0 -0

mmon/st_sensors.h

Quoted 5 lines

index 1f86a97..0894b3e 100644

include/linux/iio/common/st_sensors.h line 52

Quoted 10 lines
include/linux/iio/common/st_sensors.h +2 -2
@@ -45,8 +45,8 @@
  { \
  	.type =3D device_type, \
  	.modified =3D 1, \
-	.info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+	.info_mask_separate =3D IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_SCALE, \
  	.scan_index =3D index, \
  	.channel2 =3D mod, \
  	.address =3D addr, \

Looks good to me.

author maintainer
#8 lore raw

PATCH 7/67 iio:adc:ad_sigma_delta move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 include/linux/iio/adc/ad_sigma_delta.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
include/linux/iio/adc/ad_sigma_delta.h +3 -3
index 2e4eab9..23a6555 100644
@@ -133,9 +133,9 @@ int ad_sd_validate_trigger(struct iio_dev *indio_dev, struct iio_trigger *trig);
 		.channel2 = (_channel2), \
 		.address = (_address), \
 		.extend_name = (_extend_name), \
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT, \
+		.info_mask_separate = IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_OFFSET, \
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 		.scan_index = (_si), \
 		.scan_type = { \
 			.sign = 'u', \
Signature · 1 line
1.8.1.1
author maintainer
#9 lore raw

PATCH 8/67 iio:adc:ad7266 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/adc/ad7266.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/iio/adc/ad7266.c +6 -6
index bbad9b9..9c64a3c 100644
@@ -201,9 +201,9 @@ static int ad7266_read_raw(struct iio_dev *indio_dev,
 	.indexed = 1,					\
 	.channel = (_chan),				\
 	.address = (_chan),				\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT	\
-		| IIO_CHAN_INFO_SCALE_SHARED_BIT	\
-		| IIO_CHAN_INFO_OFFSET_SHARED_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW,	\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE \
+		| IIO_CHAN_INFO_OFFSET,			\
 	.scan_index = (_chan),				\
 	.scan_type = {					\
 		.sign = (_sign),			\
@@ -249,9 +249,9 @@ static AD7266_DECLARE_SINGLE_ENDED_CHANNELS_FIXED(s, 's');
 	.channel = (_chan) * 2,				\
 	.channel2 = (_chan) * 2 + 1,			\
 	.address = (_chan),				\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT	\
-		| IIO_CHAN_INFO_SCALE_SHARED_BIT	\
-		| IIO_CHAN_INFO_OFFSET_SHARED_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW, 	\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE	\
+		| IIO_CHAN_INFO_OFFSET,			\
 	.scan_index = (_chan),				\
 	.scan_type = {					\
 		.sign = _sign,			\
Signature · 1 line
1.8.1.1
author maintainer
#10 lore raw

PATCH 9/67 iio:adc:ad7298 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/adc/ad7298.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/adc/ad7298.c +5 -5
index b34d754..463ec7f 100644
@@ -63,8 +63,8 @@ struct ad7298_state {
 		.type = IIO_VOLTAGE,					\
 		.indexed = 1,						\
 		.channel = index,					\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,				\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.address = index,					\
 		.scan_index = index,					\
 		.scan_type = {						\
@@ -80,9 +80,9 @@ static const struct iio_chan_spec ad7298_channels[] = {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_OFFSET,
 		.address = AD7298_CH_TEMP,
 		.scan_index = -1,
 		.scan_type = {
Signature · 1 line
1.8.1.1
author maintainer
#11 lore raw

PATCH 10/67 iio:adc:ad7476 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/adc/ad7476.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/adc/ad7476.c +5 -5
index 1491fa6..688a114 100644
@@ -140,12 +140,12 @@ static int ad7476_read_raw(struct iio_dev *indio_dev,
 	return -EINVAL;
 }
 
-#define _AD7476_CHAN(bits, _shift, _info_mask)			\
+#define _AD7476_CHAN(bits, _shift, _info_mask_sep)		\
 	{							\
 	.type = IIO_VOLTAGE,					\
 	.indexed = 1,						\
-	.info_mask = _info_mask |				\
-	IIO_CHAN_INFO_SCALE_SHARED_BIT,				\
+	.info_mask_separate = _info_mask_sep,			\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 	.scan_type = {						\
 		.sign = 'u',					\
 		.realbits = (bits),				\
@@ -156,9 +156,9 @@ static int ad7476_read_raw(struct iio_dev *indio_dev,
 }
 
 #define AD7476_CHAN(bits) _AD7476_CHAN((bits), 13 - (bits), \
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT)
+		IIO_CHAN_INFO_RAW)
 #define AD7940_CHAN(bits) _AD7476_CHAN((bits), 15 - (bits), \
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT)
+		IIO_CHAN_INFO_RAW)
 #define AD7091R_CHAN(bits) _AD7476_CHAN((bits), 16 - (bits), 0)
 
 static const struct ad7476_chip_info ad7476_chip_info_tbl[] = {
Signature · 1 line
1.8.1.1
author maintainer
#12 lore raw

PATCH 11/67 iio:adc:ad7887 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/adc/ad7887.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/iio/adc/ad7887.c +4 -4
index a33d5cd..e736971 100644
@@ -207,8 +207,8 @@ static const struct ad7887_chip_info ad7887_chip_info_tbl[] = {
 			.type = IIO_VOLTAGE,
 			.indexed = 1,
 			.channel = 1,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SHARED_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
+			.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 			.address = 1,
 			.scan_index = 1,
 			.scan_type = IIO_ST('u', 12, 16, 0),
@@ -217,8 +217,8 @@ static const struct ad7887_chip_info ad7887_chip_info_tbl[] = {
 			.type = IIO_VOLTAGE,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SHARED_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
+			.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 			.address = 0,
 			.scan_index = 0,
 			.scan_type = IIO_ST('u', 12, 16, 0),
Signature · 1 line
1.8.1.1
author maintainer
#13 lore raw

PATCH 12/67 iio:adc:at91_adc move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/at91_adc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/adc/at91_adc.c +2 -2
index a526c0e..65095a0 100644
@@ -140,8 +140,8 @@ static int at91_adc_channel_init(struct iio_dev *idev)
 		chan->scan_type.sign = 'u';
 		chan->scan_type.realbits = 10;
 		chan->scan_type.storagebits = 16;
-		chan->info_mask = IIO_CHAN_INFO_SCALE_SHARED_BIT |
-			IIO_CHAN_INFO_RAW_SEPARATE_BIT;
+		chan->info_mask_shared_by_type = IIO_CHAN_INFO_SCALE;
+		chan->info_mask_separate = IIO_CHAN_INFO_RAW;
 		idx++;
 	}
 	timestamp = chan_array + idx;
Signature · 1 line
1.8.1.1
author maintainer
#14 lore raw

PATCH 13/67 iio:adc:lp8778_adc move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Milo(Woogyom) Kim <[email protected]>
---
 drivers/iio/adc/lp8788_adc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/adc/lp8788_adc.c +2 -2
index 763f575..c0f0a7e 100644
@@ -132,8 +132,8 @@ static const struct iio_info lp8788_adc_info = {
 		.type = _type,					\
 		.indexed = 1,					\
 		.channel = LPADC_##_id,				\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,	\
+		.info_mask_separate = IIO_CHAN_INFO_RAW |	\
+			IIO_CHAN_INFO_SCALE,	\
 		.datasheet_name = #_id,				\
 }
 
Signature · 1 line
1.8.1.1
author maintainer
#15 lore raw

PATCH 14/67 iio:adc:ti-adc081 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/ti-adc081c.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/adc/ti-adc081c.c +2 -2
index f4a46dd..893ba16 100644
@@ -55,8 +55,8 @@ static int adc081c_read_raw(struct iio_dev *iio,
 
 static const struct iio_chan_spec adc081c_channel = {
 	.type = IIO_VOLTAGE,
-	.info_mask = IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		     IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
+	.info_mask_separate = IIO_CHAN_INFO_RAW,
 };
 
 static const struct iio_info adc081c_info = {
Signature · 1 line
1.8.1.1
Acked-by on v1 14/67
#16 lore raw

Re: [PATCH 14/67] iio:adc:ti-adc081 move to info_mask_(shared_by_type/separate)

Quoted 13 lines · Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/ti-adc081c.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/adc/ti-adc081c.c +0 -0
index f4a46dd..893ba16 100644

drivers/iio/adc/ti-adc081c.c static int adc081c_read_raw(struct iio_dev *iio, · line 62

Quoted 10 lines
drivers/iio/adc/ti-adc081c.c +2 -2
@@ -55,8 +55,8 @@ static int adc081c_read_raw(struct iio_dev *iio,
 
 static const struct iio_chan_spec adc081c_channel = {
 	.type = IIO_VOLTAGE,
-	.info_mask = IIO_CHAN_INFO_SCALE_SHARED_BIT |
-		     IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
+	.info_mask_separate = IIO_CHAN_INFO_RAW,
 };
 
 static const struct iio_info adc081c_info = {
author maintainer
#17 lore raw

PATCH 15/67 iio:adc:ti_am335x_adc move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/ti_am335x_adc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/adc/ti_am335x_adc.c +1 -1
index cd030e1..ff44dd7 100644
@@ -89,7 +89,7 @@ static int tiadc_channel_init(struct iio_dev *indio_dev, int channels)
 		chan->type = IIO_VOLTAGE;
 		chan->indexed = 1;
 		chan->channel = i;
-		chan->info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT;
+		chan->info_mask_separate = IIO_CHAN_INFO_RAW;
 	}
 
 	indio_dev->channels = chan_array;
Signature · 1 line
1.8.1.1
author maintainer
#18 lore raw

PATCH 16/67 iio:adc:viperboard_adc move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/adc/viperboard_adc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/adc/viperboard_adc.c +1 -1
index ad02615..cb2591f 100644
@@ -41,7 +41,7 @@ struct vprbrd_adc {
 	.type = IIO_VOLTAGE,				\
 	.indexed = 1,					\
 	.channel = _index,				\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW,	\
 	.scan_index = _index,				\
 	.scan_type = {					\
 		.sign = 'u',				\
Signature · 1 line
1.8.1.1
author maintainer
#19 lore raw

PATCH 17/67 iio:amplifiers:ad8366 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
---
 drivers/iio/amplifiers/ad8366.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/amplifiers/ad8366.c +1 -1
index d6c0af2..6c2610e 100644
@@ -125,7 +125,7 @@ static const struct iio_info ad8366_info = {
 	.output = 1,					\
 	.indexed = 1,					\
 	.channel = _channel,				\
-	.info_mask = IIO_CHAN_INFO_HARDWAREGAIN_SEPARATE_BIT,\
+	.info_mask_separate = IIO_CHAN_INFO_HARDWAREGAIN,\
 }
 
 static const struct iio_chan_spec ad8366_channels[] = {
Signature · 1 line
1.8.1.1
author maintainer
#20 lore raw

PATCH 18/67 iio:dac:ad5064 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5064.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/ad5064.c +2 -2
index 2fe1d4e..76e0836 100644
@@ -297,8 +297,8 @@ static const struct iio_chan_spec_ext_info ad5064_ext_info[] = {
 	.indexed = 1,						\
 	.output = 1,						\
 	.channel = (chan),					\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-	IIO_CHAN_INFO_SCALE_SEPARATE_BIT,			\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+	IIO_CHAN_INFO_SCALE,					\
 	.address = AD5064_ADDR_DAC(chan),			\
 	.scan_type = IIO_ST('u', (bits), 16, 20 - (bits)),	\
 	.ext_info = ad5064_ext_info,				\
Signature · 1 line
1.8.1.1
author maintainer
#21 lore raw

PATCH 19/67 iio:dac:ad5360 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5360.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/dac/ad5360.c +5 -5
index 9277121..1afa956 100644
@@ -102,11 +102,11 @@ enum ad5360_type {
 	.type = IIO_VOLTAGE,					\
 	.indexed = 1,						\
 	.output = 1,						\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |	\
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+		IIO_CHAN_INFO_SCALE |				\
+		IIO_CHAN_INFO_OFFSET |				\
+		IIO_CHAN_INFO_CALIBSCALE |			\
+		IIO_CHAN_INFO_CALIBBIAS,			\
 	.scan_type = IIO_ST('u', (bits), 16, 16 - (bits))	\
 }
 
Signature · 1 line
1.8.1.1
author maintainer
#22 lore raw

PATCH 20/67 iio:dac:ad5380 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5380.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/iio/dac/ad5380.c +4 -4
index 483fc37..91d2acf 100644
@@ -257,10 +257,10 @@ static struct iio_chan_spec_ext_info ad5380_ext_info[] = {
 	.type = IIO_VOLTAGE,					\
 	.indexed = 1,						\
 	.output = 1,						\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |		\
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,		\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+		IIO_CHAN_INFO_CALIBSCALE |			\
+		IIO_CHAN_INFO_CALIBBIAS,			\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 	.scan_type = IIO_ST('u', (_bits), 16, 14 - (_bits)),	\
 	.ext_info = ad5380_ext_info,				\
 }
Signature · 1 line
1.8.1.1
author maintainer
#23 lore raw

PATCH 21/67 iio:dac:ad5421 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5421.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/dac/ad5421.c +5 -5
index 6b86a63..903c18d 100644
@@ -86,11 +86,11 @@ static const struct iio_chan_spec ad5421_channels[] = {
 		.indexed = 1,
 		.output = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SHARED_BIT |
-			IIO_CHAN_INFO_OFFSET_SHARED_BIT |
-			IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_CALIBSCALE |
+			IIO_CHAN_INFO_CALIBBIAS,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_OFFSET,
 		.scan_type = IIO_ST('u', 16, 16, 0),
 		.event_mask = IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING) |
 			IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_FALLING),
Signature · 1 line
1.8.1.1
author maintainer
#24 lore raw

PATCH 22/67 iio:dac:ad5446 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5446.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/ad5446.c +2 -2
index f5583ae..2ead3e7 100644
@@ -143,8 +143,8 @@ static const struct iio_chan_spec_ext_info ad5446_ext_info_powerdown[] = {
 	.indexed = 1, \
 	.output = 1, \
 	.channel = 0, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-	IIO_CHAN_INFO_SCALE_SHARED_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 	.scan_type = IIO_ST('u', (bits), (storage), (shift)), \
 	.ext_info = (ext), \
 }
Signature · 1 line
1.8.1.1
author maintainer
#25 lore raw

PATCH 23/67 iio:dac:ad5449 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5449.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/ad5449.c +2 -2
index c4731b7..bcd4439 100644
@@ -206,8 +206,8 @@ static const struct iio_info ad5449_info = {
 	.indexed = 1,						\
 	.output = 1,						\
 	.channel = (chan),					\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,		\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+		IIO_CHAN_INFO_SCALE,		\
 	.address = (chan),					\
 	.scan_type = IIO_ST('u', (bits), 16, 12 - (bits)),	\
 }
Signature · 1 line
1.8.1.1
author maintainer
#26 lore raw

PATCH 24/67 iio:dac:ad5504 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5504.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/ad5504.c +2 -2
index e5e5974..296cbf9 100644
@@ -259,8 +259,8 @@ static const struct iio_chan_spec_ext_info ad5504_ext_info[] = {
 	.indexed = 1, \
 	.output = 1, \
 	.channel = (_chan), \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		     IIO_CHAN_INFO_SCALE_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 	.address = AD5504_ADDR_DAC(_chan), \
 	.scan_type = IIO_ST('u', 12, 16, 0), \
 	.ext_info = ad5504_ext_info, \
Signature · 1 line
1.8.1.1
author maintainer
#27 lore raw

PATCH 25/67 iio:dac:ad5624r move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5624r_spi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/ad5624r_spi.c +2 -2
index f6e1166..5998367 100644
@@ -174,8 +174,8 @@ static const struct iio_chan_spec_ext_info ad5624r_ext_info[] = {
 	.indexed = 1, \
 	.output = 1, \
 	.channel = (_chan), \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		     IIO_CHAN_INFO_SCALE_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 	.address = (_chan), \
 	.scan_type = IIO_ST('u', (_bits), 16, 16 - (_bits)), \
 	.ext_info = ad5624r_ext_info, \
Signature · 1 line
1.8.1.1
author maintainer
#28 lore raw

PATCH 26/67 iio:dac:ad5686 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5686.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/iio/dac/ad5686.c +3 -3
index 5e554af..17245b4 100644
@@ -276,9 +276,9 @@ static const struct iio_chan_spec_ext_info ad5686_ext_info[] = {
 		.indexed = 1,					\
 		.output = 1,					\
 		.channel = chan,				\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,			\
-		.address = AD5686_ADDR_DAC(chan),			\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,	\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,\
+		.address = AD5686_ADDR_DAC(chan),		\
 		.scan_type = IIO_ST('u', bits, 16, shift),	\
 		.ext_info = ad5686_ext_info,			\
 }
Signature · 1 line
1.8.1.1
author maintainer
#29 lore raw

PATCH 27/67 iio:dac:ad5755 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5755.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/dac/ad5755.c +5 -5
index 71faabc..0e9fcff 100644
@@ -393,11 +393,11 @@ static const struct iio_chan_spec_ext_info ad5755_ext_info[] = {
 #define AD5755_CHANNEL(_bits) {					\
 	.indexed = 1,						\
 	.output = 1,						\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,		\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+		IIO_CHAN_INFO_SCALE |		\
+		IIO_CHAN_INFO_OFFSET |		\
+		IIO_CHAN_INFO_CALIBSCALE |		\
+		IIO_CHAN_INFO_CALIBBIAS,		\
 	.scan_type = IIO_ST('u', (_bits), 16, 16 - (_bits)),	\
 	.ext_info = ad5755_ext_info,				\
 }
Signature · 1 line
1.8.1.1
author maintainer
#30 lore raw

PATCH 28/67 iio:dac:ad5764 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5764.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/dac/ad5764.c +5 -5
index 5b7acd3..5b8ba84 100644
@@ -78,11 +78,11 @@ enum ad5764_type {
 	.output = 1,						\
 	.channel = (_chan),					\
 	.address = (_chan),					\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_OFFSET_SHARED_BIT |		\
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |		\
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,		\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+		IIO_CHAN_INFO_OFFSET |				\
+		IIO_CHAN_INFO_SCALE |				\
+		IIO_CHAN_INFO_CALIBSCALE |			\
+		IIO_CHAN_INFO_CALIBBIAS,			\
 	.scan_type = IIO_ST('u', (_bits), 16, 16 - (_bits))	\
 }
 
Signature · 1 line
1.8.1.1
author maintainer
#31 lore raw

PATCH 29/67 iio:dac:ad5791 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/dac/ad5791.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/iio/dac/ad5791.c +3 -3
index 8dfd3da..1fbccd3 100644
@@ -302,9 +302,9 @@ static const struct iio_chan_spec_ext_info ad5791_ext_info[] = {
 	.indexed = 1,					\
 	.address = AD5791_ADDR_DAC0,			\
 	.channel = 0,					\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-		IIO_CHAN_INFO_SCALE_SHARED_BIT |	\
-		IIO_CHAN_INFO_OFFSET_SHARED_BIT,	\
+	.info_mask_separate = IIO_CHAN_INFO_RAW,	\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE |	\
+		IIO_CHAN_INFO_OFFSET,			\
 	.scan_type = IIO_ST('u', bits, 24, shift),	\
 	.ext_info = ad5791_ext_info,			\
 }
Signature · 1 line
1.8.1.1
author maintainer
#32 lore raw

PATCH 30/67 iio:dac:max517 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/dac/max517.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/max517.c +2 -2
index 352abe2..877053c 100644
@@ -146,8 +146,8 @@ static const struct iio_info max517_info = {
 	.indexed = 1,					\
 	.output = 1,					\
 	.channel = (chan),				\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-	IIO_CHAN_INFO_SCALE_SEPARATE_BIT,		\
+	.info_mask_separate = IIO_CHAN_INFO_RAW |	\
+	IIO_CHAN_INFO_SCALE,				\
 	.scan_type = IIO_ST('u', 8, 8, 0),		\
 }
 
Signature · 1 line
1.8.1.1
author maintainer
#33 lore raw

PATCH 31/67 iio:dac:mcp4725 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/dac/mcp4725.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/dac/mcp4725.c +2 -2
index 8f88cc4..ae89646 100644
@@ -69,8 +69,8 @@ static const struct iio_chan_spec mcp4725_channel = {
 	.indexed	= 1,
 	.output		= 1,
 	.channel	= 0,
-	.info_mask	= IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			  IIO_CHAN_INFO_SCALE_SHARED_BIT,
+	.info_mask_separate = IIO_CHAN_INFO_RAW,
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 	.scan_type	= IIO_ST('u', 12, 16, 0),
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#34 lore raw

PATCH 32/67 iio:freq:ad9523 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/frequency/ad9523.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/iio/frequency/ad9523.c +4 -4
index 1ea132e..542da7d 100644
@@ -920,10 +920,10 @@ static int ad9523_setup(struct iio_dev *indio_dev)
 			st->ad9523_channels[i].channel = chan->channel_num;
 			st->ad9523_channels[i].extend_name =
 				chan->extended_name;
-			st->ad9523_channels[i].info_mask =
-				IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_PHASE_SEPARATE_BIT |
-				IIO_CHAN_INFO_FREQUENCY_SEPARATE_BIT;
+			st->ad9523_channels[i].info_mask_separate =
+				IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_PHASE |
+				IIO_CHAN_INFO_FREQUENCY;
 		}
 	}
 
Signature · 1 line
1.8.1.1
author maintainer
#35 lore raw

PATCH 33/67 iio:gyro:adis16080 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/gyro/adis16080.c | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)
drivers/iio/gyro/adis16080.c +11 -11
index 1861287..c0b58de 100644
@@ -136,32 +136,32 @@ static const struct iio_chan_spec adis16080_channels[] = {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE,
 		.address = ADIS16080_DIN_GYRO,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_OFFSET,
 		.address = ADIS16080_DIN_AIN1,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_OFFSET,
 		.address = ADIS16080_DIN_AIN2,
 	}, {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_OFFSET,
 		.address = ADIS16080_DIN_TEMP,
 	}
 };
Signature · 1 line
1.8.1.1
author maintainer
#36 lore raw

PATCH 34/67 iio:gyro:adis16136 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/gyro/adis16136.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iio/gyro/adis16136.c +7 -6
index 8cb0bcb..f7e6111 100644
@@ -357,10 +357,11 @@ static const struct iio_chan_spec adis16136_channels[] = {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_X,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SHARED_BIT |
-			IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_CALIBBIAS |
+			IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
+
 		.address = ADIS16136_REG_GYRO_OUT2,
 		.scan_index = ADIS16136_SCAN_GYRO,
 		.scan_type = {
@@ -373,8 +374,8 @@ static const struct iio_chan_spec adis16136_channels[] = {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE,
 		.address = ADIS16136_REG_TEMP_OUT,
 		.scan_index = ADIS16136_SCAN_TEMP,
 		.scan_type = {
Signature · 1 line
1.8.1.1
author maintainer
#37 lore raw

PATCH 35/67 iio:gyro:adxrs450 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/gyro/adxrs450.c | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)
drivers/iio/gyro/adxrs450.c +11 -11
index 5b79953..101a71b 100644
@@ -383,16 +383,16 @@ static const struct iio_chan_spec adxrs450_channels[2][2] = {
 			.type = IIO_ANGL_VEL,
 			.modified = 1,
 			.channel2 = IIO_MOD_Z,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-			IIO_CHAN_INFO_QUADRATURE_CORRECTION_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_CALIBBIAS |
+			IIO_CHAN_INFO_QUADRATURE_CORRECTION_RAW |
+			IIO_CHAN_INFO_SCALE,
 		}, {
 			.type = IIO_TEMP,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE,
 		}
 	},
 	[ID_ADXRS453] = {
@@ -400,15 +400,15 @@ static const struct iio_chan_spec adxrs450_channels[2][2] = {
 			.type = IIO_ANGL_VEL,
 			.modified = 1,
 			.channel2 = IIO_MOD_Z,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			IIO_CHAN_INFO_QUADRATURE_CORRECTION_RAW_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE |
+			IIO_CHAN_INFO_QUADRATURE_CORRECTION_RAW,
 		}, {
 			.type = IIO_TEMP,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE,
 		}
 	},
 };
Signature · 1 line
1.8.1.1
author maintainer
#38 lore raw

PATCH 36/67 iio:gyro:itg3200_core move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/gyro/itg3200_core.c | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)
drivers/iio/gyro/itg3200_core.c +5 -8
index df2e6aa..6b8071b 100644
@@ -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_shared_by_type = IIO_CHAN_INFO_SCALE, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
 	.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 = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_OFFSET |
+		IIO_CHAN_INFO_SCALE,
 		.address = ITG3200_REG_TEMP_OUT_H,
 		.scan_index = ITG3200_SCAN_TEMP,
 		.scan_type = ITG3200_ST,
Signature · 1 line
1.8.1.1
author maintainer
#39 lore raw

PATCH 37/67 iio:imu:adis16400 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/imu/adis16400_core.c | 44 ++++++++++++++++++----------------------
 1 file changed, 20 insertions(+), 24 deletions(-)
drivers/iio/imu/adis16400_core.c +20 -24
index b7f215e..1a993af 100644
@@ -484,8 +484,7 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.indexed = 1, \
 	.channel = 0, \
 	.extend_name = name, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_SCALE, \
 	.address = (addr), \
 	.scan_index = (si), \
 	.scan_type = { \
@@ -507,10 +506,9 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.type = IIO_ANGL_VEL, \
 	.modified = 1, \
 	.channel2 = IIO_MOD_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_CALIBBIAS,  \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE | \
+		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY, \
 	.address = addr, \
 	.scan_index = ADIS16400_SCAN_GYRO_ ## mod, \
 	.scan_type = { \
@@ -526,10 +524,9 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.type = IIO_ACCEL, \
 	.modified = 1, \
 	.channel2 = IIO_MOD_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_CALIBBIAS, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE | \
+		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY, \
 	.address = (addr), \
 	.scan_index = ADIS16400_SCAN_ACC_ ## mod, \
 	.scan_type = { \
@@ -545,9 +542,9 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.type = IIO_MAGN, \
 	.modified = 1, \
 	.channel2 = IIO_MOD_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE | \
+		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY, \
 	.address = (addr), \
 	.scan_index = ADIS16400_SCAN_MAGN_ ## mod, \
 	.scan_type = { \
@@ -568,10 +565,10 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.indexed = 1, \
 	.channel = 0, \
 	.extend_name = ADIS16400_MOD_TEMP_NAME_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT | \
-		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_OFFSET | \
+		IIO_CHAN_INFO_SCALE, \
+	.info_mask_shared_by_type = \
+		IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY, \
 	.address = (addr), \
 	.scan_index = ADIS16350_SCAN_TEMP_ ## mod, \
 	.scan_type = { \
@@ -587,9 +584,8 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.type = IIO_TEMP, \
 	.indexed = 1, \
 	.channel = 0, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_OFFSET | \
+		IIO_CHAN_INFO_SCALE, \
 	.address = (addr), \
 	.scan_index = ADIS16350_SCAN_TEMP_X, \
 	.scan_type = { \
@@ -605,8 +601,8 @@ static int adis16400_read_raw(struct iio_dev *indio_dev,
 	.type = IIO_INCLI, \
 	.modified = 1, \
 	.channel2 = IIO_MOD_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SHARED_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 	.address = (addr), \
 	.scan_index = ADIS16300_SCAN_INCLI_ ## mod, \
 	.scan_type = { \
@@ -646,8 +642,8 @@ static const struct iio_chan_spec adis16448_channels[] = {
 	ADIS16400_MAGN_CHAN(Z, ADIS16400_ZMAGN_OUT, 16),
 	{
 		.type = IIO_PRESSURE,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = ADIS16448_BARO_OUT,
 		.scan_index = ADIS16400_SCAN_BARO,
 		.scan_type = IIO_ST('s', 16, 16, 0),
Signature · 1 line
1.8.1.1
author maintainer
#40 lore raw

PATCH 38/67 iio:imu:adis16480 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/iio/imu/adis16480.c | 32 ++++++++++++++++----------------
 1 file changed, 16 insertions(+), 16 deletions(-)
drivers/iio/imu/adis16480.c +16 -16
index 8c26a5f..f68680c 100644
@@ -591,15 +591,15 @@ static int adis16480_write_raw(struct iio_dev *indio_dev,
 	}
 }
 
-#define ADIS16480_MOD_CHANNEL(_type, _mod, _address, _si, _info, _bits) \
+#define ADIS16480_MOD_CHANNEL(_type, _mod, _address, _si, _info_sep, _bits) \
 	{ \
 		.type = (_type), \
 		.modified = 1, \
 		.channel2 = (_mod), \
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-			_info, \
+		.info_mask_separate = IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_CALIBBIAS | \
+			_info_sep, \
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.address = (_address), \
 		.scan_index = (_si), \
 		.scan_type = { \
@@ -613,21 +613,21 @@ static int adis16480_write_raw(struct iio_dev *indio_dev,
 #define ADIS16480_GYRO_CHANNEL(_mod) \
 	ADIS16480_MOD_CHANNEL(IIO_ANGL_VEL, IIO_MOD_ ## _mod, \
 	ADIS16480_REG_ ## _mod ## _GYRO_OUT, ADIS16480_SCAN_GYRO_ ## _mod, \
-	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SEPARATE_BIT | \
-	IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT, \
+	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY | \
+	IIO_CHAN_INFO_CALIBSCALE, \
 	32)
 
 #define ADIS16480_ACCEL_CHANNEL(_mod) \
 	ADIS16480_MOD_CHANNEL(IIO_ACCEL, IIO_MOD_ ## _mod, \
 	ADIS16480_REG_ ## _mod ## _ACCEL_OUT, ADIS16480_SCAN_ACCEL_ ## _mod, \
-	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SEPARATE_BIT | \
-	IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT, \
+	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY | \
+	IIO_CHAN_INFO_CALIBSCALE, \
 	32)
 
 #define ADIS16480_MAGN_CHANNEL(_mod) \
 	ADIS16480_MOD_CHANNEL(IIO_MAGN, IIO_MOD_ ## _mod, \
 	ADIS16480_REG_ ## _mod ## _MAGN_OUT, ADIS16480_SCAN_MAGN_ ## _mod, \
-	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY_SEPARATE_BIT, \
+	IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY, \
 	16)
 
 #define ADIS16480_PRESSURE_CHANNEL() \
@@ -635,9 +635,9 @@ static int adis16480_write_raw(struct iio_dev *indio_dev,
 		.type = IIO_PRESSURE, \
 		.indexed = 1, \
 		.channel = 0, \
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+		.info_mask_separate = IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_CALIBBIAS | \
+			IIO_CHAN_INFO_SCALE, \
 		.address = ADIS16480_REG_BAROM_OUT, \
 		.scan_index = ADIS16480_SCAN_BARO, \
 		.scan_type = { \
@@ -652,9 +652,9 @@ static int adis16480_write_raw(struct iio_dev *indio_dev,
 		.type = IIO_TEMP, \
 		.indexed = 1, \
 		.channel = 0, \
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT | \
-			IIO_CHAN_INFO_OFFSET_SEPARATE_BIT, \
+		.info_mask_separate = IIO_CHAN_INFO_RAW | \
+			IIO_CHAN_INFO_SCALE | \
+			IIO_CHAN_INFO_OFFSET, \
 		.address = ADIS16480_REG_TEMP_OUT, \
 		.scan_index = ADIS16480_SCAN_TEMP, \
 		.scan_type = { \
Signature · 1 line
1.8.1.1
author maintainer
#41 lore raw

PATCH 39/67 iio:imu:mpu6050 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/imu/inv_mpu6050/inv_mpu_core.c +5 -5
index 37ca05b..d05d01c 100644
@@ -544,8 +544,8 @@ static int inv_mpu6050_validate_trigger(struct iio_dev *indio_dev,
 		.type = _type,                                        \
 		.modified = 1,                                        \
 		.channel2 = _channel2,                                \
-		.info_mask =  IIO_CHAN_INFO_SCALE_SHARED_BIT          \
-				| IIO_CHAN_INFO_RAW_SEPARATE_BIT,     \
+		.info_mask_shared_by_type =  IIO_CHAN_INFO_SCALE,     \
+		.info_mask_separate = IIO_CHAN_INFO_RAW,              \
 		.scan_index = _index,                                 \
 		.scan_type = {                                        \
 				.sign = 's',                          \
@@ -564,9 +564,9 @@ static const struct iio_chan_spec inv_mpu_channels[] = {
 	 */
 	{
 		.type = IIO_TEMP,
-		.info_mask =  IIO_CHAN_INFO_RAW_SEPARATE_BIT
-				| IIO_CHAN_INFO_OFFSET_SEPARATE_BIT
-				| IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate =  IIO_CHAN_INFO_RAW
+				| IIO_CHAN_INFO_OFFSET
+				| IIO_CHAN_INFO_SCALE,
 		.scan_index = -1,
 	},
 	INV_MPU6050_CHAN(IIO_ANGL_VEL, IIO_MOD_X, INV_MPU6050_SCAN_GYRO_X),
Signature · 1 line
1.8.1.1
author maintainer
#42 lore raw

PATCH 40/67 iio:light:adjd_s311 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/light/adjd_s311.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/iio/light/adjd_s311.c +2 -2
index d5b9d39..8b4c5d2 100644
@@ -207,8 +207,8 @@ static const struct iio_chan_spec_ext_info adjd_s311_ext_info[] = {
 	.type = IIO_INTENSITY, \
 	.modified = 1, \
 	.address = (IDX_##_color), \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_HARDWAREGAIN_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | \
+		IIO_CHAN_INFO_HARDWAREGAIN, \
 	.channel2 = (IIO_MOD_LIGHT_##_color), \
 	.scan_index = (_scan_idx), \
 	.scan_type = IIO_ST('u', 10, 16, 0), \
Signature · 1 line
1.8.1.1
author maintainer
#43 lore raw

PATCH 41/67 iio:light:lm3533 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/light/lm3533-als.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/iio/light/lm3533-als.c +3 -3
index 7503012..b0d52e7 100644
@@ -231,7 +231,7 @@ static int lm3533_als_read_raw(struct iio_dev *indio_dev,
 		.channel	= _channel,				\
 		.indexed	= true,					\
 		.output		= true,					\
-		.info_mask	= IIO_CHAN_INFO_RAW_SEPARATE_BIT,	\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,	\
 	}
 
 static const struct iio_chan_spec lm3533_als_channels[] = {
@@ -239,8 +239,8 @@ static const struct iio_chan_spec lm3533_als_channels[] = {
 		.type		= IIO_LIGHT,
 		.channel	= 0,
 		.indexed	= true,
-		.info_mask	= (IIO_CHAN_INFO_AVERAGE_RAW_SEPARATE_BIT |
-				   IIO_CHAN_INFO_RAW_SEPARATE_BIT),
+		.info_mask_separate = (IIO_CHAN_INFO_AVERAGE_RAW |
+				   IIO_CHAN_INFO_RAW),
 	},
 	CHANNEL_CURRENT(0),
 	CHANNEL_CURRENT(1),
Signature · 1 line
1.8.1.1
author maintainer
#44 lore raw

PATCH 42/67 iio:light:tsl2563 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/light/tsl2563.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/iio/light/tsl2563.c +5 -5
index fd8be69..08463b4 100644
@@ -530,14 +530,14 @@ static const struct iio_chan_spec tsl2563_channels[] = {
 	{
 		.type = IIO_LIGHT,
 		.indexed = 1,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 		.channel = 0,
 	}, {
 		.type = IIO_INTENSITY,
 		.modified = 1,
 		.channel2 = IIO_MOD_LIGHT_BOTH,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE,
 		.event_mask = (IIO_EV_BIT(IIO_EV_TYPE_THRESH,
 					  IIO_EV_DIR_RISING) |
 			       IIO_EV_BIT(IIO_EV_TYPE_THRESH,
@@ -546,8 +546,8 @@ static const struct iio_chan_spec tsl2563_channels[] = {
 		.type = IIO_INTENSITY,
 		.modified = 1,
 		.channel2 = IIO_MOD_LIGHT_IR,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE,
 	}
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#45 lore raw

PATCH 43/67 iio:light:vcnl4000 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/iio/light/vcnl4000.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/iio/light/vcnl4000.c +3 -3
index 2aa748f..b3b7f46 100644
@@ -93,11 +93,11 @@ static int vcnl4000_measure(struct vcnl4000_data *data, u8 req_mask,
 static const struct iio_chan_spec vcnl4000_channels[] = {
 	{
 		.type = IIO_LIGHT,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+			IIO_CHAN_INFO_SCALE,
 	}, {
 		.type = IIO_PROXIMITY,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#46 lore raw

PATCH 44/67 staging:iio:accel:adis move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/accel/adis16201_core.c |  8 +++----
 drivers/staging/iio/accel/adis16203_core.c |  2 +-
 drivers/staging/iio/accel/adis16204_core.c |  8 +++----
 drivers/staging/iio/accel/adis16209_core.c |  4 ++--
 drivers/staging/iio/accel/adis16240_core.c |  9 +++-----
 drivers/staging/iio/gyro/adis16260_core.c  |  4 ++--
 include/linux/iio/imu/adis.h               | 34 +++++++++++++++---------------
 7 files changed, 32 insertions(+), 37 deletions(-)
drivers/staging/iio/accel/adis16201_core.c +4 -4
index 9e5791f..4200985 100644
@@ -134,14 +134,14 @@ static const struct iio_chan_spec adis16201_channels[] = {
 	ADIS_SUPPLY_CHAN(ADIS16201_SUPPLY_OUT, ADIS16201_SCAN_SUPPLY, 12),
 	ADIS_TEMP_CHAN(ADIS16201_TEMP_OUT, ADIS16201_SCAN_TEMP, 12),
 	ADIS_ACCEL_CHAN(X, ADIS16201_XACCL_OUT, ADIS16201_SCAN_ACC_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	ADIS_ACCEL_CHAN(Y, ADIS16201_YACCL_OUT, ADIS16201_SCAN_ACC_Y,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	ADIS_AUX_ADC_CHAN(ADIS16201_AUX_ADC, ADIS16201_SCAN_AUX_ADC, 12),
 	ADIS_INCLI_CHAN(X, ADIS16201_XINCL_OUT, ADIS16201_SCAN_INCLI_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	ADIS_INCLI_CHAN(X, ADIS16201_YINCL_OUT, ADIS16201_SCAN_INCLI_Y,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	IIO_CHAN_SOFT_TIMESTAMP(7)
 };
 
drivers/staging/iio/accel/adis16203_core.c +1 -1
index 8c23527..5e9c0f9 100644
@@ -102,7 +102,7 @@ static const struct iio_chan_spec adis16203_channels[] = {
 	ADIS_SUPPLY_CHAN(ADIS16203_SUPPLY_OUT, ADIS16203_SCAN_SUPPLY, 12),
 	ADIS_AUX_ADC_CHAN(ADIS16203_AUX_ADC, ADIS16203_SCAN_AUX_ADC, 12),
 	ADIS_INCLI_CHAN(X, ADIS16203_XINCL_OUT, ADIS16203_SCAN_INCLI_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	/* Fixme: Not what it appears to be - see data sheet */
 	ADIS_INCLI_CHAN(Y, ADIS16203_YINCL_OUT, ADIS16203_SCAN_INCLI_Y, 0, 14),
 	ADIS_TEMP_CHAN(ADIS16203_TEMP_OUT, ADIS16203_SCAN_TEMP, 12),
drivers/staging/iio/accel/adis16204_core.c +3 -5
index f359266..6e905c3 100644
@@ -140,13 +140,11 @@ static const struct iio_chan_spec adis16204_channels[] = {
 	ADIS_AUX_ADC_CHAN(ADIS16204_AUX_ADC, ADIS16204_SCAN_AUX_ADC, 12),
 	ADIS_TEMP_CHAN(ADIS16204_TEMP_OUT, ADIS16204_SCAN_TEMP, 12),
 	ADIS_ACCEL_CHAN(X, ADIS16204_XACCL_OUT, ADIS16204_SCAN_ACC_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS | IIO_CHAN_INFO_PEAK, 14),
 	ADIS_ACCEL_CHAN(Y, ADIS16204_YACCL_OUT, ADIS16204_SCAN_ACC_Y,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS | IIO_CHAN_INFO_PEAK, 14),
 	ADIS_ACCEL_CHAN(ROOT_SUM_SQUARED_X_Y, ADIS16204_XY_RSS_OUT,
-		ADIS16204_SCAN_ACC_XY, IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 14),
+		ADIS16204_SCAN_ACC_XY, IIO_CHAN_INFO_PEAK, 14),
 	IIO_CHAN_SOFT_TIMESTAMP(5),
 };
 
drivers/staging/iio/accel/adis16209_core.c +2 -2
index 69c50ee..baf1dc7 100644
@@ -133,9 +133,9 @@ static const struct iio_chan_spec adis16209_channels[] = {
 	ADIS_SUPPLY_CHAN(ADIS16209_SUPPLY_OUT, ADIS16209_SCAN_SUPPLY, 14),
 	ADIS_TEMP_CHAN(ADIS16209_TEMP_OUT, ADIS16209_SCAN_TEMP, 12),
 	ADIS_ACCEL_CHAN(X, ADIS16209_XACCL_OUT, ADIS16209_SCAN_ACC_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	ADIS_ACCEL_CHAN(Y, ADIS16209_YACCL_OUT, ADIS16209_SCAN_ACC_Y,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT, 14),
+		IIO_CHAN_INFO_CALIBBIAS, 14),
 	ADIS_AUX_ADC_CHAN(ADIS16209_AUX_ADC, ADIS16209_SCAN_AUX_ADC, 12),
 	ADIS_INCLI_CHAN(X, ADIS16209_XINCL_OUT, ADIS16209_SCAN_INCLI_X, 0, 14),
 	ADIS_INCLI_CHAN(Y, ADIS16209_YINCL_OUT, ADIS16209_SCAN_INCLI_Y, 0, 14),
drivers/staging/iio/accel/adis16240_core.c +3 -6
index e97fa0b..3550aff 100644
@@ -176,14 +176,11 @@ static const struct iio_chan_spec adis16240_channels[] = {
 	ADIS_SUPPLY_CHAN(ADIS16240_SUPPLY_OUT, ADIS16240_SCAN_SUPPLY, 10),
 	ADIS_AUX_ADC_CHAN(ADIS16240_AUX_ADC, ADIS16240_SCAN_AUX_ADC, 10),
 	ADIS_ACCEL_CHAN(X, ADIS16240_XACCL_OUT, ADIS16240_SCAN_ACC_X,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 10),
+		IIO_CHAN_INFO_CALIBBIAS | IIO_CHAN_INFO_PEAK, 10),
 	ADIS_ACCEL_CHAN(Y, ADIS16240_YACCL_OUT, ADIS16240_SCAN_ACC_Y,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 10),
+		IIO_CHAN_INFO_CALIBBIAS | IIO_CHAN_INFO_PEAK, 10),
 	ADIS_ACCEL_CHAN(Z, ADIS16240_ZACCL_OUT, ADIS16240_SCAN_ACC_Z,
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_PEAK_SEPARATE_BIT, 10),
+		IIO_CHAN_INFO_CALIBBIAS | IIO_CHAN_INFO_PEAK, 10),
 	ADIS_TEMP_CHAN(ADIS16240_TEMP_OUT, ADIS16240_SCAN_TEMP, 10),
 	IIO_CHAN_SOFT_TIMESTAMP(6)
 };
drivers/staging/iio/gyro/adis16260_core.c +2 -2
index 6e80b8c..d2bda2c 100644
@@ -124,8 +124,8 @@ static IIO_DEVICE_ATTR(sampling_frequency_available,
 #define ADIS16260_GYRO_CHANNEL_SET(axis, mod)				\
 struct iio_chan_spec adis16260_channels_##axis[] = {		\
 	ADIS_GYRO_CHAN(mod, ADIS16260_GYRO_OUT, ADIS16260_SCAN_GYRO, \
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT | \
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT, 14), \
+		IIO_CHAN_INFO_CALIBBIAS | \
+		IIO_CHAN_INFO_CALIBSCALE, 14), \
 	ADIS_INCLI_CHAN(mod, ADIS16260_ANGL_OUT, ADIS16260_SCAN_ANGL, 0, 14), \
 	ADIS_TEMP_CHAN(ADIS16260_TEMP_OUT, ADIS16260_SCAN_TEMP, 12), \
 	ADIS_SUPPLY_CHAN(ADIS16260_SUPPLY_OUT, ADIS16260_SCAN_SUPPLY, 12), \
include/linux/iio/imu/adis.h +17 -17
index ff781dc..9d82c28 100644
@@ -162,8 +162,8 @@ int adis_single_conversion(struct iio_dev *indio_dev,
 	.indexed = 1, \
 	.channel = (chan), \
 	.extend_name = name, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | \
+		IIO_CHAN_INFO_SCALE, \
 	.address = (addr), \
 	.scan_index = (si), \
 	.scan_type = { \
@@ -184,9 +184,9 @@ int adis_single_conversion(struct iio_dev *indio_dev,
 	.type = IIO_TEMP, \
 	.indexed = 1, \
 	.channel = 0, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT | \
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | \
+		IIO_CHAN_INFO_SCALE | \
+		IIO_CHAN_INFO_OFFSET, \
 	.address = (addr), \
 	.scan_index = (si), \
 	.scan_type = { \
@@ -197,13 +197,13 @@ int adis_single_conversion(struct iio_dev *indio_dev,
 	}, \
 }
 
-#define ADIS_MOD_CHAN(_type, mod, addr, si, info, bits) { \
+#define ADIS_MOD_CHAN(_type, mod, addr, si, info_sep, bits) { \
 	.type = (_type), \
 	.modified = 1, \
 	.channel2 = IIO_MOD_ ## mod, \
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT | \
-		 IIO_CHAN_INFO_SCALE_SHARED_BIT | \
-		 info, \
+	.info_mask_separate = IIO_CHAN_INFO_RAW | \
+		 info_sep, \
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 	.address = (addr), \
 	.scan_index = (si), \
 	.scan_type = { \
@@ -214,17 +214,17 @@ int adis_single_conversion(struct iio_dev *indio_dev,
 	}, \
 }
 
-#define ADIS_ACCEL_CHAN(mod, addr, si, info, bits) \
-	ADIS_MOD_CHAN(IIO_ACCEL, mod, addr, si, info, bits)
+#define ADIS_ACCEL_CHAN(mod, addr, si, info_sep, bits) \
+	ADIS_MOD_CHAN(IIO_ACCEL, mod, addr, si, info_sep, bits)
 
-#define ADIS_GYRO_CHAN(mod, addr, si, info, bits) \
-	ADIS_MOD_CHAN(IIO_ANGL_VEL, mod, addr, si, info, bits)
+#define ADIS_GYRO_CHAN(mod, addr, si, info_sep, bits) \
+	ADIS_MOD_CHAN(IIO_ANGL_VEL, mod, addr, si, info_sep, bits)
 
-#define ADIS_INCLI_CHAN(mod, addr, si, info, bits) \
-	ADIS_MOD_CHAN(IIO_INCLI, mod, addr, si, info, bits)
+#define ADIS_INCLI_CHAN(mod, addr, si, info_sep, bits) \
+	ADIS_MOD_CHAN(IIO_INCLI, mod, addr, si, info_sep, bits)
 
-#define ADIS_ROT_CHAN(mod, addr, si, info, bits) \
-	ADIS_MOD_CHAN(IIO_ROT, mod, addr, si, info, bits)
+#define ADIS_ROT_CHAN(mod, addr, si, info_sep, bits) \
+	ADIS_MOD_CHAN(IIO_ROT, mod, addr, si, info_sep, bits)
 
 #ifdef CONFIG_IIO_ADIS_LIB_BUFFER
 
Signature · 1 line
1.8.1.1
author maintainer
#47 lore raw

PATCH 45/67 staging:iio:accel:adis16220 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/accel/adis16220_core.c | 21 ++++++++-------------
 1 file changed, 8 insertions(+), 13 deletions(-)
drivers/staging/iio/accel/adis16220_core.c +8 -13
index 370b01a..0f0fb81 100644
@@ -344,37 +344,32 @@ static const struct iio_chan_spec adis16220_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "supply",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_SCALE,
 		.address = in_supply,
 	}, {
 		.type = IIO_ACCEL,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SEPARATE_BIT |
-			     IIO_CHAN_INFO_PEAK_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_OFFSET |
+			     IIO_CHAN_INFO_SCALE | IIO_CHAN_INFO_PEAK,
 		.address = accel,
 	}, {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_OFFSET |
+			     IIO_CHAN_INFO_SCALE,
 		.address = temp,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_OFFSET |
+			     IIO_CHAN_INFO_SCALE,
 		.address = in_1,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 2,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = in_2,
 	}
 };
Signature · 1 line
1.8.1.1
author maintainer
#48 lore raw

PATCH 46/67 staging:iio:accel:lis3l02dq move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/accel/lis3l02dq_core.c | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)
drivers/staging/iio/accel/lis3l02dq_core.c +4 -7
index 0e01930..b11ef95 100644
@@ -501,12 +501,6 @@ static irqreturn_t lis3l02dq_event_handler(int irq, void *private)
 	return IRQ_HANDLED;
 }
 
-#define LIS3L02DQ_INFO_MASK				\
-	(IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-	 IIO_CHAN_INFO_SCALE_SHARED_BIT |		\
-	 IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |	\
-	 IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT)
-
 #define LIS3L02DQ_EVENT_MASK					\
 	(IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING) |	\
 	 IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_FALLING))
@@ -516,7 +510,10 @@ static irqreturn_t lis3l02dq_event_handler(int irq, void *private)
 		.type = IIO_ACCEL,				\
 		.modified = 1,					\
 		.channel2 = mod,				\
-		.info_mask =  LIS3L02DQ_INFO_MASK,		\
+		.info_mask_separate = IIO_CHAN_INFO_RAW |	\
+			IIO_CHAN_INFO_CALIBSCALE |		\
+			IIO_CHAN_INFO_CALIBBIAS,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \
 		.address = index,				\
 		.scan_index = index,				\
 		.scan_type = {					\
Signature · 1 line
1.8.1.1
author maintainer
#49 lore raw

PATCH 47/67 staging:iio:accel:sca3000 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/accel/sca3000_core.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/staging/iio/accel/sca3000_core.c +2 -3
index 14683f5..68c8b7b 100644
@@ -419,8 +419,6 @@ static IIO_DEVICE_ATTR(measurement_mode, S_IRUGO | S_IWUSR,
 
 static IIO_DEVICE_ATTR(revision, S_IRUGO, sca3000_show_rev, NULL, 0);
 
-#define SCA3000_INFO_MASK			\
-	IIO_CHAN_INFO_RAW_SEPARATE_BIT | IIO_CHAN_INFO_SCALE_SHARED_BIT
 #define SCA3000_EVENT_MASK					\
 	(IIO_EV_BIT(IIO_EV_TYPE_MAG, IIO_EV_DIR_RISING))
 
@@ -429,7 +427,8 @@ static IIO_DEVICE_ATTR(revision, S_IRUGO, sca3000_show_rev, NULL, 0);
 		.type = IIO_ACCEL,				\
 		.modified = 1,					\
 		.channel2 = mod,				\
-		.info_mask = SCA3000_INFO_MASK,			\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,	\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,\
 		.address = index,				\
 		.scan_index = index,				\
 		.scan_type = {					\
Signature · 1 line
1.8.1.1
author maintainer
#50 lore raw

PATCH 48/67 staging:iio:adc:ad7280a move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/adc/ad7280a.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/staging/iio/adc/ad7280a.c +6 -6
index 1f190c1..41a791a 100644
@@ -503,9 +503,10 @@ static int ad7280_channel_init(struct ad7280_state *st)
 				st->channels[cnt].channel = (dev * 6) + ch - 6;
 			}
 			st->channels[cnt].indexed = 1;
-			st->channels[cnt].info_mask =
-				IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_SCALE_SHARED_BIT;
+			st->channels[cnt].info_mask_separate =
+				IIO_CHAN_INFO_RAW;
+			st->channels[cnt].info_mask_shared_by_type =
+				IIO_CHAN_INFO_SCALE;
 			st->channels[cnt].address =
 				AD7280A_DEVADDR(dev) << 8 | ch;
 			st->channels[cnt].scan_index = cnt;
@@ -521,9 +522,8 @@ static int ad7280_channel_init(struct ad7280_state *st)
 	st->channels[cnt].channel2 = dev * 6;
 	st->channels[cnt].address = AD7280A_ALL_CELLS;
 	st->channels[cnt].indexed = 1;
-	st->channels[cnt].info_mask =
-		IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT;
+	st->channels[cnt].info_mask_separate = IIO_CHAN_INFO_RAW;
+	st->channels[cnt].info_mask_shared_by_type = IIO_CHAN_INFO_SCALE;
 	st->channels[cnt].scan_index = cnt;
 	st->channels[cnt].scan_type.sign = 'u';
 	st->channels[cnt].scan_type.realbits = 32;
Signature · 1 line
1.8.1.1
author maintainer
#51 lore raw

PATCH 49/67 staging:iio:ad7291 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/adc/ad7291.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/staging/iio/adc/ad7291.c +5 -5
index 6e58e36..14c57b49 100644
@@ -536,8 +536,8 @@ static int ad7291_read_raw(struct iio_dev *indio_dev,
 #define AD7291_VOLTAGE_CHAN(_chan)					\
 {									\
 	.type = IIO_VOLTAGE,						\
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |			\
-	IIO_CHAN_INFO_SCALE_SHARED_BIT,					\
+	.info_mask_separate = IIO_CHAN_INFO_RAW,			\
+	.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,		\
 	.indexed = 1,							\
 	.channel = _chan,						\
 	.event_mask = IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING)|\
@@ -555,9 +555,9 @@ static const struct iio_chan_spec ad7291_channels[] = {
 	AD7291_VOLTAGE_CHAN(7),
 	{
 		.type = IIO_TEMP,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_AVERAGE_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_AVERAGE_RAW |
+				IIO_CHAN_INFO_SCALE,
 		.indexed = 1,
 		.channel = 0,
 		.event_mask =
Signature · 1 line
1.8.1.1
author maintainer
#52 lore raw

PATCH 50/67 staging:iio:ad7606 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/adc/ad7606_core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/adc/ad7606_core.c +2 -2
index bae61cb..023a677 100644
@@ -235,8 +235,8 @@ static const struct attribute_group ad7606_attribute_group_range = {
 		.indexed = 1,					\
 		.channel = num,					\
 		.address = num,					\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |	\
-				IIO_CHAN_INFO_SCALE_SHARED_BIT, \
+		.info_mask_separate = IIO_CHAN_INFO_RAW,	\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,\
 		.scan_index = num,				\
 		.scan_type = IIO_ST('s', 16, 16, 0),		\
 	}
Signature · 1 line
1.8.1.1
author maintainer
#53 lore raw

PATCH 51/67 staging:iio:adc:ad799x move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/adc/ad799x_core.c | 76 +++++++++++++++++------------------
 1 file changed, 38 insertions(+), 38 deletions(-)
drivers/staging/iio/adc/ad799x_core.c +38 -38
index 077eedb..5ceaf04 100644
@@ -467,7 +467,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -475,7 +475,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -483,7 +483,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -491,7 +491,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -507,7 +507,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -515,7 +515,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -523,7 +523,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -531,7 +531,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -547,7 +547,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 8, 16, 4),
 			},
@@ -555,7 +555,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 8, 16, 4),
 			},
@@ -563,7 +563,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 8, 16, 4),
 			},
@@ -571,7 +571,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 8, 16, 4),
 			},
@@ -587,7 +587,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -596,7 +596,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -614,7 +614,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -624,7 +624,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.indexed = 1,
 				.channel = 1,
 				.scan_index = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
 			},
@@ -632,7 +632,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -641,7 +641,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -659,7 +659,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -668,7 +668,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -677,7 +677,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -686,7 +686,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -704,7 +704,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -713,7 +713,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -722,7 +722,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -731,7 +731,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 				.event_mask = AD799X_EV_MASK,
@@ -740,7 +740,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 4,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 4,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -748,7 +748,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 5,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 5,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -756,7 +756,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 6,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 6,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -764,7 +764,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 7,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 7,
 				.scan_type = IIO_ST('u', 10, 16, 2),
 			},
@@ -781,7 +781,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 0,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 0,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -790,7 +790,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 1,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 1,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -799,7 +799,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 2,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 2,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -808,7 +808,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 3,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 3,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 				.event_mask = AD799X_EV_MASK,
@@ -817,7 +817,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 4,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 4,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -825,7 +825,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 5,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 5,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -833,7 +833,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 6,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW,
 				.scan_index = 6,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
@@ -841,7 +841,7 @@ static const struct ad799x_chip_info ad799x_chip_info_tbl[] = {
 				.type = IIO_VOLTAGE,
 				.indexed = 1,
 				.channel = 7,
-				.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+				.info_mask_separate = IIO_CHAN_INFO_RAW ,
 				.scan_index = 7,
 				.scan_type = IIO_ST('u', 12, 16, 0),
 			},
Signature · 1 line
1.8.1.1
author maintainer
#54 lore raw

PATCH 52/67 staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/cdc/ad7150.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/staging/iio/cdc/ad7150.c +4 -4
index 3c608c1..05b24f8 100644
@@ -429,8 +429,8 @@ static const struct iio_chan_spec ad7150_channels[] = {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_AVERAGE_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_AVERAGE_RAW,
 		.event_mask =
 		IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING) |
 		IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_FALLING) |
@@ -442,8 +442,8 @@ static const struct iio_chan_spec ad7150_channels[] = {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_AVERAGE_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_AVERAGE_RAW,
 		.event_mask =
 		IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_RISING) |
 		IIO_EV_BIT(IIO_EV_TYPE_THRESH, IIO_EV_DIR_FALLING) |
Signature · 1 line
1.8.1.1
author maintainer
#55 lore raw

PATCH 53/67 staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/cdc/ad7152.c | 32 ++++++++++++++++----------------
 1 file changed, 16 insertions(+), 16 deletions(-)
drivers/staging/iio/cdc/ad7152.c +16 -16
index 3c92ba3..69ddaef 100644
@@ -436,38 +436,38 @@ static const struct iio_chan_spec ad7152_channels[] = {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE |
+		IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 	}, {
 		.type = IIO_CAPACITANCE,
 		.differential = 1,
 		.indexed = 1,
 		.channel = 0,
 		.channel2 = 2,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE |
+		IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 	}, {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE |
+		IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 	}, {
 		.type = IIO_CAPACITANCE,
 		.differential = 1,
 		.indexed = 1,
 		.channel = 1,
 		.channel2 = 3,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE |
+		IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 	}
 };
 /*
Signature · 1 line
1.8.1.1
author maintainer
#56 lore raw

PATCH 54/67 staging:iio:cdc:ad7746 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/cdc/ad7746.c | 48 ++++++++++++++++++----------------------
 1 file changed, 22 insertions(+), 26 deletions(-)
drivers/staging/iio/cdc/ad7746.c +22 -26
index 466b82e..2789839 100644
@@ -123,8 +123,8 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_VT_DATA_HIGH << 8 |
 			AD7746_VTSETUP_VTMD_EXT_VIN,
 	},
@@ -133,8 +133,8 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "supply",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_VT_DATA_HIGH << 8 |
 			AD7746_VTSETUP_VTMD_VDD_MON,
 	},
@@ -142,7 +142,7 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 		.address = AD7746_REG_VT_DATA_HIGH << 8 |
 			AD7746_VTSETUP_VTMD_INT_TEMP,
 	},
@@ -150,7 +150,7 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 		.address = AD7746_REG_VT_DATA_HIGH << 8 |
 			AD7746_VTSETUP_VTMD_EXT_TEMP,
 	},
@@ -158,11 +158,10 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_CAP_DATA_HIGH << 8,
 	},
 	[CIN1_DIFF] = {
@@ -171,11 +170,10 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.channel2 = 2,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_CAP_DATA_HIGH << 8 |
 			AD7746_CAPSETUP_CAPDIFF
 	},
@@ -183,11 +181,10 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.type = IIO_CAPACITANCE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_CAP_DATA_HIGH << 8 |
 			AD7746_CAPSETUP_CIN2,
 	},
@@ -197,11 +194,10 @@ static const struct iio_chan_spec ad7746_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.channel2 = 3,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_CALIBBIAS |
+		IIO_CHAN_INFO_SCALE,
 		.address = AD7746_REG_CAP_DATA_HIGH << 8 |
 			AD7746_CAPSETUP_CAPDIFF | AD7746_CAPSETUP_CIN2,
 	}
Signature · 1 line
1.8.1.1
maintainer Acked-by on v1 54/67
#57 lore raw

RE: [PATCH 54/67] staging:iio:cdc:ad7746 move to info_mask_(shared_by_type/separate)

-----Original Message-----
From: Jonathan Cameron [mailto:[email protected]]=20
Sent: Mittwoch, 27. Februar 2013 21:39
To: [email protected]
Cc: Jonathan Cameron; Hennerich, Michael; Lars-Peter Clausen
Subject: [PATCH 54/67] staging:iio:cdc:ad7746 move to info_mask_(shared_by_= type/separate)

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>

All CC: me

---
drivers/staging/iio/cdc/ad7746.c | 48 ++++++++++++++++++------------------=
----

 1 file changed, 22 insertions(+), 26 deletions(-)
drivers/staging/iio/cdc/ad7= renamed from drivers/staging/iio/cdc/ad7746.c +0 -0

746.c
index 466b82e..2789839 100644

drivers/staging/iio/cdc/ad7746.c +2 -2
@@ -123,8 +123,8 @@ static const struct iio_chan_spec ad7746_channels[] =3D=
 {
 		.type =3D IIO_VOLTAGE,
 		.indexed =3D 1,
 		.channel =3D 0,
-		.info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate =3D IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type =3D IIO_CHAN_INFO_SCALE,
 		.address =3D AD7746_REG_VT_DATA_HIGH << 8 |
 			AD7746_VTSETUP_VTMD_EXT_VIN,

},
@@ -133,8 +133,8 @@ static const struct iio_chan_spec ad7746_channels[] =3D=
{
.indexed =3D 1,
.channel =3D 1,
.extend_name =3D "supply",
- .info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
- IIO_CHAN_INFO_SCALE_SHARED_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_RAW,
+ .info_mask_shared_by_type =3D IIO_CHAN_INFO_SCALE,
.address =3D AD7746_REG_VT_DATA_HIGH << 8 |
AD7746_VTSETUP_VTMD_VDD_MON,
},
@@ -142,7 +142,7 @@ static const struct iio_chan_spec ad7746_channels[] =3D=
{
.type =3D IIO_TEMP,
.indexed =3D 1,
.channel =3D 0,
- .info_mask =3D IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_PROCESSED,
.address =3D AD7746_REG_VT_DATA_HIGH << 8 |
AD7746_VTSETUP_VTMD_INT_TEMP,
},
@@ -150,7 +150,7 @@ static const struct iio_chan_spec ad7746_channels[] =3D=
{
.type =3D IIO_TEMP,
.indexed =3D 1,
.channel =3D 1,
- .info_mask =3D IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_PROCESSED,
.address =3D AD7746_REG_VT_DATA_HIGH << 8 |
AD7746_VTSETUP_VTMD_EXT_TEMP,
},
@@ -158,11 +158,10 @@ static const struct iio_chan_spec ad7746_channels[] = =3D {
.type =3D IIO_CAPACITANCE,
.indexed =3D 1,
.channel =3D 0,
- .info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
- IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
- IIO_CHAN_INFO_SCALE_SHARED_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_RAW |
+ IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+ .info_mask_shared_by_type =3D IIO_CHAN_INFO_CALIBBIAS |
+ IIO_CHAN_INFO_SCALE,
.address =3D AD7746_REG_CAP_DATA_HIGH << 8,
},
[CIN1_DIFF] =3D {
@@ -171,11 +170,10 @@ static const struct iio_chan_spec ad7746_channels[] = =3D {
.indexed =3D 1,
.channel =3D 0,
.channel2 =3D 2,
- .info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
- IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
- IIO_CHAN_INFO_SCALE_SHARED_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_RAW |
+ IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+ .info_mask_shared_by_type =3D IIO_CHAN_INFO_CALIBBIAS |
+ IIO_CHAN_INFO_SCALE,
.address =3D AD7746_REG_CAP_DATA_HIGH << 8 |
AD7746_CAPSETUP_CAPDIFF
},
@@ -183,11 +181,10 @@ static const struct iio_chan_spec ad7746_channels[] = =3D {
.type =3D IIO_CAPACITANCE,
.indexed =3D 1,
.channel =3D 1,
- .info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
- IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
- IIO_CHAN_INFO_SCALE_SHARED_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_RAW |
+ IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+ .info_mask_shared_by_type =3D IIO_CHAN_INFO_CALIBBIAS |
+ IIO_CHAN_INFO_SCALE,
.address =3D AD7746_REG_CAP_DATA_HIGH << 8 |
AD7746_CAPSETUP_CIN2,
},
@@ -197,11 +194,10 @@ static const struct iio_chan_spec ad7746_channels[] = =3D {
.indexed =3D 1,
.channel =3D 1,
.channel2 =3D 3,
- .info_mask =3D IIO_CHAN_INFO_RAW_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
- IIO_CHAN_INFO_CALIBBIAS_SHARED_BIT |
- IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
- IIO_CHAN_INFO_SCALE_SHARED_BIT,
+ .info_mask_separate =3D IIO_CHAN_INFO_RAW |
+ IIO_CHAN_INFO_CALIBSCALE | IIO_CHAN_INFO_OFFSET,
+ .info_mask_shared_by_type =3D IIO_CHAN_INFO_CALIBBIAS |
+ IIO_CHAN_INFO_SCALE,
.address =3D AD7746_REG_CAP_DATA_HIGH << 8 |
AD7746_CAPSETUP_CAPDIFF | AD7746_CAPSETUP_CIN2,
}
--=20
1.8.1.1

author maintainer
#58 lore raw

PATCH 55/67 staging:iio:gyro:adis16060 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/gyro/adis16060_core.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)
drivers/staging/iio/gyro/adis16060_core.c +5 -6
index 687c151..dfe8deb 100644
@@ -120,27 +120,26 @@ static const struct iio_chan_spec adis16060_channels[] = {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = ADIS16060_GYRO,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = ADIS16060_AIN1,
 	}, {
 		.type = IIO_VOLTAGE,
 		.indexed = 1,
 		.channel = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = ADIS16060_AIN2,
 	}, {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_OFFSET_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_OFFSET | IIO_CHAN_INFO_SCALE,
 		.address = ADIS16060_TEMP_OUT,
 	}
 };
Signature · 1 line
1.8.1.1
author maintainer
#59 lore raw

PATCH 56/67 staging:iio:gyro:adis16130 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/gyro/adis16130_core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/gyro/adis16130_core.c +2 -2
index 835801e..c0ae2c1 100644
@@ -100,13 +100,13 @@ static const struct iio_chan_spec adis16130_channels[] = {
 		.type = IIO_ANGL_VEL,
 		.modified = 1,
 		.channel2 = IIO_MOD_Z,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = ADIS16130_RATEDATA,
 	}, {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.address = ADIS16130_TEMPDATA,
 	}
 };
Signature · 1 line
1.8.1.1
author maintainer
#60 lore raw

PATCH 57/67 staging:iio:impedance:ad5933 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/impedance-analyzer/ad5933.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)
drivers/staging/iio/impedance-analyzer/ad5933.c +3 -5
index 440e226..fc90d6d 100644
@@ -113,7 +113,7 @@ static const struct iio_chan_spec ad5933_channels[] = {
 		.type = IIO_TEMP,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 		.address = AD5933_REG_TEMP_DATA,
 		.scan_type = {
 			.sign = 's',
@@ -125,8 +125,7 @@ static const struct iio_chan_spec ad5933_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "real_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_SCALE,
 		.address = AD5933_REG_REAL_DATA,
 		.scan_index = 0,
 		.scan_type = {
@@ -139,8 +138,7 @@ static const struct iio_chan_spec ad5933_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "imag_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW | IIO_CHAN_INFO_SCALE,
 		.address = AD5933_REG_IMAG_DATA,
 		.scan_index = 1,
 		.scan_type = {
Signature · 1 line
1.8.1.1
author maintainer
#61 lore raw

PATCH 58/67 staging:iio:light:isl29018 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/light/isl29018.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/staging/iio/light/isl29018.c +4 -4
index b0adac0..c1bf1d5 100644
@@ -412,17 +412,17 @@ static const struct iio_chan_spec isl29018_channels[] = {
 		.type = IIO_LIGHT,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED |
+		IIO_CHAN_INFO_CALIBSCALE,
 	}, {
 		.type = IIO_INTENSITY,
 		.modified = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 		.channel2 = IIO_MOD_LIGHT_IR,
 	}, {
 		/* Unindexed in current ABI.  But perhaps it should be. */
 		.type = IIO_PROXIMITY,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}
 };
 
Signature · 1 line
1.8.1.1
#62 lore raw

Re: [PATCH 58/67] staging:iio:light:isl29018 move to info_mask_(shared_by_type/separate)

Quoted 24 lines · Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
  drivers/staging/iio/light/isl29018.c | 8 ++++----
  1 file changed, 4 insertions(+), 4 deletions(-)
drivers/staging/iio/light/isl29018.c +2 -3
index b0adac0..c1bf1d5 100644
@@ -412,17 +412,17 @@ static const struct iio_chan_spec isl29018_channels[] = {
  		.type = IIO_LIGHT,
  		.indexed = 1,
  		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT |
-		IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED |
+		IIO_CHAN_INFO_CALIBSCALE,
  	}, {
  		.type = IIO_INTENSITY,
  		.modified = 1,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,

drivers/staging/iio/light/isl29018.c static const struct iio_chan_spec isl29018_channels[] = { · line 428

Quoted 10 lines
drivers/staging/iio/light/isl29018.c +2 -1
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
  		.channel2 = IIO_MOD_LIGHT_IR,
  	}, {
  		/* Unindexed in current ABI.  But perhaps it should be. */
  		.type = IIO_PROXIMITY,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
  	}
  };
 

looks good to me.

Acked-by Rhyland Klein <[email protected]>

Signature · 1 line
nvpublic
author maintainer
#63 lore raw

PATCH 59/67 staging:iio:isl29028 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/light/isl29028.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/staging/iio/light/isl29028.c +5 -5
index e52af77..c8787ea 100644
@@ -391,15 +391,15 @@ static const struct attribute_group isl29108_group = {
 static const struct iio_chan_spec isl29028_channels[] = {
 	{
 		.type = IIO_LIGHT,
-		.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT |
-		IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_PROCESSED |
+		IIO_CHAN_INFO_SCALE,
 	}, {
 		.type = IIO_INTENSITY,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}, {
 		.type = IIO_PROXIMITY,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-		IIO_CHAN_INFO_SAMP_FREQ_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW |
+		IIO_CHAN_INFO_SAMP_FREQ,
 	}
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#65 lore raw

PATCH 60/67 staging:iio:light:tsl2x7x move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/light/tsl2x7x_core.c | 40 ++++++++++++++++----------------
 1 file changed, 20 insertions(+), 20 deletions(-)
drivers/staging/iio/light/tsl2x7x_core.c +20 -20
index a58731e..3c38534 100644
@@ -1733,14 +1733,14 @@ static const struct tsl2x7x_chip_info tsl2x7x_chip_info_tbl[] = {
 			.type = IIO_LIGHT,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 			}, {
 			.type = IIO_INTENSITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_CALIBSCALE |
+				IIO_CHAN_INFO_CALIBBIAS,
 			.event_mask = TSL2X7X_EVENT_MASK
 			}, {
 			.type = IIO_INTENSITY,
@@ -1757,7 +1757,7 @@ static const struct tsl2x7x_chip_info tsl2x7x_chip_info_tbl[] = {
 			.type = IIO_PROXIMITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
 			.event_mask = TSL2X7X_EVENT_MASK
 			},
 		},
@@ -1770,25 +1770,25 @@ static const struct tsl2x7x_chip_info tsl2x7x_chip_info_tbl[] = {
 			.type = IIO_LIGHT,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT
+			.info_mask_separate = IIO_CHAN_INFO_PROCESSED
 			}, {
 			.type = IIO_INTENSITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_CALIBSCALE |
+				IIO_CHAN_INFO_CALIBBIAS,
 			.event_mask = TSL2X7X_EVENT_MASK
 			}, {
 			.type = IIO_INTENSITY,
 			.indexed = 1,
 			.channel = 1,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
 			}, {
 			.type = IIO_PROXIMITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
 			.event_mask = TSL2X7X_EVENT_MASK
 			},
 		},
@@ -1801,8 +1801,8 @@ static const struct tsl2x7x_chip_info tsl2x7x_chip_info_tbl[] = {
 			.type = IIO_PROXIMITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_CALIBSCALE,
 			.event_mask = TSL2X7X_EVENT_MASK
 			},
 		},
@@ -1815,26 +1815,26 @@ static const struct tsl2x7x_chip_info tsl2x7x_chip_info_tbl[] = {
 			.type = IIO_LIGHT,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_PROCESSED_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_PROCESSED,
 			}, {
 			.type = IIO_INTENSITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBBIAS_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_CALIBSCALE |
+				IIO_CHAN_INFO_CALIBBIAS,
 			.event_mask = TSL2X7X_EVENT_MASK
 			}, {
 			.type = IIO_INTENSITY,
 			.indexed = 1,
 			.channel = 1,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW,
 			}, {
 			.type = IIO_PROXIMITY,
 			.indexed = 1,
 			.channel = 0,
-			.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-				IIO_CHAN_INFO_CALIBSCALE_SEPARATE_BIT,
+			.info_mask_separate = IIO_CHAN_INFO_RAW |
+				IIO_CHAN_INFO_CALIBSCALE,
 			.event_mask = TSL2X7X_EVENT_MASK
 			},
 		},
Signature · 1 line
1.8.1.1
author maintainer
#66 lore raw

PATCH 61/67 staging:iio:mag:ak8975 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/magnetometer/ak8975.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/magnetometer/ak8975.c +2 -2
index 28f080e..22b40ee 100644
@@ -395,8 +395,8 @@ static int ak8975_read_raw(struct iio_dev *indio_dev,
 		.type = IIO_MAGN,					\
 		.modified = 1,						\
 		.channel2 = IIO_MOD_##axis,				\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-			     IIO_CHAN_INFO_SCALE_SEPARATE_BIT,		\
+		.info_mask_separate = IIO_CHAN_INFO_RAW |		\
+			     IIO_CHAN_INFO_SCALE,			\
 		.address = index,					\
 	}
 
Signature · 1 line
1.8.1.1
author maintainer
#67 lore raw

PATCH 62/67 staging:iio:hmc5843 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

---
 drivers/staging/iio/magnetometer/hmc5843.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/magnetometer/hmc5843.c +2 -2
index 1a520ec..66c0194 100644
@@ -564,8 +564,8 @@ static int hmc5843_read_raw(struct iio_dev *indio_dev,
 		.type = IIO_MAGN,					\
 		.modified = 1,						\
 		.channel2 = IIO_MOD_##axis,				\
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,		\
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
 		.address = add						\
 	}
 
Signature · 1 line
1.8.1.1
author maintainer
#68 lore raw

PATCH 63/67 staging:iio:meter:ade7758 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Lars-Peter Clausen <[email protected]>
---
 drivers/staging/iio/meter/ade7758_core.c | 60 ++++++++++++++++----------------
 1 file changed, 30 insertions(+), 30 deletions(-)
drivers/staging/iio/meter/ade7758_core.c +30 -30
index 53c68dc..2d27d20 100644
@@ -649,8 +649,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_A, AD7758_VOLTAGE),
 		.scan_index = 0,
 		.scan_type = {
@@ -663,8 +663,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_A, AD7758_CURRENT),
 		.scan_index = 1,
 		.scan_type = {
@@ -677,8 +677,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "apparent_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_A, AD7758_APP_PWR),
 		.scan_index = 2,
 		.scan_type = {
@@ -691,8 +691,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "active_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_A, AD7758_ACT_PWR),
 		.scan_index = 3,
 		.scan_type = {
@@ -705,8 +705,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 0,
 		.extend_name = "reactive_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_A, AD7758_REACT_PWR),
 		.scan_index = 4,
 		.scan_type = {
@@ -719,8 +719,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_B, AD7758_VOLTAGE),
 		.scan_index = 5,
 		.scan_type = {
@@ -733,8 +733,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_B, AD7758_CURRENT),
 		.scan_index = 6,
 		.scan_type = {
@@ -747,8 +747,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "apparent_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_B, AD7758_APP_PWR),
 		.scan_index = 7,
 		.scan_type = {
@@ -761,8 +761,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "active_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_B, AD7758_ACT_PWR),
 		.scan_index = 8,
 		.scan_type = {
@@ -775,8 +775,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 1,
 		.extend_name = "reactive_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_B, AD7758_REACT_PWR),
 		.scan_index = 9,
 		.scan_type = {
@@ -789,8 +789,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 2,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_C, AD7758_VOLTAGE),
 		.scan_index = 10,
 		.scan_type = {
@@ -803,8 +803,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 2,
 		.extend_name = "raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_C, AD7758_CURRENT),
 		.scan_index = 11,
 		.scan_type = {
@@ -817,8 +817,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 2,
 		.extend_name = "apparent_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_C, AD7758_APP_PWR),
 		.scan_index = 12,
 		.scan_type = {
@@ -831,8 +831,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 2,
 		.extend_name = "active_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_C, AD7758_ACT_PWR),
 		.scan_index = 13,
 		.scan_type = {
@@ -845,8 +845,8 @@ static const struct iio_chan_spec ade7758_channels[] = {
 		.indexed = 1,
 		.channel = 2,
 		.extend_name = "reactive_raw",
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |
-			     IIO_CHAN_INFO_SCALE_SHARED_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,
 		.address = AD7758_WT(AD7758_PHASE_C, AD7758_REACT_PWR),
 		.scan_index = 14,
 		.scan_type = {
Signature · 1 line
1.8.1.1
author maintainer
#69 lore raw

PATCH 64/67 staging:iio:resolver:ad2s1200 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
---
 drivers/staging/iio/resolver/ad2s1200.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/resolver/ad2s1200.c +2 -2
index 4fe3499..ff544fc 100644
@@ -85,12 +85,12 @@ static const struct iio_chan_spec ad2s1200_channels[] = {
 		.type = IIO_ANGL,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}, {
 		.type = IIO_ANGL_VEL,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#70 lore raw

PATCH 65/67 staging:iio:resolver:ad2s1210 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
---
 drivers/staging/iio/resolver/ad2s1210.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/iio/resolver/ad2s1210.c +2 -2
index 53110b6..bea9d63 100644
@@ -577,12 +577,12 @@ static const struct iio_chan_spec ad2s1210_channels[] = {
 		.type = IIO_ANGL,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}, {
 		.type = IIO_ANGL_VEL,
 		.indexed = 1,
 		.channel = 0,
-		.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+		.info_mask_separate = IIO_CHAN_INFO_RAW,
 	}
 };
 
Signature · 1 line
1.8.1.1
author maintainer
#71 lore raw

PATCH 66/67 staging:iio:ad2s90 move to info_mask_(shared_by_type/separate)

In reply to Jonathan Cameron

The original info_mask is going away in favour of the broken out versions.

cc Michael Hennerich <[email protected]>
---
 drivers/staging/iio/resolver/ad2s90.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/iio/resolver/ad2s90.c +1 -1
index 0aecfbc..ea55158 100644
@@ -55,7 +55,7 @@ static const struct iio_chan_spec ad2s90_chan = {
 	.type = IIO_ANGL,
 	.indexed = 1,
 	.channel = 0,
-	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT,
+	.info_mask_separate = IIO_CHAN_INFO_RAW,
 };
 
 static int ad2s90_probe(struct spi_device *spi)
Signature · 1 line
1.8.1.1
author maintainer
#72 lore raw

PATCH 67/67 iio:core drop info_mask from struct iio_info

In reply to Jonathan Cameron

This has been replaced by the pair of masks info_mask_separate and info_mask_shared_by_type. Other variants may follow.

---
 drivers/iio/industrialio-core.c | 17 ----------
 include/linux/iio/iio.h         | 73 +----------------------------------------
 2 files changed, 1 insertion(+), 89 deletions(-)
drivers/iio/industrialio-core.c +0 -17
index bfb9ccb..feb29ff 100644
@@ -691,23 +691,6 @@ static int iio_device_add_channel_sysfs(struct iio_dev *indio_dev,
 
 	if (chan->channel < 0)
 		return 0;
-	for_each_set_bit(i, &chan->info_mask, sizeof(long)*8) {
-		ret = __iio_add_chan_devattr(iio_chan_info_postfix[i/2],
-					     chan,
-					     &iio_read_channel_info,
-					     &iio_write_channel_info,
-					     i/2,
-					     !(i%2),
-					     &indio_dev->dev,
-					     &indio_dev->channel_attr_list);
-		if (ret == -EBUSY && (i%2 == 0)) {
-			ret = 0;
-			continue;
-		}
-		if (ret < 0)
-			goto error_ret;
-		attrcount++;
-	}
 	for_each_set_bit(i, &chan->info_mask_separate, sizeof(long)*8) {
 		ret = __iio_add_chan_devattr(iio_chan_info_postfix[i],
 					     chan,
include/linux/iio/iio.h +1 -72

85 lines not on this page · raw message

Signature · 1 line
1.8.1.1
#73 lore raw
In reply to Jonathan Cameron
Quoted 30 lines · Jonathan Cameron

Hi All,

This has been on my todo list for a while. I'm not sure how we ever ended up with the mess that is the current info_mask bitmap of which properties exist for a given channel. Anyhow currently you have two types of bit in there, IIO_CHAN_INFO_SHARED_BIT (even) and IIO_CHAN_INFO_SEPARATE_BIT (odd). Whether we have odd or even elements is used to indicate whether we want an associated attribute specific to the channel, or one that is shared. E.g.

in_accel_x_scale (for just the x accel channel)
or
in_accel_scale (for all accel channels)

in_illuminance0_calibbias
or
in_illuminance_calibbias

This led to a horrible mess in iio.h where we had macros for each option of every element added to the info_mask. Also, a while back it became apparent that sometimes we have attributes shared across all channels irrespective of their type (sampling_frequency for example). Now the obvious solution to this would be to add a third type of info_mask element, but then things are getting rather silly.

Hence the proposed solution. Have separate info_mask elements for each of the two types of bit we had previously (others may follow).

Advantages:

Quoted 9 lines

1) More consise naming of elements
2) Drop all those hideous macros
3) More space (admitedly there are lots of other ways we could have gotten that).

Can't immediately think of any disadvantages other than the fact that we now have so many drivers this was rather time consuming to actually put together and almost certainly has some errors somewhere.

I think this is a good idea. But unless I'm missing something your series is not going to work. IIO_CHAN_INFO_SCALE and friends are part of an enum and just normal numbers. They are not bitfields, so

+ .info_mask_separate = IIO_CHAN_INFO_RAW, \
+ .info_mask_shared_by_type = IIO_CHAN_INFO_SCALE, \

is not going to work. We still need IIO_CHAN_INFO_RAW_BIT, etc. defines.

- Lars

Quoted 154 lines

Jonathan

Jonathan Cameron (67):
iio: Add broken out info_mask fields for shared_by_type and separate iio:adc:max1363 move to info_mask_(shared_by_type/separate) staging:iio:dummy move to info_mask_(shared_by_type/separate) iio:hid_sensors move to info_mask_(shared_by_type/separate) iio:accel:kxsd9 move to info_mask_(shared_by_type/separate) iio:st_sensors move to info_mask_(shared_by_type/separate) iio:adc:ad_sigma_delta move to info_mask_(shared_by_type/separate) iio:adc:ad7266 move to info_mask_(shared_by_type/separate) iio:adc:ad7298 move to info_mask_(shared_by_type/separate) iio:adc:ad7476 move to info_mask_(shared_by_type/separate) iio:adc:ad7887 move to info_mask_(shared_by_type/separate) iio:adc:at91_adc move to info_mask_(shared_by_type/separate) iio:adc:lp8778_adc move to info_mask_(shared_by_type/separate) iio:adc:ti-adc081 move to info_mask_(shared_by_type/separate) iio:adc:ti_am335x_adc move to info_mask_(shared_by_type/separate) iio:adc:viperboard_adc move to info_mask_(shared_by_type/separate) iio:amplifiers:ad8366 move to info_mask_(shared_by_type/separate) iio:dac:ad5064 move to info_mask_(shared_by_type/separate) iio:dac:ad5360 move to info_mask_(shared_by_type/separate) iio:dac:ad5380 move to info_mask_(shared_by_type/separate) iio:dac:ad5421 move to info_mask_(shared_by_type/separate) iio:dac:ad5446 move to info_mask_(shared_by_type/separate) iio:dac:ad5449 move to info_mask_(shared_by_type/separate) iio:dac:ad5504 move to info_mask_(shared_by_type/separate) iio:dac:ad5624r move to info_mask_(shared_by_type/separate) iio:dac:ad5686 move to info_mask_(shared_by_type/separate) iio:dac:ad5755 move to info_mask_(shared_by_type/separate) iio:dac:ad5764 move to info_mask_(shared_by_type/separate) iio:dac:ad5791 move to info_mask_(shared_by_type/separate) iio:dac:max517 move to info_mask_(shared_by_type/separate) iio:dac:mcp4725 move to info_mask_(shared_by_type/separate) iio:freq:ad9523 move to info_mask_(shared_by_type/separate) iio:gyro:adis16080 move to info_mask_(shared_by_type/separate) iio:gyro:adis16136 move to info_mask_(shared_by_type/separate) iio:gyro:adxrs450 move to info_mask_(shared_by_type/separate) iio:gyro:itg3200_core move to info_mask_(shared_by_type/separate) iio:imu:adis16400 move to info_mask_(shared_by_type/separate) iio:imu:adis16480 move to info_mask_(shared_by_type/separate) iio:imu:mpu6050 move to info_mask_(shared_by_type/separate) iio:light:adjd_s311 move to info_mask_(shared_by_type/separate) iio:light:lm3533 move to info_mask_(shared_by_type/separate) iio:light:tsl2563 move to info_mask_(shared_by_type/separate) iio:light:vcnl4000 move to info_mask_(shared_by_type/separate) staging:iio:accel:adis move to info_mask_(shared_by_type/separate) staging:iio:accel:adis16220 move to
info_mask_(shared_by_type/separate)
staging:iio:accel:lis3l02dq move to
info_mask_(shared_by_type/separate)
staging:iio:accel:sca3000 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad7280a move to info_mask_(shared_by_type/separate) staging:iio:ad7291 move to info_mask_(shared_by_type/separate) staging:iio:ad7606 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad799x move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7746 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16060 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16130 move to info_mask_(shared_by_type/separate) staging:iio:impedance:ad5933 move to
info_mask_(shared_by_type/separate)
staging:iio:light:isl29018 move to info_mask_(shared_by_type/separate) staging:iio:isl29028 move to info_mask_(shared_by_type/separate) staging:iio:light:tsl2x7x move to info_mask_(shared_by_type/separate) staging:iio:mag:ak8975 move to info_mask_(shared_by_type/separate) staging:iio:hmc5843 move to info_mask_(shared_by_type/separate) staging:iio:meter:ade7758 move to info_mask_(shared_by_type/separate) staging:iio:resolver:ad2s1200 move to
info_mask_(shared_by_type/separate)
staging:iio:resolver:ad2s1210 move to
info_mask_(shared_by_type/separate)
staging:iio:ad2s90 move to info_mask_(shared_by_type/separate) iio:core drop info_mask from struct iio_info

 drivers/iio/accel/hid-sensor-accel-3d.c         | 24 ++++----
 drivers/iio/accel/kxsd9.c                       |  6 +-
 drivers/iio/adc/ad7266.c                        | 12 ++--
 drivers/iio/adc/ad7298.c                        | 10 ++--
 drivers/iio/adc/ad7476.c                        | 10 ++--
 drivers/iio/adc/ad7887.c                        |  8 +--
 drivers/iio/adc/at91_adc.c                      |  4 +-
 drivers/iio/adc/lp8788_adc.c                    |  4 +-
 drivers/iio/adc/max1363.c                       |  9 +--
 drivers/iio/adc/ti-adc081c.c                    |  4 +-
 drivers/iio/adc/ti_am335x_adc.c                 |  2 +-
 drivers/iio/adc/viperboard_adc.c                |  2 +-
 drivers/iio/amplifiers/ad8366.c                 |  2 +-
 drivers/iio/dac/ad5064.c                        |  4 +-
 drivers/iio/dac/ad5360.c                        | 10 ++--
 drivers/iio/dac/ad5380.c                        |  8 +--
 drivers/iio/dac/ad5421.c                        | 10 ++--
 drivers/iio/dac/ad5446.c                        |  4 +-
 drivers/iio/dac/ad5449.c                        |  4 +-
 drivers/iio/dac/ad5504.c                        |  4 +-
 drivers/iio/dac/ad5624r_spi.c                   |  4 +-
 drivers/iio/dac/ad5686.c                        |  6 +-
 drivers/iio/dac/ad5755.c                        | 10 ++--
 drivers/iio/dac/ad5764.c                        | 10 ++--
 drivers/iio/dac/ad5791.c                        |  6 +-
 drivers/iio/dac/max517.c                        |  4 +-
 drivers/iio/dac/mcp4725.c                       |  4 +-
 drivers/iio/frequency/ad9523.c                  |  8 +--
 drivers/iio/gyro/adis16080.c                    | 22 +++----
 drivers/iio/gyro/adis16136.c                    | 13 ++--
 drivers/iio/gyro/adxrs450.c                     | 22 +++----
 drivers/iio/gyro/hid-sensor-gyro-3d.c           | 24 ++++----
 drivers/iio/gyro/itg3200_core.c                 | 13 ++--
 drivers/iio/imu/adis16400_core.c                | 44 +++++++-------
 drivers/iio/imu/adis16480.c                     | 32 +++++-----
 drivers/iio/imu/inv_mpu6050/inv_mpu_core.c      | 10 ++--
 drivers/iio/industrialio-core.c                 | 27 ++++++---
 drivers/iio/light/adjd_s311.c                   |  4 +-
 drivers/iio/light/hid-sensor-als.c              |  8 +--
 drivers/iio/light/lm3533-als.c                  |  6 +-
 drivers/iio/light/tsl2563.c                     | 10 ++--
 drivers/iio/light/vcnl4000.c                    |  6 +-
 drivers/iio/magnetometer/hid-sensor-magn-3d.c   | 24 ++++----
 drivers/staging/iio/accel/adis16201_core.c      |  8 +--
 drivers/staging/iio/accel/adis16203_core.c      |  2 +-
 drivers/staging/iio/accel/adis16204_core.c      |  8 +--
 drivers/staging/iio/accel/adis16209_core.c      |  4 +-
 drivers/staging/iio/accel/adis16220_core.c      | 21 +++----
 drivers/staging/iio/accel/adis16240_core.c      |  9 +--
 drivers/staging/iio/accel/lis3l02dq_core.c      | 11 ++--
 drivers/staging/iio/accel/sca3000_core.c        |  5 +-
 drivers/staging/iio/adc/ad7280a.c               | 12 ++--
 drivers/staging/iio/adc/ad7291.c                | 10 ++--
 drivers/staging/iio/adc/ad7606_core.c           |  4 +-
 drivers/staging/iio/adc/ad799x_core.c           | 76 ++++++++++++------------
 drivers/staging/iio/cdc/ad7150.c                |  8 +--
 drivers/staging/iio/cdc/ad7152.c                | 32 +++++-----
 drivers/staging/iio/cdc/ad7746.c                | 48 +++++++--------
 drivers/staging/iio/gyro/adis16060_core.c       | 11 ++--
 drivers/staging/iio/gyro/adis16130_core.c       |  4 +-
 drivers/staging/iio/gyro/adis16260_core.c       |  4 +-
 drivers/staging/iio/iio_simple_dummy.c          | 33 +++++------
 drivers/staging/iio/impedance-analyzer/ad5933.c |  8 +--
 drivers/staging/iio/light/isl29018.c            |  8 +--
 drivers/staging/iio/light/isl29028.c            | 10 ++--
 drivers/staging/iio/light/tsl2x7x_core.c        | 40 ++++++-------
 drivers/staging/iio/magnetometer/ak8975.c       |  4 +-
 drivers/staging/iio/magnetometer/hmc5843.c      |  4 +-
 drivers/staging/iio/meter/ade7758_core.c        | 60 +++++++++----------
 drivers/staging/iio/resolver/ad2s1200.c         |  4 +-
 drivers/staging/iio/resolver/ad2s1210.c         |  4 +-
 drivers/staging/iio/resolver/ad2s90.c           |  2 +-
 include/linux/iio/adc/ad_sigma_delta.h          |  6 +-
 include/linux/iio/common/st_sensors.h           |  4 +-
 include/linux/iio/iio.h                         | 79 +++----------------------
 include/linux/iio/imu/adis.h                    | 34 +++++------
 76 files changed, 478 insertions(+), 557 deletions(-)
author maintainer
#74 lore raw
Quoted 48 lines · Lars-Peter Clausen
Quoted 30 lines · Jonathan Cameron

Hi All,

This has been on my todo list for a while. I'm not sure how we ever ended up with the mess that is the current info_mask bitmap of which properties exist for a given channel. Anyhow currently you have two types of bit in there, IIO_CHAN_INFO_SHARED_BIT (even) and IIO_CHAN_INFO_SEPARATE_BIT (odd). Whether we have odd or even elements is used to indicate whether we want an associated attribute specific to the channel, or one that is shared. E.g.

in_accel_x_scale (for just the x accel channel)
or
in_accel_scale (for all accel channels)

in_illuminance0_calibbias
or
in_illuminance_calibbias

This led to a horrible mess in iio.h where we had macros for each option of every element added to the info_mask. Also, a while back it became apparent that sometimes we have attributes shared across all channels irrespective of their type (sampling_frequency for example). Now the obvious solution to this would be to add a third type of info_mask element, but then things are getting rather silly.

Hence the proposed solution. Have separate info_mask elements for each of the two types of bit we had previously (others may follow).

Advantages:

Quoted 9 lines

1) More consise naming of elements
2) Drop all those hideous macros
3) More space (admitedly there are lots of other ways we could have gotten that).

Can't immediately think of any disadvantages other than the fact that we now have so many drivers this was rather time consuming to actually put together and almost certainly has some errors somewhere.

I think this is a good idea. But unless I'm missing something your series is not going to work. IIO_CHAN_INFO_SCALE and friends are part of an enum and just normal numbers. They are not bitfields, so

(quoted diff) +2 -0
+		.info_mask_separate = IIO_CHAN_INFO_RAW,		\
+		.info_mask_shared_by_type = IIO_CHAN_INFO_SCALE,	\
Quoted 1 line

is not going to work. We still need IIO_CHAN_INFO_RAW_BIT, etc. defines.

You are of course correct.

I clearly shouldn't send series like this out late in the evening (and should test them at least a little rather than thinking to myself, it's obvious this will work!...)

Sorry all.

Will repost a form that will actually work when I get a few mins to fix up this messup.

Jonathan

Quoted 164 lines

- Lars

Quoted 145 lines

Jonathan

Jonathan Cameron (67):
iio: Add broken out info_mask fields for shared_by_type and separate iio:adc:max1363 move to info_mask_(shared_by_type/separate) staging:iio:dummy move to info_mask_(shared_by_type/separate) iio:hid_sensors move to info_mask_(shared_by_type/separate) iio:accel:kxsd9 move to info_mask_(shared_by_type/separate) iio:st_sensors move to info_mask_(shared_by_type/separate) iio:adc:ad_sigma_delta move to info_mask_(shared_by_type/separate) iio:adc:ad7266 move to info_mask_(shared_by_type/separate) iio:adc:ad7298 move to info_mask_(shared_by_type/separate) iio:adc:ad7476 move to info_mask_(shared_by_type/separate) iio:adc:ad7887 move to info_mask_(shared_by_type/separate) iio:adc:at91_adc move to info_mask_(shared_by_type/separate) iio:adc:lp8778_adc move to info_mask_(shared_by_type/separate) iio:adc:ti-adc081 move to info_mask_(shared_by_type/separate) iio:adc:ti_am335x_adc move to info_mask_(shared_by_type/separate) iio:adc:viperboard_adc move to info_mask_(shared_by_type/separate) iio:amplifiers:ad8366 move to info_mask_(shared_by_type/separate) iio:dac:ad5064 move to info_mask_(shared_by_type/separate) iio:dac:ad5360 move to info_mask_(shared_by_type/separate) iio:dac:ad5380 move to info_mask_(shared_by_type/separate) iio:dac:ad5421 move to info_mask_(shared_by_type/separate) iio:dac:ad5446 move to info_mask_(shared_by_type/separate) iio:dac:ad5449 move to info_mask_(shared_by_type/separate) iio:dac:ad5504 move to info_mask_(shared_by_type/separate) iio:dac:ad5624r move to info_mask_(shared_by_type/separate) iio:dac:ad5686 move to info_mask_(shared_by_type/separate) iio:dac:ad5755 move to info_mask_(shared_by_type/separate) iio:dac:ad5764 move to info_mask_(shared_by_type/separate) iio:dac:ad5791 move to info_mask_(shared_by_type/separate) iio:dac:max517 move to info_mask_(shared_by_type/separate) iio:dac:mcp4725 move to info_mask_(shared_by_type/separate) iio:freq:ad9523 move to info_mask_(shared_by_type/separate) iio:gyro:adis16080 move to info_mask_(shared_by_type/separate) iio:gyro:adis16136 move to info_mask_(shared_by_type/separate) iio:gyro:adxrs450 move to info_mask_(shared_by_type/separate) iio:gyro:itg3200_core move to info_mask_(shared_by_type/separate) iio:imu:adis16400 move to info_mask_(shared_by_type/separate) iio:imu:adis16480 move to info_mask_(shared_by_type/separate) iio:imu:mpu6050 move to info_mask_(shared_by_type/separate) iio:light:adjd_s311 move to info_mask_(shared_by_type/separate) iio:light:lm3533 move to info_mask_(shared_by_type/separate) iio:light:tsl2563 move to info_mask_(shared_by_type/separate) iio:light:vcnl4000 move to info_mask_(shared_by_type/separate) staging:iio:accel:adis move to info_mask_(shared_by_type/separate) staging:iio:accel:adis16220 move to
info_mask_(shared_by_type/separate)
staging:iio:accel:lis3l02dq move to
info_mask_(shared_by_type/separate)
staging:iio:accel:sca3000 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad7280a move to info_mask_(shared_by_type/separate) staging:iio:ad7291 move to info_mask_(shared_by_type/separate) staging:iio:ad7606 move to info_mask_(shared_by_type/separate) staging:iio:adc:ad799x move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7152 move to info_mask_(shared_by_type/separate) staging:iio:cdc:ad7746 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16060 move to info_mask_(shared_by_type/separate) staging:iio:gyro:adis16130 move to info_mask_(shared_by_type/separate) staging:iio:impedance:ad5933 move to
info_mask_(shared_by_type/separate)
staging:iio:light:isl29018 move to info_mask_(shared_by_type/separate) staging:iio:isl29028 move to info_mask_(shared_by_type/separate) staging:iio:light:tsl2x7x move to info_mask_(shared_by_type/separate) staging:iio:mag:ak8975 move to info_mask_(shared_by_type/separate) staging:iio:hmc5843 move to info_mask_(shared_by_type/separate) staging:iio:meter:ade7758 move to info_mask_(shared_by_type/separate) staging:iio:resolver:ad2s1200 move to
info_mask_(shared_by_type/separate)
staging:iio:resolver:ad2s1210 move to
info_mask_(shared_by_type/separate)
staging:iio:ad2s90 move to info_mask_(shared_by_type/separate) iio:core drop info_mask from struct iio_info

 drivers/iio/accel/hid-sensor-accel-3d.c         | 24 ++++----
 drivers/iio/accel/kxsd9.c                       |  6 +-
 drivers/iio/adc/ad7266.c                        | 12 ++--
 drivers/iio/adc/ad7298.c                        | 10 ++--
 drivers/iio/adc/ad7476.c                        | 10 ++--
 drivers/iio/adc/ad7887.c                        |  8 +--
 drivers/iio/adc/at91_adc.c                      |  4 +-
 drivers/iio/adc/lp8788_adc.c                    |  4 +-
 drivers/iio/adc/max1363.c                       |  9 +--
 drivers/iio/adc/ti-adc081c.c                    |  4 +-
 drivers/iio/adc/ti_am335x_adc.c                 |  2 +-
 drivers/iio/adc/viperboard_adc.c                |  2 +-
 drivers/iio/amplifiers/ad8366.c                 |  2 +-
 drivers/iio/dac/ad5064.c                        |  4 +-
 drivers/iio/dac/ad5360.c                        | 10 ++--
 drivers/iio/dac/ad5380.c                        |  8 +--
 drivers/iio/dac/ad5421.c                        | 10 ++--
 drivers/iio/dac/ad5446.c                        |  4 +-
 drivers/iio/dac/ad5449.c                        |  4 +-
 drivers/iio/dac/ad5504.c                        |  4 +-
 drivers/iio/dac/ad5624r_spi.c                   |  4 +-
 drivers/iio/dac/ad5686.c                        |  6 +-
 drivers/iio/dac/ad5755.c                        | 10 ++--
 drivers/iio/dac/ad5764.c                        | 10 ++--
 drivers/iio/dac/ad5791.c                        |  6 +-
 drivers/iio/dac/max517.c                        |  4 +-
 drivers/iio/dac/mcp4725.c                       |  4 +-
 drivers/iio/frequency/ad9523.c                  |  8 +--
 drivers/iio/gyro/adis16080.c                    | 22 +++----
 drivers/iio/gyro/adis16136.c                    | 13 ++--
 drivers/iio/gyro/adxrs450.c                     | 22 +++----
 drivers/iio/gyro/hid-sensor-gyro-3d.c           | 24 ++++----
 drivers/iio/gyro/itg3200_core.c                 | 13 ++--
 drivers/iio/imu/adis16400_core.c                | 44 +++++++-------
 drivers/iio/imu/adis16480.c                     | 32 +++++-----
 drivers/iio/imu/inv_mpu6050/inv_mpu_core.c      | 10 ++--
 drivers/iio/industrialio-core.c                 | 27 ++++++---
 drivers/iio/light/adjd_s311.c                   |  4 +-
 drivers/iio/light/hid-sensor-als.c              |  8 +--
 drivers/iio/light/lm3533-als.c                  |  6 +-
 drivers/iio/light/tsl2563.c                     | 10 ++--
 drivers/iio/light/vcnl4000.c                    |  6 +-
 drivers/iio/magnetometer/hid-sensor-magn-3d.c   | 24 ++++----
 drivers/staging/iio/accel/adis16201_core.c      |  8 +--
 drivers/staging/iio/accel/adis16203_core.c      |  2 +-
 drivers/staging/iio/accel/adis16204_core.c      |  8 +--
 drivers/staging/iio/accel/adis16209_core.c      |  4 +-
 drivers/staging/iio/accel/adis16220_core.c      | 21 +++----
 drivers/staging/iio/accel/adis16240_core.c      |  9 +--
 drivers/staging/iio/accel/lis3l02dq_core.c      | 11 ++--
 drivers/staging/iio/accel/sca3000_core.c        |  5 +-
 drivers/staging/iio/adc/ad7280a.c               | 12 ++--
 drivers/staging/iio/adc/ad7291.c                | 10 ++--
 drivers/staging/iio/adc/ad7606_core.c           |  4 +-
 drivers/staging/iio/adc/ad799x_core.c           | 76 ++++++++++++------------
 drivers/staging/iio/cdc/ad7150.c                |  8 +--
 drivers/staging/iio/cdc/ad7152.c                | 32 +++++-----
 drivers/staging/iio/cdc/ad7746.c                | 48 +++++++--------
 drivers/staging/iio/gyro/adis16060_core.c       | 11 ++--
 drivers/staging/iio/gyro/adis16130_core.c       |  4 +-
 drivers/staging/iio/gyro/adis16260_core.c       |  4 +-
 drivers/staging/iio/iio_simple_dummy.c          | 33 +++++------
 drivers/staging/iio/impedance-analyzer/ad5933.c |  8 +--
 drivers/staging/iio/light/isl29018.c            |  8 +--
 drivers/staging/iio/light/isl29028.c            | 10 ++--
 drivers/staging/iio/light/tsl2x7x_core.c        | 40 ++++++-------
 drivers/staging/iio/magnetometer/ak8975.c       |  4 +-
 drivers/staging/iio/magnetometer/hmc5843.c      |  4 +-
 drivers/staging/iio/meter/ade7758_core.c        | 60 +++++++++----------
Quoted 9 lines
 drivers/staging/iio/resolver/ad2s1200.c         |  4 +-
 drivers/staging/iio/resolver/ad2s1210.c         |  4 +-
 drivers/staging/iio/resolver/ad2s90.c           |  2 +-
 include/linux/iio/adc/ad_sigma_delta.h          |  6 +-
 include/linux/iio/common/st_sensors.h           |  4 +-
 include/linux/iio/iio.h                         | 79 +++----------------------
 include/linux/iio/imu/adis.h                    | 34 +++++------
 76 files changed, 478 insertions(+), 557 deletions(-)

--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html