diff options
author | Jean Delvare <khali@linux-fr.org> | 2007-08-16 08:30:01 -0400 |
---|---|---|
committer | Mark M. Hoffman <mhoffman@lightlink.com> | 2007-10-09 22:56:29 -0400 |
commit | b26f93309282bdfebb3edb8939e022a4bbe56dfe (patch) | |
tree | 639c84137751e908b192de9586f8dc3ecefe718d /drivers/hwmon/w83627hf.c | |
parent | 5bfedac045082a97e20d47d876071279ef984d28 (diff) |
hwmon: Don't export thermistor beta
Deprecate the use of thermistor beta values as thermal sensor types.
No driver supports changing the beta value anyway.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
Diffstat (limited to 'drivers/hwmon/w83627hf.c')
-rw-r--r-- | drivers/hwmon/w83627hf.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/hwmon/w83627hf.c b/drivers/hwmon/w83627hf.c index 0866739a227c..f0e0e208be9a 100644 --- a/drivers/hwmon/w83627hf.c +++ b/drivers/hwmon/w83627hf.c | |||
@@ -372,11 +372,8 @@ struct w83627hf_data { | |||
372 | u8 beep_enable; /* Boolean */ | 372 | u8 beep_enable; /* Boolean */ |
373 | u8 pwm[3]; /* Register value */ | 373 | u8 pwm[3]; /* Register value */ |
374 | u8 pwm_freq[3]; /* Register value */ | 374 | u8 pwm_freq[3]; /* Register value */ |
375 | u16 sens[3]; /* 782D/783S only. | 375 | u16 sens[3]; /* 1 = pentium diode; 2 = 3904 diode; |
376 | 1 = pentium diode; 2 = 3904 diode; | 376 | 4 = thermistor */ |
377 | 3000-5000 = thermistor beta. | ||
378 | Default = 3435. | ||
379 | Other Betas unimplemented */ | ||
380 | u8 vrm; | 377 | u8 vrm; |
381 | u8 vrm_ovt; /* Register value, 627THF/637HF/687THF only */ | 378 | u8 vrm_ovt; /* Register value, 627THF/637HF/687THF only */ |
382 | }; | 379 | }; |
@@ -1001,7 +998,11 @@ store_sensor_reg(struct device *dev, const char *buf, size_t count, int nr) | |||
1001 | tmp & ~BIT_SCFG2[nr - 1]); | 998 | tmp & ~BIT_SCFG2[nr - 1]); |
1002 | data->sens[nr - 1] = val; | 999 | data->sens[nr - 1] = val; |
1003 | break; | 1000 | break; |
1004 | case W83781D_DEFAULT_BETA: /* thermistor */ | 1001 | case W83781D_DEFAULT_BETA: |
1002 | dev_warn(dev, "Sensor type %d is deprecated, please use 4 " | ||
1003 | "instead\n", W83781D_DEFAULT_BETA); | ||
1004 | /* fall through */ | ||
1005 | case 4: /* thermistor */ | ||
1005 | tmp = w83627hf_read_value(data, W83781D_REG_SCFG1); | 1006 | tmp = w83627hf_read_value(data, W83781D_REG_SCFG1); |
1006 | w83627hf_write_value(data, W83781D_REG_SCFG1, | 1007 | w83627hf_write_value(data, W83781D_REG_SCFG1, |
1007 | tmp & ~BIT_SCFG1[nr - 1]); | 1008 | tmp & ~BIT_SCFG1[nr - 1]); |
@@ -1009,8 +1010,8 @@ store_sensor_reg(struct device *dev, const char *buf, size_t count, int nr) | |||
1009 | break; | 1010 | break; |
1010 | default: | 1011 | default: |
1011 | dev_err(dev, | 1012 | dev_err(dev, |
1012 | "Invalid sensor type %ld; must be 1, 2, or %d\n", | 1013 | "Invalid sensor type %ld; must be 1, 2, or 4\n", |
1013 | (long) val, W83781D_DEFAULT_BETA); | 1014 | (long) val); |
1014 | break; | 1015 | break; |
1015 | } | 1016 | } |
1016 | 1017 | ||
@@ -1513,7 +1514,7 @@ static void __devinit w83627hf_init_device(struct platform_device *pdev) | |||
1513 | tmp = w83627hf_read_value(data, W83781D_REG_SCFG1); | 1514 | tmp = w83627hf_read_value(data, W83781D_REG_SCFG1); |
1514 | for (i = 1; i <= 3; i++) { | 1515 | for (i = 1; i <= 3; i++) { |
1515 | if (!(tmp & BIT_SCFG1[i - 1])) { | 1516 | if (!(tmp & BIT_SCFG1[i - 1])) { |
1516 | data->sens[i - 1] = W83781D_DEFAULT_BETA; | 1517 | data->sens[i - 1] = 4; |
1517 | } else { | 1518 | } else { |
1518 | if (w83627hf_read_value | 1519 | if (w83627hf_read_value |
1519 | (data, | 1520 | (data, |