diff options
author | Krzysztof Helt <krzysztof.h1@wp.pl> | 2007-09-09 11:35:34 -0400 |
---|---|---|
committer | Mark M. Hoffman <mhoffman@lightlink.com> | 2007-10-09 22:56:30 -0400 |
commit | bba891c24a77419e9dcf76f866bd0d8ecf66d770 (patch) | |
tree | 61a79dfadf447efedeee3d3b0764030fe94b65a4 /drivers/hwmon | |
parent | c7f1f7166a83f8f5607cc03c7a6c5f936cde6b0d (diff) |
hwmon: (thmc50) Fix alarms clearing
This patch make use the interrupt status register instead
of the interrupt status mirror register. Reading of the mirror
register does not clear alarms.
Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
Diffstat (limited to 'drivers/hwmon')
-rw-r--r-- | drivers/hwmon/thmc50.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/hwmon/thmc50.c b/drivers/hwmon/thmc50.c index 981d1f1dc61f..f79c7504204e 100644 --- a/drivers/hwmon/thmc50.c +++ b/drivers/hwmon/thmc50.c | |||
@@ -47,10 +47,10 @@ I2C_CLIENT_MODULE_PARM(adm1022_temp3, "List of adapter,address pairs " | |||
47 | #define THMC50_REG_DIE_CODE 0x3F | 47 | #define THMC50_REG_DIE_CODE 0x3F |
48 | #define THMC50_REG_ANALOG_OUT 0x19 | 48 | #define THMC50_REG_ANALOG_OUT 0x19 |
49 | /* | 49 | /* |
50 | * We use mirror status register for reading alarms | 50 | * The mirror status register cannot be used as |
51 | * so ACPI can use the primary status register. | 51 | * reading it does not clear alarms. |
52 | */ | 52 | */ |
53 | #define THMC50_REG_INTR_MIRROR 0x4C | 53 | #define THMC50_REG_INTR 0x41 |
54 | 54 | ||
55 | const static u8 THMC50_REG_TEMP[] = { 0x27, 0x26, 0x20 }; | 55 | const static u8 THMC50_REG_TEMP[] = { 0x27, 0x26, 0x20 }; |
56 | const static u8 THMC50_REG_TEMP_MIN[] = { 0x3A, 0x38, 0x2C }; | 56 | const static u8 THMC50_REG_TEMP_MIN[] = { 0x3A, 0x38, 0x2C }; |
@@ -441,7 +441,7 @@ static struct thmc50_data *thmc50_update_device(struct device *dev) | |||
441 | data->analog_out = | 441 | data->analog_out = |
442 | i2c_smbus_read_byte_data(client, THMC50_REG_ANALOG_OUT); | 442 | i2c_smbus_read_byte_data(client, THMC50_REG_ANALOG_OUT); |
443 | data->alarms = | 443 | data->alarms = |
444 | i2c_smbus_read_byte_data(client, THMC50_REG_INTR_MIRROR); | 444 | i2c_smbus_read_byte_data(client, THMC50_REG_INTR); |
445 | data->last_updated = jiffies; | 445 | data->last_updated = jiffies; |
446 | data->valid = 1; | 446 | data->valid = 1; |
447 | } | 447 | } |