Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

revert "hwmon: f71882fg: add support for the Fintek F71808E"

Revert commit 7721fea3d0fd93fb4d000eb737b444369358d6d3 ("hwmon:
f71882fg: add support for the Fintek F71808E").

Hans said:

: A second review after I've received a data sheet for this device from
: Fintek has turned up a few bugs.
:
: Unfortunately Giel (nor I) have time to fix this in time for the 2.6.36
: cycle. Therefor I would like to see this patch reverted as not having any
: support for the hwmon function of this superio chip is better then having
: unreliable support.

Cc: Giel van Schijndel <me@mortis.eu>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Andrew Morton and committed by
Linus Torvalds
f2e41e91 a25effa4

+11 -82
-4
Documentation/hwmon/f71882fg
··· 2 2 ====================== 3 3 4 4 Supported chips: 5 - * Fintek F71808E 6 - Prefix: 'f71808fg' 7 - Addresses scanned: none, address read from Super I/O config space 8 - Datasheet: Not public 9 5 * Fintek F71858FG 10 6 Prefix: 'f71858fg' 11 7 Addresses scanned: none, address read from Super I/O config space
+3 -3
drivers/hwmon/Kconfig
··· 332 332 will be called f71805f. 333 333 334 334 config SENSORS_F71882FG 335 - tristate "Fintek F71808E, F71858FG, F71862FG, F71882FG, F71889FG and F8000" 335 + tristate "Fintek F71858FG, F71862FG, F71882FG, F71889FG and F8000" 336 336 depends on EXPERIMENTAL 337 337 help 338 - If you say yes here you get support for hardware monitoring features 339 - of the Fintek F71808E, F71858FG, F71862FG/71863FG, F71882FG/F71883FG, 338 + If you say yes here you get support for hardware monitoring 339 + features of the Fintek F71858FG, F71862FG/71863FG, F71882FG/F71883FG, 340 340 F71889FG and F8000 Super-I/O chips. 341 341 342 342 This driver can also be built as a module. If so, the module
+8 -75
drivers/hwmon/f71882fg.c
··· 45 45 #define SIO_REG_ADDR 0x60 /* Logical device address (2 bytes) */ 46 46 47 47 #define SIO_FINTEK_ID 0x1934 /* Manufacturers ID */ 48 - #define SIO_F71808_ID 0x0901 /* Chipset ID */ 49 48 #define SIO_F71858_ID 0x0507 /* Chipset ID */ 50 49 #define SIO_F71862_ID 0x0601 /* Chipset ID */ 51 50 #define SIO_F71882_ID 0x0541 /* Chipset ID */ ··· 96 97 module_param(force_id, ushort, 0); 97 98 MODULE_PARM_DESC(force_id, "Override the detected device ID"); 98 99 99 - enum chips { f71808fg, f71858fg, f71862fg, f71882fg, f71889fg, f8000 }; 100 + enum chips { f71858fg, f71862fg, f71882fg, f71889fg, f8000 }; 100 101 101 102 static const char *f71882fg_names[] = { 102 - "f71808fg", 103 103 "f71858fg", 104 104 "f71862fg", 105 105 "f71882fg", ··· 306 308 SENSOR_ATTR_2(temp3_fault, S_IRUGO, show_temp_fault, NULL, 0, 2), 307 309 }; 308 310 309 - /* In attr common to the f71862fg, f71882fg and f71889fg */ 310 - static struct sensor_device_attribute_2 fxxxx_in_attr[] = { 311 + /* Temp and in attr common to the f71862fg, f71882fg and f71889fg */ 312 + static struct sensor_device_attribute_2 fxxxx_in_temp_attr[] = { 311 313 SENSOR_ATTR_2(in0_input, S_IRUGO, show_in, NULL, 0, 0), 312 314 SENSOR_ATTR_2(in1_input, S_IRUGO, show_in, NULL, 0, 1), 313 315 SENSOR_ATTR_2(in2_input, S_IRUGO, show_in, NULL, 0, 2), ··· 317 319 SENSOR_ATTR_2(in6_input, S_IRUGO, show_in, NULL, 0, 6), 318 320 SENSOR_ATTR_2(in7_input, S_IRUGO, show_in, NULL, 0, 7), 319 321 SENSOR_ATTR_2(in8_input, S_IRUGO, show_in, NULL, 0, 8), 320 - }; 321 - 322 - /* In attr for the f71808fg */ 323 - static struct sensor_device_attribute_2 f71808_in_attr[] = { 324 - SENSOR_ATTR_2(in0_input, S_IRUGO, show_in, NULL, 0, 0), 325 - SENSOR_ATTR_2(in1_input, S_IRUGO, show_in, NULL, 0, 1), 326 - SENSOR_ATTR_2(in2_input, S_IRUGO, show_in, NULL, 0, 2), 327 - SENSOR_ATTR_2(in3_input, S_IRUGO, show_in, NULL, 0, 3), 328 - SENSOR_ATTR_2(in4_input, S_IRUGO, show_in, NULL, 0, 4), 329 - SENSOR_ATTR_2(in5_input, S_IRUGO, show_in, NULL, 0, 5), 330 - SENSOR_ATTR_2(in6_input, S_IRUGO, show_in, NULL, 0, 7), 331 - SENSOR_ATTR_2(in7_input, S_IRUGO, show_in, NULL, 0, 8), 332 - }; 333 - 334 - /* Temp attr common to the f71808fg, f71862fg, f71882fg and f71889fg */ 335 - static struct sensor_device_attribute_2 fxxxx_temp_attr[] = { 336 322 SENSOR_ATTR_2(temp1_input, S_IRUGO, show_temp, NULL, 0, 1), 337 323 SENSOR_ATTR_2(temp1_max, S_IRUGO|S_IWUSR, show_temp_max, 338 324 store_temp_max, 0, 1), ··· 355 373 store_temp_beep, 0, 6), 356 374 SENSOR_ATTR_2(temp2_type, S_IRUGO, show_temp_type, NULL, 0, 2), 357 375 SENSOR_ATTR_2(temp2_fault, S_IRUGO, show_temp_fault, NULL, 0, 2), 358 - }; 359 - 360 - /* Temp and in attr common to the f71862fg, f71882fg and f71889fg */ 361 - static struct sensor_device_attribute_2 f71862_temp_attr[] = { 362 376 SENSOR_ATTR_2(temp3_input, S_IRUGO, show_temp, NULL, 0, 3), 363 377 SENSOR_ATTR_2(temp3_max, S_IRUGO|S_IWUSR, show_temp_max, 364 378 store_temp_max, 0, 3), ··· 989 1011 data->temp_type[1] = 6; 990 1012 break; 991 1013 } 992 - } else if (data->type == f71808fg) { 993 - reg = f71882fg_read8(data, F71882FG_REG_TEMP_TYPE); 994 - data->temp_type[1] = (reg & 0x02) ? 2 : 4; 995 - data->temp_type[2] = (reg & 0x04) ? 2 : 4; 996 - 997 1014 } else { 998 1015 reg2 = f71882fg_read8(data, F71882FG_REG_PECI); 999 1016 if ((reg2 & 0x03) == 0x01) ··· 1871 1898 1872 1899 val /= 1000; 1873 1900 1874 - if (data->type == f71889fg 1875 - || data->type == f71808fg) 1901 + if (data->type == f71889fg) 1876 1902 val = SENSORS_LIMIT(val, -128, 127); 1877 1903 else 1878 1904 val = SENSORS_LIMIT(val, 0, 127); ··· 1974 2002 /* fall through! */ 1975 2003 case f71862fg: 1976 2004 err = f71882fg_create_sysfs_files(pdev, 1977 - f71862_temp_attr, 1978 - ARRAY_SIZE(f71862_temp_attr)); 1979 - if (err) 1980 - goto exit_unregister_sysfs; 1981 - err = f71882fg_create_sysfs_files(pdev, 1982 - fxxxx_in_attr, 1983 - ARRAY_SIZE(fxxxx_in_attr)); 1984 - if (err) 1985 - goto exit_unregister_sysfs; 1986 - err = f71882fg_create_sysfs_files(pdev, 1987 - fxxxx_temp_attr, 1988 - ARRAY_SIZE(fxxxx_temp_attr)); 1989 - break; 1990 - case f71808fg: 1991 - err = f71882fg_create_sysfs_files(pdev, 1992 - f71808_in_attr, 1993 - ARRAY_SIZE(f71808_in_attr)); 1994 - if (err) 1995 - goto exit_unregister_sysfs; 1996 - err = f71882fg_create_sysfs_files(pdev, 1997 - fxxxx_temp_attr, 1998 - ARRAY_SIZE(fxxxx_temp_attr)); 2005 + fxxxx_in_temp_attr, 2006 + ARRAY_SIZE(fxxxx_in_temp_attr)); 1999 2007 break; 2000 2008 case f8000: 2001 2009 err = f71882fg_create_sysfs_files(pdev, ··· 2002 2050 case f71862fg: 2003 2051 err = (data->pwm_enable & 0x15) != 0x15; 2004 2052 break; 2005 - case f71808fg: 2006 2053 case f71882fg: 2007 2054 case f71889fg: 2008 2055 err = 0; ··· 2047 2096 f8000_auto_pwm_attr, 2048 2097 ARRAY_SIZE(f8000_auto_pwm_attr)); 2049 2098 break; 2050 - case f71808fg: 2051 2099 case f71889fg: 2052 2100 for (i = 0; i < nr_fans; i++) { 2053 2101 data->pwm_auto_point_mapping[i] = ··· 2126 2176 /* fall through! */ 2127 2177 case f71862fg: 2128 2178 f71882fg_remove_sysfs_files(pdev, 2129 - f71862_temp_attr, 2130 - ARRAY_SIZE(f71862_temp_attr)); 2131 - f71882fg_remove_sysfs_files(pdev, 2132 - fxxxx_in_attr, 2133 - ARRAY_SIZE(fxxxx_in_attr)); 2134 - f71882fg_remove_sysfs_files(pdev, 2135 - fxxxx_temp_attr, 2136 - ARRAY_SIZE(fxxxx_temp_attr)); 2137 - break; 2138 - case f71808fg: 2139 - f71882fg_remove_sysfs_files(pdev, 2140 - f71808_in_attr, 2141 - ARRAY_SIZE(f71808_in_attr)); 2142 - f71882fg_remove_sysfs_files(pdev, 2143 - fxxxx_temp_attr, 2144 - ARRAY_SIZE(fxxxx_temp_attr)); 2179 + fxxxx_in_temp_attr, 2180 + ARRAY_SIZE(fxxxx_in_temp_attr)); 2145 2181 break; 2146 2182 case f8000: 2147 2183 f71882fg_remove_sysfs_files(pdev, ··· 2195 2259 2196 2260 devid = force_id ? force_id : superio_inw(sioaddr, SIO_REG_DEVID); 2197 2261 switch (devid) { 2198 - case SIO_F71808_ID: 2199 - sio_data->type = f71808fg; 2200 - break; 2201 2262 case SIO_F71858_ID: 2202 2263 sio_data->type = f71858fg; 2203 2264 break;