1.. SPDX-License-Identifier: GPL-2.0-or-later 2 3Kernel driver emc1812 4===================== 5 6Supported chips: 7 8 * Microchip EMC1812, EMC1813, EMC1814, EMC1815, EMC1833 9 10 Prefix: 'emc1812' 11 12 Datasheets: 13 14 - https://ww1.microchip.com/downloads/aemDocuments/documents/MSLD/ProductDocuments/DataSheets/EMC1812-3-4-5-33-Data-Sheet-DS20005751.pdf 15 16Author: 17 Marius Cristea <marius.cristea@microchip.com> 18 19 20Description 21----------- 22 23The Microchip EMC181x/33 chips contain up to 4 remote temperature sensors 24and one internal. 25- The EMC1812 is a single channel remote temperature sensor. 26- The EMC1813 and EMC1833 are dual channel remote temperature sensor. The 27remote channels for this selection of devices can support substrate diodes, 28discrete diode-connected transistors or CPU/GPU thermal diodes. 29- The EMC1814 is a three channel remote temperature sensor that supports 30Anti-Parallel Diode (APD) only on one channel. For the channel that does not 31support APD functionality, substrate diodes, discrete diode-connected 32transistors or CPU/GPU thermal diodes are supported. For the channel that 33supports APD, only discrete diode-connected transistors may be implemented. 34However, if APD is disabled on the EMC1814, then the channel that supports 35APD will be functional with substrate diodes, discrete diode-connected 36transistors and CPU/GPU thermal diodes. 37- The EMC1815 is a four channel remote temperature sensor. 38 39The EMC1815 and EMC1833 support APD on all channels. When APD is enabled, 40the channels support only diode-connected transistors. If APD is disabled, 41then the channels will support substrate transistors, discrete diode-connected 42transistors and CPU/GPU thermal diodes. 43 44Note: Disabling APD functionality to implement substrate diodes on devices 45that support APD eliminates the benefit of APD (two diodes on one channel). 46 47The chips implement three limits for each sensor: low (tempX_min), high 48(tempX_max) and critical (tempX_crit). The chips also implement an 49hysteresis mechanism which applies to all limits. The relative difference 50is stored in a single register on the chip, which means that the relative 51difference between the limit and its hysteresis is always the same for 52all three limits. 53 54This implementation detail implies the following: 55 56* When setting a limit, its hysteresis will automatically follow, the 57 difference staying unchanged. For example, if the old critical limit was 58 80 degrees C, and the hysteresis was 75 degrees C, and you change the 59 critical limit to 90 degrees C, then the hysteresis will automatically 60 change to 85 degrees C. 61* The hysteresis values can't be set independently. We decided to make 62 only tempX_crit_hyst writable, while all other hysteresis attributes 63 are read-only. Setting tempX_crit_hyst writes the difference between 64 tempX_crit_hyst and tempX_crit into the chip, and the same relative 65 hysteresis applies automatically to all other limits. 66* The limits should be set before the hysteresis. At power up the device 67 starts with 10 degree hysteresis. 68