Skip to content

Commit

Permalink
Merge branch 'release' of git://lm-sensors.org/kernel/mhoffman/hwmon-2.6
Browse files Browse the repository at this point in the history
* 'release' of git://lm-sensors.org/kernel/mhoffman/hwmon-2.6:
  hwmon: normal_i2c arrays should be const
  hwmon: New driver for Analog Devices ADT7473 sensor chip
  hwmon: (coretemp) Add Penryn CPU to coretemp
  hwmon: (coretemp) Add TjMax detection for mobile CPUs
  hwmon: (applesmc) sensors set for MacBook2
  hwmon: (thmc50) Storage class should be before const qualifier
  hwmon: (coretemp) fix section mismatch warning
  hwmon: (coretemp) Add maximum cooling temperature readout
  hwmon: (adm1026) Properly terminate sysfs groups
  hwmon: (vt8231) Update maintainer email address
  hwmon: (vt8231) Add individual alarm files
  hwmon: (via686a) Add individual alarm files
  hwmon: (smsc47m1) Add individual alarm files
  hwmon: (max1619) Add individual alarm and fault files
  hwmon: (lm92) Add individual alarm files
  • Loading branch information
Linus Torvalds committed Feb 22, 2008
2 parents 20f8d2a + 25e9c86 commit bfe38cc
Show file tree
Hide file tree
Showing 51 changed files with 1,534 additions and 120 deletions.
79 changes: 79 additions & 0 deletions Documentation/hwmon/adt7473
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
Kernel driver adt7473
======================

Supported chips:
* Analog Devices ADT7473
Prefix: 'adt7473'
Addresses scanned: I2C 0x2C, 0x2D, 0x2E
Datasheet: Publicly available at the Analog Devices website

Author: Darrick J. Wong

Description
-----------

This driver implements support for the Analog Devices ADT7473 chip family.

The LM85 uses the 2-wire interface compatible with the SMBUS 2.0
specification. Using an analog to digital converter it measures three (3)
temperatures and two (2) voltages. It has three (3) 16-bit counters for
measuring fan speed. There are three (3) PWM outputs that can be used
to control fan speed.

A sophisticated control system for the PWM outputs is designed into the
LM85 that allows fan speed to be adjusted automatically based on any of the
three temperature sensors. Each PWM output is individually adjustable and
programmable. Once configured, the ADT7473 will adjust the PWM outputs in
response to the measured temperatures without further host intervention.
This feature can also be disabled for manual control of the PWM's.

Each of the measured inputs (voltage, temperature, fan speed) has
corresponding high/low limit values. The ADT7473 will signal an ALARM if
any measured value exceeds either limit.

The ADT7473 samples all inputs continuously. The driver will not read
the registers more often than once every other second. Further,
configuration data is only read once per minute.

Special Features
----------------

The ADT7473 have a 10-bit ADC and can therefore measure temperatures
with 0.25 degC resolution. Temperature readings can be configured either
for twos complement format or "Offset 64" format, wherein 63 is subtracted
from the raw value to get the temperature value.

The Analog Devices datasheet is very detailed and describes a procedure for
determining an optimal configuration for the automatic PWM control.

Hardware Configurations
-----------------------

The ADT7473 chips have an optional SMBALERT output that can be used to
signal the chipset in case a limit is exceeded or the temperature sensors
fail. Individual sensor interrupts can be masked so they won't trigger
SMBALERT. The SMBALERT output if configured replaces the PWM2 function.

Configuration Notes
-------------------

Besides standard interfaces driver adds the following:

* PWM Control

* pwm#_auto_point1_pwm and pwm#_auto_point1_temp and
* pwm#_auto_point2_pwm and pwm#_auto_point2_temp -

point1: Set the pwm speed at a lower temperature bound.
point2: Set the pwm speed at a higher temperature bound.

The ADT7473 will scale the pwm between the lower and higher pwm speed when
the temperature is between the two temperature boundaries. PWM values range
from 0 (off) to 255 (full speed).

Notes
-----

The NVIDIA binary driver presents an ADT7473 chip via an on-card i2c bus.
Unfortunately, they fail to set the i2c adapter class, so this driver may
fail to find the chip until the nvidia driver is patched.
6 changes: 4 additions & 2 deletions Documentation/hwmon/coretemp
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ Kernel driver coretemp
Supported chips:
* All Intel Core family
Prefix: 'coretemp'
CPUID: family 0x6, models 0xe, 0xf, 0x16
CPUID: family 0x6, models 0xe, 0xf, 0x16, 0x17
Datasheet: Intel 64 and IA-32 Architectures Software Developer's Manual
Volume 3A: System Programming Guide
http://softwarecommunity.intel.com/Wiki/Mobility/720.htm

Author: Rudolf Marek

Expand All @@ -25,7 +26,8 @@ may be raised, if the temperature grows enough (more than TjMax) to trigger
the Out-Of-Spec bit. Following table summarizes the exported sysfs files:

temp1_input - Core temperature (in millidegrees Celsius).
temp1_crit - Maximum junction temperature (in millidegrees Celsius).
temp1_max - All cooling devices should be turned on (on Core2).
temp1_crit - Maximum junction temperature (in millidegrees Celsius).
temp1_crit_alarm - Set when Out-of-spec bit is set, never clears.
Correct CPU operation is no longer guaranteed.
temp1_label - Contains string "Core X", where X is processor
Expand Down
2 changes: 1 addition & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -4261,7 +4261,7 @@ S: Maintained

VT8231 HARDWARE MONITOR DRIVER
P: Roger Lucas
M: roger@planbit.co.uk
M: vt8231@hiddenengine.co.uk
L: lm-sensors@lm-sensors.org
S: Maintained

Expand Down
10 changes: 10 additions & 0 deletions drivers/hwmon/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,16 @@ config SENSORS_ADT7470
This driver can also be built as a module. If so, the module
will be called adt7470.

config SENSORS_ADT7473
tristate "Analog Devices ADT7473"
depends on I2C && EXPERIMENTAL
help
If you say yes here you get support for the Analog Devices
ADT7473 temperature monitoring chips.

This driver can also be built as a module. If so, the module
will be called adt7473.

config SENSORS_K8TEMP
tristate "AMD Athlon64/FX or Opteron temperature sensor"
depends on X86 && PCI && EXPERIMENTAL
Expand Down
1 change: 1 addition & 0 deletions drivers/hwmon/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ obj-$(CONFIG_SENSORS_ADM1031) += adm1031.o
obj-$(CONFIG_SENSORS_ADM9240) += adm9240.o
obj-$(CONFIG_SENSORS_ADS7828) += ads7828.o
obj-$(CONFIG_SENSORS_ADT7470) += adt7470.o
obj-$(CONFIG_SENSORS_ADT7473) += adt7473.o
obj-$(CONFIG_SENSORS_APPLESMC) += applesmc.o
obj-$(CONFIG_SENSORS_AMS) += ams/
obj-$(CONFIG_SENSORS_ATXP1) += atxp1.o
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/ad7418.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#define DRV_VERSION "0.3"

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x28, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x28, I2C_CLIENT_END };
/* Insmod parameters */
I2C_CLIENT_INSMOD_3(ad7416, ad7417, ad7418);

Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/adm1021.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@


/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
0x29, 0x2a, 0x2b,
0x4c, 0x4d, 0x4e,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = {
0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_8(adm1021, adm1023, max1617, max1617a, thmc10, lm84, gl523sm,
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm1025.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
* NE1619 has two possible addresses: 0x2c and 0x2d.
*/

static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
4 changes: 3 additions & 1 deletion drivers/hwmon/adm1026.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(adm1026);
Expand Down Expand Up @@ -1624,6 +1624,7 @@ static struct attribute *adm1026_attributes_temp3[] = {
&dev_attr_temp3_crit_enable.attr,
&dev_attr_temp3_auto_point1_pwm.attr,
&dev_attr_temp3_auto_point2_pwm.attr,
NULL
};

static const struct attribute_group adm1026_group_temp3 = {
Expand All @@ -1639,6 +1640,7 @@ static struct attribute *adm1026_attributes_in8_9[] = {
&sensor_dev_attr_in9_max.dev_attr.attr,
&sensor_dev_attr_in9_min.dev_attr.attr,
&sensor_dev_attr_in9_alarm.dev_attr.attr,
NULL
};

static const struct attribute_group adm1026_group_in8_9 = {
Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/adm1029.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,8 @@
* Addresses to scan
*/

static unsigned short normal_i2c[] = {
0x28, 0x29, 0x2a,
0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END
static const unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END
};

/*
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm1031.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
#define ADM1031_CONF2_TEMP_ENABLE(chan) (0x10 << (chan))

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_2(adm1030, adm1031);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm9240.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/ads7828.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
#define ADS7828_INT_VREF_MV 2500 /* Internal vref is 2.5V, 2500mV */

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adt7470.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <linux/log2.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2C, 0x2E, 0x2F, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2C, 0x2E, 0x2F, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(adt7470);
Expand Down
Loading

0 comments on commit bfe38cc

Please sign in to comment.