forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/…
…kernel/git/jdelvare/staging * '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 ...
- Loading branch information
Showing
58 changed files
with
2,319 additions
and
1,742 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -483,3 +483,10 @@ Why: With the recent innovations in CPU hardware acceleration technologies | |
Who: Alok N Kataria <[email protected]> | ||
|
||
---------------------------- | ||
|
||
What: adt7473 hardware monitoring driver | ||
When: February 2010 | ||
Why: Obsoleted by the adt7475 driver. | ||
Who: Jean Delvare <[email protected]> | ||
|
||
--------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,87 +1,117 @@ | ||
This describes the interface for the ADT7475 driver: | ||
|
||
(there are 4 fans, numbered fan1 to fan4): | ||
|
||
fanX_input Read the current speed of the fan (in RPMs) | ||
fanX_min Read/write the minimum speed of the fan. Dropping | ||
below this sets an alarm. | ||
|
||
(there are three PWMs, numbered pwm1 to pwm3): | ||
|
||
pwmX Read/write the current duty cycle of the PWM. Writes | ||
only have effect when auto mode is turned off (see | ||
below). Range is 0 - 255. | ||
|
||
pwmX_enable Fan speed control method: | ||
|
||
0 - No control (fan at full speed) | ||
1 - Manual fan speed control (using pwm[1-*]) | ||
2 - Automatic fan speed control | ||
|
||
pwmX_auto_channels_temp Select which channels affect this PWM | ||
|
||
1 - TEMP1 controls PWM | ||
2 - TEMP2 controls PWM | ||
4 - TEMP3 controls PWM | ||
6 - TEMP2 and TEMP3 control PWM | ||
7 - All three inputs control PWM | ||
|
||
pwmX_freq Read/write the PWM frequency in Hz. The number | ||
should be one of the following: | ||
|
||
11 Hz | ||
14 Hz | ||
22 Hz | ||
29 Hz | ||
35 Hz | ||
44 Hz | ||
58 Hz | ||
88 Hz | ||
|
||
pwmX_auto_point1_pwm Read/write the minimum PWM duty cycle in automatic mode | ||
|
||
pwmX_auto_point2_pwm Read/write the maximum PWM duty cycle in automatic mode | ||
|
||
(there are three temperature settings numbered temp1 to temp3): | ||
|
||
tempX_input Read the current temperature. The value is in milli | ||
degrees of Celsius. | ||
|
||
tempX_max Read/write the upper temperature limit - exceeding this | ||
will cause an alarm. | ||
|
||
tempX_min Read/write the lower temperature limit - exceeding this | ||
will cause an alarm. | ||
|
||
tempX_offset Read/write the temperature adjustment offset | ||
|
||
tempX_crit Read/write the THERM limit for remote1. | ||
|
||
tempX_crit_hyst Set the temperature value below crit where the | ||
fans will stay on - this helps drive the temperature | ||
low enough so it doesn't stay near the edge and | ||
cause THERM to keep tripping. | ||
|
||
tempX_auto_point1_temp Read/write the minimum temperature where the fans will | ||
turn on in automatic mode. | ||
|
||
tempX_auto_point2_temp Read/write the maximum temperature over which the fans | ||
will run in automatic mode. tempX_auto_point1_temp | ||
and tempX_auto_point2_temp together define the | ||
range of automatic control. | ||
|
||
tempX_alarm Read a 1 if the max/min alarm is set | ||
tempX_fault Read a 1 if either temp1 or temp3 diode has a fault | ||
|
||
(There are two voltage settings, in1 and in2): | ||
|
||
inX_input Read the current voltage on VCC. Value is in | ||
millivolts. | ||
|
||
inX_min read/write the minimum voltage limit. | ||
Dropping below this causes an alarm. | ||
|
||
inX_max read/write the maximum voltage limit. | ||
Exceeding this causes an alarm. | ||
|
||
inX_alarm Read a 1 if the max/min alarm is set. | ||
Kernel driver adt7475 | ||
===================== | ||
|
||
Supported chips: | ||
* Analog Devices ADT7473 | ||
Prefix: 'adt7473' | ||
Addresses scanned: I2C 0x2C, 0x2D, 0x2E | ||
Datasheet: Publicly available at the On Semiconductors website | ||
* Analog Devices ADT7475 | ||
Prefix: 'adt7475' | ||
Addresses scanned: I2C 0x2E | ||
Datasheet: Publicly available at the On Semiconductors website | ||
* Analog Devices ADT7476 | ||
Prefix: 'adt7476' | ||
Addresses scanned: I2C 0x2C, 0x2D, 0x2E | ||
Datasheet: Publicly available at the On Semiconductors website | ||
* Analog Devices ADT7490 | ||
Prefix: 'adt7490' | ||
Addresses scanned: I2C 0x2C, 0x2D, 0x2E | ||
Datasheet: Publicly available at the On Semiconductors website | ||
|
||
Authors: | ||
Jordan Crouse | ||
Hans de Goede | ||
Darrick J. Wong (documentation) | ||
Jean Delvare | ||
|
||
|
||
Description | ||
----------- | ||
|
||
This driver implements support for the Analog Devices ADT7473, ADT7475, | ||
ADT7476 and ADT7490 chip family. The ADT7473 and ADT7475 differ only in | ||
minor details. The ADT7476 has additional features, including extra voltage | ||
measurement inputs and VID support. The ADT7490 also has additional | ||
features, including extra voltage measurement inputs and PECI support. All | ||
the supported chips will be collectively designed by the name "ADT747x" in | ||
the rest of this document. | ||
|
||
The ADT747x 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) or more voltages. It has four (4) 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 | ||
ADT747x 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 ADT747x 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 ADT747x will signal an ALARM if | ||
any measured value exceeds either limit. | ||
|
||
The ADT747x 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. | ||
|
||
Chip Differences Summary | ||
------------------------ | ||
|
||
ADT7473: | ||
* 2 voltage inputs | ||
* system acoustics optimizations (not implemented) | ||
|
||
ADT7475: | ||
* 2 voltage inputs | ||
|
||
ADT7476: | ||
* 5 voltage inputs | ||
* VID support | ||
|
||
ADT7490: | ||
* 6 voltage inputs | ||
* 1 Imon input (not implemented) | ||
* PECI support (not implemented) | ||
* 2 GPIO pins (not implemented) | ||
* system acoustics optimizations (not implemented) | ||
|
||
Special Features | ||
---------------- | ||
|
||
The ADT747x has a 10-bit ADC and can therefore measure temperatures | ||
with a resolution of 0.25 degree Celsius. Temperature readings can be | ||
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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
Kernel driver mc13783-adc | ||
========================= | ||
|
||
Supported chips: | ||
* Freescale Atlas MC13783 | ||
Prefix: 'mc13783_adc' | ||
Datasheet: http://www.freescale.com/files/rf_if/doc/data_sheet/MC13783.pdf?fsrch=1 | ||
|
||
Authors: | ||
Sascha Hauer <[email protected]> | ||
Luotao Fu <[email protected]> | ||
|
||
Description | ||
----------- | ||
|
||
The Freescale MC13783 is a Power Management and Audio Circuit. Among | ||
other things it contains a 10-bit A/D converter. The converter has 16 | ||
channels which can be used in different modes. | ||
The A/D converter has a resolution of 2.25mV. Channels 0-4 have | ||
a dedicated meaning with chip internal scaling applied. Channels 5-7 | ||
can be used as general purpose inputs or alternatively in a dedicated | ||
mode. Channels 12-15 are occupied by the touchscreen if it's active. | ||
|
||
Currently the driver only supports channels 2 and 5-15 with no alternative | ||
modes for channels 5-7. | ||
|
||
See this table for the meaning of the different channels and their chip | ||
internal scaling: | ||
|
||
Channel Signal Input Range Scaling | ||
------------------------------------------------------------------------------- | ||
0 Battery Voltage (BATT) 2.50 - 4.65V -2.40V | ||
1 Battery Current (BATT - BATTISNS) -50 - 50 mV x20 | ||
2 Application Supply (BP) 2.50 - 4.65V -2.40V | ||
3 Charger Voltage (CHRGRAW) 0 - 10V / /5 | ||
0 - 20V /10 | ||
4 Charger Current (CHRGISNSP-CHRGISNSN) -0.25V - 0.25V x4 | ||
5 General Purpose ADIN5 / Battery Pack Thermistor 0 - 2.30V No | ||
6 General Purpose ADIN6 / Backup Voltage (LICELL) 0 - 2.30V / No / | ||
1.50 - 3.50V -1.20V | ||
7 General Purpose ADIN7 / UID / Die Temperature 0 - 2.30V / No / | ||
0 - 2.55V / x0.9 / No | ||
8 General Purpose ADIN8 0 - 2.30V No | ||
9 General Purpose ADIN9 0 - 2.30V No | ||
10 General Purpose ADIN10 0 - 2.30V No | ||
11 General Purpose ADIN11 0 - 2.30V No | ||
12 General Purpose TSX1 / Touchscreen X-plate 1 0 - 2.30V No | ||
13 General Purpose TSX2 / Touchscreen X-plate 2 0 - 2.30V No | ||
14 General Purpose TSY1 / Touchscreen Y-plate 1 0 - 2.30V No | ||
15 General Purpose TSY2 / Touchscreen Y-plate 2 0 - 2.30V No |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.