aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Malý <madcatxster@devoid-pointer.net>2015-04-08 16:56:41 -0400
committerJiri Kosina <jkosina@suse.cz>2015-05-07 10:27:08 -0400
commitfbf85e2ad1ade7bcc9efa0557c19bea5fffd192a (patch)
treeb5ede0e581eaecb376a48137e277f151b1bd5aa9
parentd0afd84893ebdbbe6dc022514cd6b62fbc90a034 (diff)
HID: hid-lg4ff: Replace DEVICE_ATTR_RW with DEVICE_ATTR to have all internal functions prefixed with "lg4ff_"
Replace DEVICE_ATTR_RW with DEVICE_ATTR to have all internal functions prefixed with "lg4ff_". All internal functions should be prefixed with just "lg4ff_". Usage of DEVICE_ATTR_RW breaks this scheme because it expects the functions' names to match the name of the respective sysfs entry. This partially reverts "2f1cec3250e38609bf9252db52dbbe61603c04a7" Signed-off-by: Michal Malý <madcatxster@devoid-pointer.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
-rw-r--r--drivers/hid/hid-lg4ff.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/hid/hid-lg4ff.c b/drivers/hid/hid-lg4ff.c
index 9a0c0e5f42d6..cec84a583b9b 100644
--- a/drivers/hid/hid-lg4ff.c
+++ b/drivers/hid/hid-lg4ff.c
@@ -721,9 +721,9 @@ static ssize_t lg4ff_alternate_modes_store(struct device *dev, struct device_att
721} 721}
722static DEVICE_ATTR(alternate_modes, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH, lg4ff_alternate_modes_show, lg4ff_alternate_modes_store); 722static DEVICE_ATTR(alternate_modes, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH, lg4ff_alternate_modes_show, lg4ff_alternate_modes_store);
723 723
724/* Read current range and display it in terminal */ 724/* Export the currently set range of the wheel */
725static ssize_t range_show(struct device *dev, struct device_attribute *attr, 725static ssize_t lg4ff_range_show(struct device *dev, struct device_attribute *attr,
726 char *buf) 726 char *buf)
727{ 727{
728 struct hid_device *hid = to_hid_device(dev); 728 struct hid_device *hid = to_hid_device(dev);
729 struct lg4ff_device_entry *entry; 729 struct lg4ff_device_entry *entry;
@@ -748,8 +748,8 @@ static ssize_t range_show(struct device *dev, struct device_attribute *attr,
748 748
749/* Set range to user specified value, call appropriate function 749/* Set range to user specified value, call appropriate function
750 * according to the type of the wheel */ 750 * according to the type of the wheel */
751static ssize_t range_store(struct device *dev, struct device_attribute *attr, 751static ssize_t lg4ff_range_store(struct device *dev, struct device_attribute *attr,
752 const char *buf, size_t count) 752 const char *buf, size_t count)
753{ 753{
754 struct hid_device *hid = to_hid_device(dev); 754 struct hid_device *hid = to_hid_device(dev);
755 struct lg4ff_device_entry *entry; 755 struct lg4ff_device_entry *entry;
@@ -780,7 +780,7 @@ static ssize_t range_store(struct device *dev, struct device_attribute *attr,
780 780
781 return count; 781 return count;
782} 782}
783static DEVICE_ATTR_RW(range); 783static DEVICE_ATTR(range, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH, lg4ff_range_show, lg4ff_range_store);
784 784
785static ssize_t lg4ff_real_id_show(struct device *dev, struct device_attribute *attr, char *buf) 785static ssize_t lg4ff_real_id_show(struct device *dev, struct device_attribute *attr, char *buf)
786{ 786{