hwmon: Add support for DS1682
PATCH 1/1 hwmon: Add support for DS1682
Hi,
This adds a driver for the Dallas Semiconductor DS1682 Total Elapsed Time counter.
Signed-off-by Martin Hicks <mort at bork.org>
---
drivers/hwmon/Kconfig | 25 ++++ drivers/hwmon/Makefile | 1 drivers/hwmon/ds1682.c | 321 ++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/i2c-id.h | 1 4 files changed, 348 insertions(+), 0 deletions(-) create mode 100644 drivers/hwmon/ds1682.c
929a2c6bbd7ba9abdc68219552f2944290d8f45f
drivers/hwmon/Kconfig +25 -0
@@ -129,6 +129,31 @@ config SENSORS_DS1621 This driver can also be built as a module. If so, the module will be called ds1621. +config SENSORS_DS1682 + tristate "Dallas Semiconductor DS1682" + depends on HWMON && I2C && EXPERIMENTAL + help + If you say yes here you get support for Dallas Semiconductor + DS1682 total elapsed time recorder. + + This driver can also be built as a module. If so, the module + will be called ds1682. + +config SENSORS_DS1682_RESET + bool "Enable DS1682 Config and Reset capabilities" + depends on SENSORS_DS1682 + help + This enables the configuration phase of the ds1682. Once you + setup the config register to your liking you can issue a reset + command by doing, for example: + + echo 55 > /sys/bus/i2c/devices/0-006b/reset + + twice. This permanently locks the device into its current + configuration. + + YOU CAN ONLY DO THIS ONCE. Subsequent resets are ignored. + config SENSORS_F71805F tristate "Fintek F71805F/FG" depends on HWMON && EXPERIMENTAL
drivers/hwmon/Makefile +1 -0
@@ -20,6 +20,7 @@ obj-$(CONFIG_SENSORS_ADM1031) += adm1031 obj-$(CONFIG_SENSORS_ADM9240) += adm9240.o obj-$(CONFIG_SENSORS_ATXP1) += atxp1.o obj-$(CONFIG_SENSORS_DS1621) += ds1621.o +obj-$(CONFIG_SENSORS_DS1682) += ds1682.o obj-$(CONFIG_SENSORS_F71805F) += f71805f.o obj-$(CONFIG_SENSORS_FSCHER) += fscher.o obj-$(CONFIG_SENSORS_FSCPOS) += fscpos.o
drivers/hwmon/ds1682.c new file +320 -0
320 lines not on this page · raw message
include/linux/i2c-id.h +1 -0
@@ -158,6 +158,7 @@ #define I2C_DRIVERID_LM90 1042#define I2C_DRIVERID_ASB100 1043#define I2C_DRIVERID_FSCHER 1046#define I2C_DRIVERID_W83L785TS 1047 +#define I2C_DRIVERID_DS1682 1049/* * ---- Adapter types ----------------------------------------------------
Signature · 5 lines
1.3.2 -- Martin Hicks || mort at bork.org || PGP/GnuPG: 0x4C7F2BEE