From 04cc862c1893a055ab1117fa6f3aa0886c0ba032 Mon Sep 17 00:00:00 2001 From: Henrique de Moraes Holschuh Date: Sat, 21 Apr 2007 11:08:43 -0300 Subject: ACPI: thinkpad-acpi: cleanup thermal subdriver for sysfs conversion Clean-up the thermal subdriver for sysfs conversion. Make thermal_get_* reentrancy-safe while at it, and add the missing thermal_read_mode variable to the header file. Signed-off-by: Henrique de Moraes Holschuh Signed-off-by: Len Brown --- drivers/misc/thinkpad_acpi.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'drivers/misc/thinkpad_acpi.h') diff --git a/drivers/misc/thinkpad_acpi.h b/drivers/misc/thinkpad_acpi.h index fb0abb02a016..6432b28339af 100644 --- a/drivers/misc/thinkpad_acpi.h +++ b/drivers/misc/thinkpad_acpi.h @@ -427,12 +427,20 @@ enum thermal_access_mode { TPACPI_THERMAL_TPEC_16, /* Use ACPI EC regs, 16 sensors */ }; +enum { /* TPACPI_THERMAL_TPEC_* */ + TP_EC_THERMAL_TMP0 = 0x78, /* ACPI EC regs TMP 0..7 */ + TP_EC_THERMAL_TMP8 = 0xC0, /* ACPI EC regs TMP 8..15 */ +}; + #define TPACPI_MAX_THERMAL_SENSORS 16 /* Max thermal sensors supported */ struct ibm_thermal_sensors_struct { s32 temp[TPACPI_MAX_THERMAL_SENSORS]; }; +static enum thermal_access_mode thermal_read_mode; + static int thermal_init(struct ibm_init_struct *iibm); +static int thermal_get_sensor(int idx, s32 *value); static int thermal_get_sensors(struct ibm_thermal_sensors_struct *s); static int thermal_read(char *p); -- cgit v1.2.3-59-g8ed1b