Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f71eaf68 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging: (41 commits)
  hwmon: (adt7475) Add VID support for the ADT7476
  hwmon: (adt7475) Add an entry in MAINTAINERS
  hwmon: (adt7475) Add support for the ADT7476
  hwmon: (adt7475) Voltage attenuators can be bypassed
  hwmon: (adt7475) Print device information on probe
  hwmon: (adt7475) Handle alternative pin functions
  hwmon: (adt7475) Move sysfs files removal to a separate function
  hwmon: (adt7475) Add support for the ADT7490
  hwmon: (adt7475) Improve device detection
  hwmon: (adt7475) Add missing static marker
  hwmon: (adt7475) Rework voltage inputs handling
  hwmon: (adt7475) Implement pwm_use_point2_pwm_at_crit
  hwmon: (adt7475) New documentation
  hwmon: (adt7475) Add support for the ADT7473
  hwmon: (f71882fg) Add support for the f71889fg (version 2)
  hwmon: (f71882fg) Fix sysfs file removal
  hwmon: (f71882fg) Cleanup sysfs attr creation 2/2
  hwmon: (f71882fg) Cleanup sysfs attr creation 1/2
  hwmon: (thmc50) Stop using I2C_CLIENT_MODULE_PARM
  hwmon: Add Freescale MC13783 ADC driver
  ...
parents 78f1ae19 54fe4671
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -483,3 +483,10 @@ Why: With the recent innovations in CPU hardware acceleration technologies
Who:	Alok N Kataria <akataria@vmware.com>
Who:	Alok N Kataria <akataria@vmware.com>


----------------------------
----------------------------

What:	adt7473 hardware monitoring driver
When:	February 2010
Why:	Obsoleted by the adt7475 driver.
Who:	Jean Delvare <khali@linux-fr.org>

---------------------------
+2 −0
Original line number Original line Diff line number Diff line
@@ -9,6 +9,8 @@ Supported chips:


Author: Darrick J. Wong
Author: Darrick J. Wong


This driver is depreacted, please use the adt7475 driver instead.

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


+117 −87
Original line number Original line Diff line number Diff line
This describes the interface for the ADT7475 driver:
Kernel driver adt7475

=====================
(there are 4 fans, numbered fan1 to fan4):


Supported chips:
fanX_input		Read the current speed of the fan (in RPMs)
  * Analog Devices ADT7473
fanX_min		Read/write the minimum speed of the fan.  Dropping
    Prefix: 'adt7473'
			below this sets an alarm.
    Addresses scanned: I2C 0x2C, 0x2D, 0x2E

    Datasheet: Publicly available at the On Semiconductors website
(there are three PWMs, numbered pwm1 to pwm3):
  * Analog Devices ADT7475

    Prefix: 'adt7475'
pwmX			Read/write the current duty cycle of the PWM.  Writes
    Addresses scanned: I2C 0x2E
			only have effect when auto mode is turned off (see
    Datasheet: Publicly available at the On Semiconductors website
			below).  Range is 0 - 255.
  * Analog Devices ADT7476

    Prefix: 'adt7476'
pwmX_enable		Fan speed control method:
    Addresses scanned: I2C 0x2C, 0x2D, 0x2E

    Datasheet: Publicly available at the On Semiconductors website
			0 - No control (fan at full speed)
  * Analog Devices ADT7490
			1 - Manual fan speed control (using pwm[1-*])
    Prefix: 'adt7490'
			2 - Automatic fan speed control
    Addresses scanned: I2C 0x2C, 0x2D, 0x2E

    Datasheet: Publicly available at the On Semiconductors website
pwmX_auto_channels_temp	Select which channels affect this PWM


Authors:
			1 - TEMP1 controls PWM
	Jordan Crouse
			2 - TEMP2 controls PWM
	Hans de Goede
			4 - TEMP3 controls PWM
	Darrick J. Wong (documentation)
			6 - TEMP2 and TEMP3 control PWM
	Jean Delvare
			7 - All three inputs control PWM



pwmX_freq		Read/write the PWM frequency in Hz. The number
Description
			should be one of the following:
-----------


			11 Hz
This driver implements support for the Analog Devices ADT7473, ADT7475,
			14 Hz
ADT7476 and ADT7490 chip family. The ADT7473 and ADT7475 differ only in
			22 Hz
minor details. The ADT7476 has additional features, including extra voltage
			29 Hz
measurement inputs and VID support. The ADT7490 also has additional
			35 Hz
features, including extra voltage measurement inputs and PECI support. All
			44 Hz
the supported chips will be collectively designed by the name "ADT747x" in
			58 Hz
the rest of this document.
			88 Hz


The ADT747x uses the 2-wire interface compatible with the SMBus 2.0
pwmX_auto_point1_pwm	Read/write the minimum PWM duty cycle in automatic mode
specification. Using an analog to digital converter it measures three (3)

temperatures and two (2) or more voltages. It has four (4) 16-bit counters
pwmX_auto_point2_pwm	Read/write the maximum PWM duty cycle in automatic mode
for measuring fan speed. There are three (3) PWM outputs that can be used

to control fan speed.
(there are three temperature settings numbered temp1 to temp3):


A sophisticated control system for the PWM outputs is designed into the
tempX_input		Read the current temperature.  The value is in milli
ADT747x that allows fan speed to be adjusted automatically based on any of the
			degrees of Celsius.
three temperature sensors. Each PWM output is individually adjustable and

programmable. Once configured, the ADT747x will adjust the PWM outputs in
tempX_max		Read/write the upper temperature limit - exceeding this
response to the measured temperatures without further host intervention.
			will cause an alarm.
This feature can also be disabled for manual control of the PWM's.


tempX_min		Read/write the lower temperature limit - exceeding this
Each of the measured inputs (voltage, temperature, fan speed) has
			will cause an alarm.
corresponding high/low limit values. The ADT747x will signal an ALARM if

any measured value exceeds either limit.
tempX_offset		Read/write the temperature adjustment offset


The ADT747x samples all inputs continuously. The driver will not read
tempX_crit		Read/write the THERM limit for remote1.
the registers more often than once every other second. Further,

configuration data is only read once per minute.
tempX_crit_hyst		Set the temperature value below crit where the

			fans will stay on - this helps drive the temperature
Chip Differences Summary
			low enough so it doesn't stay near the edge and
------------------------
			cause THERM to keep tripping.


ADT7473:
tempX_auto_point1_temp	Read/write the minimum temperature where the fans will
  * 2 voltage inputs
			turn on in automatic mode.
  * system acoustics optimizations (not implemented)


tempX_auto_point2_temp	Read/write the maximum temperature over which the fans
ADT7475:
			will run in automatic mode.  tempX_auto_point1_temp
  * 2 voltage inputs
			and tempX_auto_point2_temp together define the

			range of automatic control.
ADT7476:

  * 5 voltage inputs
tempX_alarm		Read a 1 if the max/min alarm is set
  * VID support
tempX_fault		Read a 1 if either temp1 or temp3 diode has a fault


ADT7490:
(There are two voltage settings, in1 and in2):
  * 6 voltage inputs

  * 1 Imon input (not implemented)
inX_input		Read the current voltage on VCC.  Value is in
  * PECI support (not implemented)
			millivolts.
  * 2 GPIO pins (not implemented)

  * system acoustics optimizations (not implemented)
inX_min			read/write the minimum voltage limit.

			Dropping below this causes an alarm.
Special Features

----------------
inX_max			read/write the maximum voltage limit.

			Exceeding this causes an alarm.
The ADT747x has a 10-bit ADC and can therefore measure temperatures

with a resolution of 0.25 degree Celsius. Temperature readings can be
inX_alarm		Read a 1 if the max/min alarm is set.
configured either for two's complement format or "Offset 64" format,
wherein 64 is subtracted from the raw value to get the temperature value.

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

Fan Speed Control
-----------------

The driver exposes two trip points per PWM channel.

point1: Set the PWM speed at the lower temperature bound
point2: Set the PWM speed at the higher temperature bound

The ADT747x will scale the PWM linearly between the lower and higher PWM
speed when the temperature is between the two temperature boundaries.
Temperature boundaries are associated to temperature channels rather than
PWM outputs, and a given PWM output can be controlled by several temperature
channels. As a result, the ADT747x may compute more than one PWM value
for a channel at a given time, in which case the maximum value (fastest
fan speed) is applied. PWM values range from 0 (off) to 255 (full speed).

Fan speed may be set to maximum when the temperature sensor associated with
the PWM control exceeds temp#_max.

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.
+10 −0
Original line number Original line Diff line number Diff line
@@ -14,6 +14,10 @@ Supported chips:
    Prefix: 'f71882fg'
    Prefix: 'f71882fg'
    Addresses scanned: none, address read from Super I/O config space
    Addresses scanned: none, address read from Super I/O config space
    Datasheet: Available from the Fintek website
    Datasheet: Available from the Fintek website
  * Fintek F71889FG
    Prefix: 'f71889fg'
    Addresses scanned: none, address read from Super I/O config space
    Datasheet: Should become available on the Fintek website soon
  * Fintek F8000
  * Fintek F8000
    Prefix: 'f8000'
    Prefix: 'f8000'
    Addresses scanned: none, address read from Super I/O config space
    Addresses scanned: none, address read from Super I/O config space
@@ -51,6 +55,12 @@ supported. The right one to use depends on external circuitry on the
motherboard, so the driver assumes that the BIOS set the method
motherboard, so the driver assumes that the BIOS set the method
properly.
properly.


Note that the lowest numbered temperature zone trip point corresponds to
to the border between the highest and one but highest temperature zones, and
vica versa. So the temperature zone trip points 1-4 (or 1-2) go from high temp
to low temp! This is how things are implemented in the IC, and the driver
mimicks this.

There are 2 modes to specify the speed of the fan, PWM duty cycle (or DC
There are 2 modes to specify the speed of the fan, PWM duty cycle (or DC
voltage) mode, where 0-100% duty cycle (0-100% of 12V) is specified. And RPM
voltage) mode, where 0-100% duty cycle (0-100% of 12V) is specified. And RPM
mode where the actual RPM of the fan (as measured) is controlled and the speed
mode where the actual RPM of the fan (as measured) is controlled and the speed
+0 −1
Original line number Original line Diff line number Diff line
@@ -86,7 +86,6 @@ The IT8712F and IT8716F additionally feature VID inputs, used to report
the Vcore voltage of the processor. The early IT8712F have 5 VID pins,
the Vcore voltage of the processor. The early IT8712F have 5 VID pins,
the IT8716F and late IT8712F have 6. They are shared with other functions
the IT8716F and late IT8712F have 6. They are shared with other functions
though, so the functionality may not be available on a given system.
though, so the functionality may not be available on a given system.
The driver dumbly assume it is there.


The IT8718F and IT8720F also features VID inputs (up to 8 pins) but the value
The IT8718F and IT8720F also features VID inputs (up to 8 pins) but the value
is stored in the Super-I/O configuration space. Due to technical limitations,
is stored in the Super-I/O configuration space. Due to technical limitations,
Loading