Back to home page

OSCL-LXR

 
 

    


0001 =====================
0002 Kernel driver asc7621
0003 =====================
0004 
0005 Supported chips:
0006 
0007     Andigilog aSC7621 and aSC7621a
0008 
0009     Prefix: 'asc7621'
0010 
0011     Addresses scanned: I2C 0x2c, 0x2d, 0x2e
0012 
0013     Datasheet: http://www.fairview5.com/linux/asc7621/asc7621.pdf
0014 
0015 Author:
0016                 George Joseph
0017 
0018 Description provided by Dave Pivin @ Andigilog:
0019 
0020 Andigilog has both the PECI and pre-PECI versions of the Heceta-6, as
0021 Intel calls them. Heceta-6e has high frequency PWM and Heceta-6p has
0022 added PECI and a 4th thermal zone. The Andigilog aSC7611 is the
0023 Heceta-6e part and aSC7621 is the Heceta-6p part. They are both in
0024 volume production, shipping to Intel and their subs.
0025 
0026 We have enhanced both parts relative to the governing Intel
0027 specification. First enhancement is temperature reading resolution. We
0028 have used registers below 20h for vendor-specific functions in addition
0029 to those in the Intel-specified vendor range.
0030 
0031 Our conversion process produces a result that is reported as two bytes.
0032 The fan speed control uses this finer value to produce a "step-less" fan
0033 PWM output. These two bytes are "read-locked" to guarantee that once a
0034 high or low byte is read, the other byte is locked-in until after the
0035 next read of any register. So to get an atomic reading, read high or low
0036 byte, then the very next read should be the opposite byte. Our data
0037 sheet says 10-bits of resolution, although you may find the lower bits
0038 are active, they are not necessarily reliable or useful externally. We
0039 chose not to mask them.
0040 
0041 We employ significant filtering that is user tunable as described in the
0042 data sheet. Our temperature reports and fan PWM outputs are very smooth
0043 when compared to the competition, in addition to the higher resolution
0044 temperature reports. The smoother PWM output does not require user
0045 intervention.
0046 
0047 We offer GPIO features on the former VID pins. These are open-drain
0048 outputs or inputs and may be used as general purpose I/O or as alarm
0049 outputs that are based on temperature limits. These are in 19h and 1Ah.
0050 
0051 We offer flexible mapping of temperature readings to thermal zones. Any
0052 temperature may be mapped to any zone, which has a default assignment
0053 that follows Intel's specs.
0054 
0055 Since there is a fan to zone assignment that allows for the "hotter" of
0056 a set of zones to control the PWM of an individual fan, but there is no
0057 indication to the user, we have added an indicator that shows which zone
0058 is currently controlling the PWM for a given fan. This is in register
0059 00h.
0060 
0061 Both remote diode temperature readings may be given an offset value such
0062 that the reported reading as well as the temperature used to determine
0063 PWM may be offset for system calibration purposes.
0064 
0065 PECI Extended configuration allows for having more than two domains per
0066 PECI address and also provides an enabling function for each PECI
0067 address. One could use our flexible zone assignment to have a zone
0068 assigned to up to 4 PECI addresses. This is not possible in the default
0069 Intel configuration. This would be useful in multi-CPU systems with
0070 individual fans on each that would benefit from individual fan control.
0071 This is in register 0Eh.
0072 
0073 The tachometer measurement system is flexible and able to adapt to many
0074 fan types. We can also support pulse-stretched PWM so that 3-wire fans
0075 may be used. These characteristics are in registers 04h to 07h.
0076 
0077 Finally, we have added a tach disable function that turns off the tach
0078 measurement system for individual tachs in order to save power. That is
0079 in register 75h.
0080 
0081 --------------------------------------------------------------------------
0082 
0083 aSC7621 Product Description
0084 ===========================
0085 
0086 The aSC7621 has a two wire digital interface compatible with SMBus 2.0.
0087 Using a 10-bit ADC, the aSC7621 measures the temperature of two remote diode
0088 connected transistors as well as its own die. Support for Platform
0089 Environmental Control Interface (PECI) is included.
0090 
0091 Using temperature information from these four zones, an automatic fan speed
0092 control algorithm is employed to minimize acoustic impact while achieving
0093 recommended CPU temperature under varying operational loads.
0094 
0095 To set fan speed, the aSC7621 has three independent pulse width modulation
0096 (PWM) outputs that are controlled by one, or a combination of three,
0097 temperature zones. Both high- and low-frequency PWM ranges are supported.
0098 
0099 The aSC7621 also includes a digital filter that can be invoked to smooth
0100 temperature readings for better control of fan speed and minimum acoustic
0101 impact.
0102 
0103 The aSC7621 has tachometer inputs to measure fan speed on up to four fans.
0104 Limit and status registers for all measured values are included to alert
0105 the system host that any measurements are outside of programmed limits
0106 via status registers.
0107 
0108 System voltages of VCCP, 2.5V, 3.3V, 5.0V, and 12V motherboard power are
0109 monitored efficiently with internal scaling resistors.
0110 
0111 Features
0112 --------
0113 
0114 - Supports PECI interface and monitors internal and remote thermal diodes
0115 - 2-wire, SMBus 2.0 compliant, serial interface
0116 - 10-bit ADC
0117 - Monitors VCCP, 2.5V, 3.3V, 5.0V, and 12V motherboard/processor supplies
0118 - Programmable autonomous fan control based on temperature readings
0119 - Noise filtering of temperature reading for fan speed control
0120 - 0.25C digital temperature sensor resolution
0121 - 3 PWM fan speed control outputs for 2-, 3- or 4-wire fans and up to 4 fan
0122   tachometer inputs
0123 - Enhanced measured temperature to Temperature Zone assignment.
0124 - Provides high and low PWM frequency ranges
0125 - 3 GPIO pins for custom use
0126 - 24-Lead QSOP package
0127 
0128 Configuration Notes
0129 ===================
0130 
0131 Except where noted below, the sysfs entries created by this driver follow
0132 the standards defined in "sysfs-interface".
0133 
0134 temp1_source
0135         =       ===============================================
0136         0       (default) peci_legacy = 0, Remote 1 Temperature
0137                 peci_legacy = 1, PECI Processor Temperature 0
0138         1       Remote 1 Temperature
0139         2       Remote 2 Temperature
0140         3       Internal Temperature
0141         4       PECI Processor Temperature 0
0142         5       PECI Processor Temperature 1
0143         6       PECI Processor Temperature 2
0144         7       PECI Processor Temperature 3
0145         =       ===============================================
0146 
0147 temp2_source
0148         =       ===============================================
0149         0       (default) Internal Temperature
0150         1       Remote 1 Temperature
0151         2       Remote 2 Temperature
0152         3       Internal Temperature
0153         4       PECI Processor Temperature 0
0154         5       PECI Processor Temperature 1
0155         6       PECI Processor Temperature 2
0156         7       PECI Processor Temperature 3
0157         =       ===============================================
0158 
0159 temp3_source
0160         =       ===============================================
0161         0       (default) Remote 2 Temperature
0162         1       Remote 1 Temperature
0163         2       Remote 2 Temperature
0164         3       Internal Temperature
0165         4       PECI Processor Temperature 0
0166         5       PECI Processor Temperature 1
0167         6       PECI Processor Temperature 2
0168         7       PECI Processor Temperature 3
0169         =       ===============================================
0170 
0171 temp4_source
0172         =       ===============================================
0173         0       (default) peci_legacy = 0, PECI Processor Temperature 0
0174                 peci_legacy = 1, Remote 1 Temperature
0175         1       Remote 1 Temperature
0176         2       Remote 2 Temperature
0177         3       Internal Temperature
0178         4       PECI Processor Temperature 0
0179         5       PECI Processor Temperature 1
0180         6       PECI Processor Temperature 2
0181         7       PECI Processor Temperature 3
0182         =       ===============================================
0183 
0184 temp[1-4]_smoothing_enable / temp[1-4]_smoothing_time
0185         Smooths spikes in temp readings caused by noise.
0186         Valid values in milliseconds are:
0187 
0188         * 35000
0189         * 17600
0190         * 11800
0191         *  7000
0192         *  4400
0193         *  3000
0194         *  1600
0195         *   800
0196 
0197 temp[1-4]_crit
0198         When the corresponding zone temperature reaches this value,
0199         ALL pwm outputs will got to 100%.
0200 
0201 temp[5-8]_input / temp[5-8]_enable
0202         The aSC7621 can also read temperatures provided by the processor
0203         via the PECI bus.  Usually these are "core" temps and are relative
0204         to the point where the automatic thermal control circuit starts
0205         throttling.  This means that these are usually negative numbers.
0206 
0207 pwm[1-3]_enable
0208         =============== ========================================================
0209         0               Fan off.
0210         1               Fan on manual control.
0211         2               Fan on automatic control and will run at the minimum pwm
0212                         if the temperature for the zone is below the minimum.
0213         3               Fan on automatic control but will be off if the
0214                         temperature for the zone is below the minimum.
0215         4-254           Ignored.
0216         255             Fan on full.
0217         =============== ========================================================
0218 
0219 pwm[1-3]_auto_channels
0220         Bitmap as described in sysctl-interface with the following
0221         exceptions...
0222 
0223         Only the following combination of zones (and their corresponding masks)
0224         are valid:
0225 
0226         * 1
0227         * 2
0228         * 3
0229         * 2,3
0230         * 1,2,3
0231         * 4
0232         * 1,2,3,4
0233 
0234         * Special values:
0235 
0236           ==            ======================
0237           0             Disabled.
0238           16            Fan on manual control.
0239           31            Fan on full.
0240           ==            ======================
0241 
0242 
0243 pwm[1-3]_invert
0244         When set, inverts the meaning of pwm[1-3].
0245         i.e.  when pwm = 0, the fan will be on full and
0246         when pwm = 255 the fan will be off.
0247 
0248 pwm[1-3]_freq
0249         PWM frequency in Hz
0250         Valid values in Hz are:
0251 
0252         * 10
0253         * 15
0254         * 23
0255         * 30  (default)
0256         * 38
0257         * 47
0258         * 62
0259         * 94
0260         * 23000
0261         * 24000
0262         * 25000
0263         * 26000
0264         * 27000
0265         * 28000
0266         * 29000
0267         * 30000
0268 
0269         Setting any other value will be ignored.
0270 
0271 peci_enable
0272         Enables or disables PECI
0273 
0274 peci_avg
0275         Input filter average time.
0276 
0277         * 0     0 Sec. (no Smoothing) (default)
0278         * 1     0.25 Sec.
0279         * 2     0.5 Sec.
0280         * 3     1.0 Sec.
0281         * 4     2.0 Sec.
0282         * 5     4.0 Sec.
0283         * 6     8.0 Sec.
0284         * 7     0.0 Sec.
0285 
0286 peci_legacy
0287         =       ============================================
0288         0       Standard Mode (default)
0289                 Remote Diode 1 reading is associated with
0290                 Temperature Zone 1, PECI is associated with
0291                 Zone 4
0292 
0293         1       Legacy Mode
0294                 PECI is associated with Temperature Zone 1,
0295                 Remote Diode 1 is associated with Zone 4
0296         =       ============================================
0297 
0298 peci_diode
0299         Diode filter
0300 
0301         =       ====================
0302         0       0.25 Sec.
0303         1       1.1 Sec.
0304         2       2.4 Sec.  (default)
0305         3       3.4 Sec.
0306         4       5.0 Sec.
0307         5       6.8 Sec.
0308         6       10.2 Sec.
0309         7       16.4 Sec.
0310         =       ====================
0311 
0312 peci_4domain
0313         Four domain enable
0314 
0315         =       ===============================================
0316         0       1 or 2 Domains for enabled processors (default)
0317         1       3 or 4 Domains for enabled processors
0318         =       ===============================================
0319 
0320 peci_domain
0321         Domain
0322 
0323         =       ==================================================
0324         0       Processor contains a single domain (0)   (default)
0325         1       Processor contains two domains (0,1)
0326         =       ==================================================