diff options
author | Matt Ranostay <mranostay@gmail.com> | 2016-01-26 21:34:30 -0500 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2016-01-30 11:27:17 -0500 |
commit | ecb3a7ccc653fc8007edd0591d32d839386673f1 (patch) | |
tree | 36a6cc38498db92fffeccc4889280315d933e555 | |
parent | 5f9c95d8516e9383f545be6f7178eef8aea008c8 (diff) |
iio: ph: add IIO_PH 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 | 7 | ||||
-rw-r--r-- | drivers/iio/industrialio-core.c | 1 | ||||
-rw-r--r-- | include/uapi/linux/iio/types.h | 1 |
3 files changed, 9 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/testing/sysfs-bus-iio index 8fadd272ad8a..80c6fce9935b 100644 --- a/Documentation/ABI/testing/sysfs-bus-iio +++ b/Documentation/ABI/testing/sysfs-bus-iio | |||
@@ -1493,3 +1493,10 @@ Description: | |||
1493 | This ABI is especially applicable for humidity sensors | 1493 | This ABI is especially applicable for humidity sensors |
1494 | to heatup the device and get rid of any condensation | 1494 | to heatup the device and get rid of any condensation |
1495 | in some humidity environment | 1495 | in some humidity environment |
1496 | |||
1497 | What: /sys/bus/iio/devices/iio:deviceX/in_ph_raw | ||
1498 | KernelVersion: 4.5 | ||
1499 | Contact: linux-iio@vger.kernel.org | ||
1500 | Description: | ||
1501 | Raw (unscaled no offset etc.) pH reading of a substance as a negative | ||
1502 | base-10 logarithm of hydrodium ions in a litre of water. | ||
diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c index fd01f3493fc7..eb01a83a5b7c 100644 --- a/drivers/iio/industrialio-core.c +++ b/drivers/iio/industrialio-core.c | |||
@@ -77,6 +77,7 @@ static const char * const iio_chan_type_name_spec[] = { | |||
77 | [IIO_VELOCITY] = "velocity", | 77 | [IIO_VELOCITY] = "velocity", |
78 | [IIO_CONCENTRATION] = "concentration", | 78 | [IIO_CONCENTRATION] = "concentration", |
79 | [IIO_RESISTANCE] = "resistance", | 79 | [IIO_RESISTANCE] = "resistance", |
80 | [IIO_PH] = "ph", | ||
80 | }; | 81 | }; |
81 | 82 | ||
82 | static const char * const iio_modifier_names[] = { | 83 | static const char * const iio_modifier_names[] = { |
diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h index 7c63bd67c36e..c077617f3304 100644 --- a/include/uapi/linux/iio/types.h +++ b/include/uapi/linux/iio/types.h | |||
@@ -37,6 +37,7 @@ enum iio_chan_type { | |||
37 | IIO_VELOCITY, | 37 | IIO_VELOCITY, |
38 | IIO_CONCENTRATION, | 38 | IIO_CONCENTRATION, |
39 | IIO_RESISTANCE, | 39 | IIO_RESISTANCE, |
40 | IIO_PH, | ||
40 | }; | 41 | }; |
41 | 42 | ||
42 | enum iio_modifier { | 43 | enum iio_modifier { |