diff options
author | Guenter Roeck <linux@roeck-us.net> | 2012-09-04 21:57:08 -0400 |
---|---|---|
committer | Guenter Roeck <linux@roeck-us.net> | 2012-09-24 00:08:34 -0400 |
commit | f4a41eeac90eaed4e21007e75d21fb74e3588f53 (patch) | |
tree | fcfd0d607ce98ffa43db6a5efe47e3c6b46de30b /drivers/hwmon | |
parent | 146ab288bbe037aa85a233221cd8d9a84bedcf85 (diff) |
hwmon: (adm9240) Remove legacy chassis intrusion detection sysfs attribute
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'drivers/hwmon')
-rw-r--r-- | drivers/hwmon/adm9240.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/drivers/hwmon/adm9240.c b/drivers/hwmon/adm9240.c index 5a78d102a0fa..8b24d1a4a2b4 100644 --- a/drivers/hwmon/adm9240.c +++ b/drivers/hwmon/adm9240.c | |||
@@ -500,31 +500,6 @@ static ssize_t set_aout(struct device *dev, | |||
500 | } | 500 | } |
501 | static DEVICE_ATTR(aout_output, S_IRUGO | S_IWUSR, show_aout, set_aout); | 501 | static DEVICE_ATTR(aout_output, S_IRUGO | S_IWUSR, show_aout, set_aout); |
502 | 502 | ||
503 | /* chassis_clear */ | ||
504 | static ssize_t chassis_clear_legacy(struct device *dev, | ||
505 | struct device_attribute *attr, | ||
506 | const char *buf, size_t count) | ||
507 | { | ||
508 | struct i2c_client *client = to_i2c_client(dev); | ||
509 | long val; | ||
510 | int err; | ||
511 | |||
512 | err = kstrtol(buf, 10, &val); | ||
513 | if (err) | ||
514 | return err; | ||
515 | |||
516 | dev_warn(dev, "Attribute chassis_clear is deprecated, " | ||
517 | "use intrusion0_alarm instead\n"); | ||
518 | |||
519 | if (val == 1) { | ||
520 | i2c_smbus_write_byte_data(client, | ||
521 | ADM9240_REG_CHASSIS_CLEAR, 0x80); | ||
522 | dev_dbg(&client->dev, "chassis intrusion latch cleared\n"); | ||
523 | } | ||
524 | return count; | ||
525 | } | ||
526 | static DEVICE_ATTR(chassis_clear, S_IWUSR, NULL, chassis_clear_legacy); | ||
527 | |||
528 | static ssize_t chassis_clear(struct device *dev, | 503 | static ssize_t chassis_clear(struct device *dev, |
529 | struct device_attribute *attr, | 504 | struct device_attribute *attr, |
530 | const char *buf, size_t count) | 505 | const char *buf, size_t count) |
@@ -586,7 +561,6 @@ static struct attribute *adm9240_attributes[] = { | |||
586 | &sensor_dev_attr_fan2_alarm.dev_attr.attr, | 561 | &sensor_dev_attr_fan2_alarm.dev_attr.attr, |
587 | &dev_attr_alarms.attr, | 562 | &dev_attr_alarms.attr, |
588 | &dev_attr_aout_output.attr, | 563 | &dev_attr_aout_output.attr, |
589 | &dev_attr_chassis_clear.attr, | ||
590 | &sensor_dev_attr_intrusion0_alarm.dev_attr.attr, | 564 | &sensor_dev_attr_intrusion0_alarm.dev_attr.attr, |
591 | &dev_attr_cpu0_vid.attr, | 565 | &dev_attr_cpu0_vid.attr, |
592 | NULL | 566 | NULL |