diff options
author | Matt Ranostay <mranostay@gmail.com> | 2015-09-13 23:26:12 -0400 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2015-09-23 15:23:25 -0400 |
commit | d38d54692d454e4dded125677e39f53514dc4277 (patch) | |
tree | b22f6892d501fe8470936d139c37faa4c8a44d09 | |
parent | 8ff6b3bc9493089247e012a9fcba7198e194b4a5 (diff) |
iio: resistance: add IIO_RESISTANCE channel type
Signed-off-by: Matt Ranostay <mranostay@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
-rw-r--r-- | Documentation/ABI/testing/sysfs-bus-iio | 8 | ||||
-rw-r--r-- | drivers/iio/industrialio-core.c | 1 | ||||
-rw-r--r-- | include/uapi/linux/iio/types.h | 1 |
3 files changed, 10 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/testing/sysfs-bus-iio index 08903b940957..8ce14c85156d 100644 --- a/Documentation/ABI/testing/sysfs-bus-iio +++ b/Documentation/ABI/testing/sysfs-bus-iio | |||
@@ -1471,3 +1471,11 @@ KernelVersion: 4.3 | |||
1471 | Contact: linux-iio@vger.kernel.org | 1471 | Contact: linux-iio@vger.kernel.org |
1472 | Description: | 1472 | Description: |
1473 | Raw (unscaled no offset etc.) percentage reading of a substance. | 1473 | Raw (unscaled no offset etc.) percentage reading of a substance. |
1474 | |||
1475 | What: /sys/bus/iio/devices/iio:deviceX/in_resistance_raw | ||
1476 | What: /sys/bus/iio/devices/iio:deviceX/in_resistanceX_raw | ||
1477 | KernelVersion: 4.3 | ||
1478 | Contact: linux-iio@vger.kernel.org | ||
1479 | Description: | ||
1480 | Raw (unscaled no offset etc.) resistance reading that can be processed | ||
1481 | into an ohm value. | ||
diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c index ee09a945a2c7..208358f9e7e3 100644 --- a/drivers/iio/industrialio-core.c +++ b/drivers/iio/industrialio-core.c | |||
@@ -76,6 +76,7 @@ static const char * const iio_chan_type_name_spec[] = { | |||
76 | [IIO_DISTANCE] = "distance", | 76 | [IIO_DISTANCE] = "distance", |
77 | [IIO_VELOCITY] = "velocity", | 77 | [IIO_VELOCITY] = "velocity", |
78 | [IIO_CONCENTRATION] = "concentration", | 78 | [IIO_CONCENTRATION] = "concentration", |
79 | [IIO_RESISTANCE] = "resistance", | ||
79 | }; | 80 | }; |
80 | 81 | ||
81 | static const char * const iio_modifier_names[] = { | 82 | static const char * const iio_modifier_names[] = { |
diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h index 1e4c4e346ffb..7c63bd67c36e 100644 --- a/include/uapi/linux/iio/types.h +++ b/include/uapi/linux/iio/types.h | |||
@@ -36,6 +36,7 @@ enum iio_chan_type { | |||
36 | IIO_DISTANCE, | 36 | IIO_DISTANCE, |
37 | IIO_VELOCITY, | 37 | IIO_VELOCITY, |
38 | IIO_CONCENTRATION, | 38 | IIO_CONCENTRATION, |
39 | IIO_RESISTANCE, | ||
39 | }; | 40 | }; |
40 | 41 | ||
41 | enum iio_modifier { | 42 | enum iio_modifier { |