aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Cameron <jic23@kernel.org>2013-03-20 18:21:00 -0400
committerJonathan Cameron <jic23@kernel.org>2013-03-23 06:08:15 -0400
commit51b53dc991ae7eebc5d45b06d576da6486fbf823 (patch)
tree821e9f3f6b31f3fd7c73e26de9ab23c2e94dd896
parent3465a22488a47d5f4791876a22fde2bb1720f4cf (diff)
hwmon: Move the IIO client driver for hwmon out of staging
This driver uses channel maps, defined either through device tree or platform data, to create a hwmon driver which acts as a client for the underlying IIO device channels. Thus a general purpose IIO adc driver can be used to provide hardware monitoring using a subset of its channels. Signed-off-by: Jonathan Cameron <jic23@kernel.org> Acked-by: Guenter Roeck <linux@roeck-us.net> -- The only non move changes here concern the description and changes to the dependencies to IIO explicit and hwmon implicit. I'm proposing moving this into hwmon on the basis of placing drivers based on what they provide rather than what their underlying hardware is. drivers/hwmon/Kconfig | 9 ++ drivers/hwmon/Makefile | 1 + drivers/hwmon/iio_hwmon.c | 196 ++++++++++++++++++++++++++++++++++++++++ drivers/staging/iio/Kconfig | 8 -- drivers/staging/iio/Makefile | 2 - drivers/staging/iio/iio_hwmon.c | 196 ---------------------------------------- 6 files changed, 206 insertions(+), 206 deletions(-)
-rw-r--r--drivers/hwmon/Kconfig9
-rw-r--r--drivers/hwmon/Makefile1
-rw-r--r--drivers/hwmon/iio_hwmon.c (renamed from drivers/staging/iio/iio_hwmon.c)0
-rw-r--r--drivers/staging/iio/Kconfig8
-rw-r--r--drivers/staging/iio/Makefile2
5 files changed, 10 insertions, 10 deletions
diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig
index 89ac1cb26f24..effbd11ff5ec 100644
--- a/drivers/hwmon/Kconfig
+++ b/drivers/hwmon/Kconfig
@@ -499,6 +499,15 @@ config SENSORS_IBMPEX
499 This driver can also be built as a module. If so, the module 499 This driver can also be built as a module. If so, the module
500 will be called ibmpex. 500 will be called ibmpex.
501 501
502config SENSORS_IIO_HWMON
503 tristate "Hwmon driver that uses channels specified via iio maps"
504 depends on IIO
505 help
506 This is a platform driver that in combination with a suitable
507 map allows IIO devices to provide basic hwmon functionality
508 for those channels specified in the map. This map can be provided
509 either via platform data or the device tree bindings.
510
502config SENSORS_IT87 511config SENSORS_IT87
503 tristate "ITE IT87xx and compatibles" 512 tristate "ITE IT87xx and compatibles"
504 depends on !PPC 513 depends on !PPC
diff --git a/drivers/hwmon/Makefile b/drivers/hwmon/Makefile
index 8d6d97ea7c1e..a87fdabddfff 100644
--- a/drivers/hwmon/Makefile
+++ b/drivers/hwmon/Makefile
@@ -65,6 +65,7 @@ obj-$(CONFIG_SENSORS_ULTRA45) += ultra45_env.o
65obj-$(CONFIG_SENSORS_I5K_AMB) += i5k_amb.o 65obj-$(CONFIG_SENSORS_I5K_AMB) += i5k_amb.o
66obj-$(CONFIG_SENSORS_IBMAEM) += ibmaem.o 66obj-$(CONFIG_SENSORS_IBMAEM) += ibmaem.o
67obj-$(CONFIG_SENSORS_IBMPEX) += ibmpex.o 67obj-$(CONFIG_SENSORS_IBMPEX) += ibmpex.o
68obj-$(CONFIG_SENSORS_IIO_HWMON) += iio_hwmon.o
68obj-$(CONFIG_SENSORS_INA209) += ina209.o 69obj-$(CONFIG_SENSORS_INA209) += ina209.o
69obj-$(CONFIG_SENSORS_INA2XX) += ina2xx.o 70obj-$(CONFIG_SENSORS_INA2XX) += ina2xx.o
70obj-$(CONFIG_SENSORS_IT87) += it87.o 71obj-$(CONFIG_SENSORS_IT87) += it87.o
diff --git a/drivers/staging/iio/iio_hwmon.c b/drivers/hwmon/iio_hwmon.c
index aafa4531b961..aafa4531b961 100644
--- a/drivers/staging/iio/iio_hwmon.c
+++ b/drivers/hwmon/iio_hwmon.c
diff --git a/drivers/staging/iio/Kconfig b/drivers/staging/iio/Kconfig
index dc267175a2b5..db4d6dc03243 100644
--- a/drivers/staging/iio/Kconfig
+++ b/drivers/staging/iio/Kconfig
@@ -4,14 +4,6 @@
4menu "IIO staging drivers" 4menu "IIO staging drivers"
5 depends on IIO 5 depends on IIO
6 6
7config IIO_ST_HWMON
8 tristate "Hwmon driver that uses channels specified via iio maps"
9 depends on HWMON
10 help
11 This is a platform driver that in combination with a suitable
12 map allows IIO devices to provide basic hwmon functionality
13 for those channels specified in the map.
14
15source "drivers/staging/iio/accel/Kconfig" 7source "drivers/staging/iio/accel/Kconfig"
16source "drivers/staging/iio/adc/Kconfig" 8source "drivers/staging/iio/adc/Kconfig"
17source "drivers/staging/iio/addac/Kconfig" 9source "drivers/staging/iio/addac/Kconfig"
diff --git a/drivers/staging/iio/Makefile b/drivers/staging/iio/Makefile
index 158e0a017e7b..d87106135b27 100644
--- a/drivers/staging/iio/Makefile
+++ b/drivers/staging/iio/Makefile
@@ -9,8 +9,6 @@ iio_dummy-$(CONFIG_IIO_SIMPLE_DUMMY_BUFFER) += iio_simple_dummy_buffer.o
9 9
10obj-$(CONFIG_IIO_DUMMY_EVGEN) += iio_dummy_evgen.o 10obj-$(CONFIG_IIO_DUMMY_EVGEN) += iio_dummy_evgen.o
11 11
12obj-$(CONFIG_IIO_ST_HWMON) += iio_hwmon.o
13
14obj-y += accel/ 12obj-y += accel/
15obj-y += adc/ 13obj-y += adc/
16obj-y += addac/ 14obj-y += addac/