[PATCH] hwmon/hdaps: remove redundant sysfs invert

From: Frank Seidel
Date: Thu Feb 19 2009 - 07:51:26 EST


From: Frank Seidel <frank@xxxxxxxxxxx>

Get rid of sysfs attribute "invert" as its
redundant to module parameter.

Signed-off-by: Frank Seidel <frank@xxxxxxxxxxx>
---
drivers/hwmon/hdaps.c | 24 ------------------------
1 file changed, 24 deletions(-)

--- a/drivers/hwmon/hdaps.c
+++ b/drivers/hwmon/hdaps.c
@@ -428,28 +428,6 @@ static ssize_t hdaps_calibrate_store(str
return count;
}

-static ssize_t hdaps_invert_show(struct device *dev,
- struct device_attribute *attr, char *buf)
-{
- return sprintf(buf, "%u\n", hdaps_invert);
-}
-
-static ssize_t hdaps_invert_store(struct device *dev,
- struct device_attribute *attr,
- const char *buf, size_t count)
-{
- int invert;
-
- if (sscanf(buf, "%d", &invert) != 1 ||
- invert < 0 || invert > HDAPS_BOTH_AXES)
- return -EINVAL;
-
- hdaps_invert = invert;
- hdaps_calibrate();
-
- return count;
-}
-
static DEVICE_ATTR(position, 0444, hdaps_position_show, NULL);
static DEVICE_ATTR(variance, 0444, hdaps_variance_show, NULL);
static DEVICE_ATTR(temp1, 0444, hdaps_temp1_show, NULL);
@@ -457,7 +435,6 @@ static DEVICE_ATTR(temp2, 0444, hdaps_te
static DEVICE_ATTR(keyboard_activity, 0444, hdaps_keyboard_activity_show, NULL);
static DEVICE_ATTR(mouse_activity, 0444, hdaps_mouse_activity_show, NULL);
static DEVICE_ATTR(calibrate, 0644, hdaps_calibrate_show,hdaps_calibrate_store);
-static DEVICE_ATTR(invert, 0644, hdaps_invert_show, hdaps_invert_store);

static struct attribute *hdaps_attributes[] = {
&dev_attr_position.attr,
@@ -467,7 +444,6 @@ static struct attribute *hdaps_attribute
&dev_attr_keyboard_activity.attr,
&dev_attr_mouse_activity.attr,
&dev_attr_calibrate.attr,
- &dev_attr_invert.attr,
NULL,
};

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/