diff options
author | Clemens Ladisch <clemens@ladisch.de> | 2011-02-16 08:02:38 -0500 |
---|---|---|
committer | Guenter Roeck <guenter.roeck@ericsson.com> | 2011-02-16 11:18:33 -0500 |
commit | 2c6315da6a1657a49e03970a4084dc3d1958ad70 (patch) | |
tree | e2b8f4639578e4f81e9371778c6f45faabe3c87e /Documentation/hwmon/jc42 | |
parent | d5622f5b6c4671d1588ccc9056705366d4eb312a (diff) |
hwmon: (jc42) do not allow writing to locked registers
On systems where the temperature sensor is actually used, the BIOS is
likely to have locked the alarm registers. In that case, all writes
through the corresponding sysfs files would be silently ignored.
To prevent this, detect the locks and make the affected sysfs files
read-only.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: stable@kernel.org
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Diffstat (limited to 'Documentation/hwmon/jc42')
-rw-r--r-- | Documentation/hwmon/jc42 | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/Documentation/hwmon/jc42 b/Documentation/hwmon/jc42 index 2a0924003f92..a22ecf48f255 100644 --- a/Documentation/hwmon/jc42 +++ b/Documentation/hwmon/jc42 | |||
@@ -86,15 +86,19 @@ limits. The chip supports only a single register to configure the hysteresis, | |||
86 | which applies to all limits. This register can be written by writing into | 86 | which applies to all limits. This register can be written by writing into |
87 | temp1_crit_hyst. Other hysteresis attributes are read-only. | 87 | temp1_crit_hyst. Other hysteresis attributes are read-only. |
88 | 88 | ||
89 | If the BIOS has configured the sensor for automatic temperature management, it | ||
90 | is likely that it has locked the registers, i.e., that the temperature limits | ||
91 | cannot be changed. | ||
92 | |||
89 | Sysfs entries | 93 | Sysfs entries |
90 | ------------- | 94 | ------------- |
91 | 95 | ||
92 | temp1_input Temperature (RO) | 96 | temp1_input Temperature (RO) |
93 | temp1_min Minimum temperature (RW) | 97 | temp1_min Minimum temperature (RO or RW) |
94 | temp1_max Maximum temperature (RW) | 98 | temp1_max Maximum temperature (RO or RW) |
95 | temp1_crit Critical high temperature (RW) | 99 | temp1_crit Critical high temperature (RO or RW) |
96 | 100 | ||
97 | temp1_crit_hyst Critical hysteresis temperature (RW) | 101 | temp1_crit_hyst Critical hysteresis temperature (RO or RW) |
98 | temp1_max_hyst Maximum hysteresis temperature (RO) | 102 | temp1_max_hyst Maximum hysteresis temperature (RO) |
99 | 103 | ||
100 | temp1_min_alarm Temperature low alarm | 104 | temp1_min_alarm Temperature low alarm |