patch i2c-hwmon-class-02.patch added to gregkh-2.6 tree
[email protected]
AppliedThis is a note to let you know that I've just added the patch titled
Subject: I2C hwmon: hwmon sysfs class
to my gregkh-2.6 tree. Its filename is
i2c-hwmon-class-02.patch
This tree can be found at
http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/patches/
Patches currently in gregkh-2.6 which might be from [email protected] are
i2c/i2c-hwmon-class-01.patchi2c/i2c-hwmon-class-02.patchi2c/i2c-hwmon-class-03.patch
From [email protected] Fri Jul 15 18:42:15 2005
Date: Fri, 15 Jul 2005 21:38:08 -0400
From: "Mark M. Hoffman" <[email protected]>
To: Greg KH <[email protected]>
Cc: Jean Delvare <[email protected]>,
Yani Ioannou <[email protected]>, lm-sensors <[email protected]>
Subject: I2C hwmon: hwmon sysfs class
Message-ID: <[email protected]>
This patch adds the sysfs class "hwmon" for use by hardware monitoring (sensors) chip drivers. It also fixes up the related Kconfig/Makefile bits.
--- drivers/hwmon/Kconfig | 7 +++ drivers/hwmon/Makefile | 2 + drivers/hwmon/hwmon.c | 98 +++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/hwmon.h | 24 ++++++++++++ 4 files changed, 130 insertions(+), 1 deletion(-)
drivers/hwmon/Kconfig +6 -1
@@ -12,7 +12,12 @@ of a system. Most modern motherboards include such a device. It can include temperature sensors, voltage sensors, fan speed sensors and various additional features such as the ability to - control the speed of the fans. + control the speed of the fans. If you want this support you + should say Y here and also to the specific driver(s) for your + sensors chip(s) below. + + This support can also be built as a module. If so, the module + will be called hwmon. config SENSORS_ADM1021 tristate "Analog Devices ADM1021 and compatibles"
drivers/hwmon/Makefile +2 -0
@@ -2,6 +2,8 @@ # Makefile for sensor chip drivers. # +obj-$(CONFIG_HWMON) += hwmon.o + # asb100, then w83781d go first, as they can override other drivers' addresses. obj-$(CONFIG_SENSORS_ASB100) += asb100.o obj-$(CONFIG_SENSORS_W83627HF) += w83627hf.o
drivers/hwmon/hwmon.c new file +98 -0
98 lines not on this page · raw message
include/linux/hwmon.h new file +24 -0
@@ -0,0 +1,24 @@ +/* +hwmon.h - part of lm_sensors, Linux kernel modules for hardware monitoring + +This file declares helper functions for the sysfs class "hwmon", +for use by sensors drivers. + +Copyright (C) 2005 Mark M. Hoffman <[email protected]> + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; version 2 of the License. +*/ + +#ifndef _HWMON_H_ +#define _HWMON_H_ + +#include <linux/device.h> + +struct class_device *hwmon_device_register (struct device *dev); + +void hwmon_device_unregister (struct class_device *cdev); + +#endif +