summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorStefan Achatz <stefan_achatz@web.de>2012-11-11 06:21:19 +0100
committerJiri Kosina <jkosina@suse.cz>2012-11-12 15:30:29 +0100
commit172e2abc19b51feef5b7980055725f0b242e988e (patch)
treed16cf15bc518cfc6c70271a5aed3d1312c138d04 /drivers
parentbb060d65c3bf1d0211262e8229097d9a1beab20d (diff)
downloadlinux-172e2abc19b51feef5b7980055725f0b242e988e.tar.gz
HID: roccat: deprecate some Kovaplus attributes
Introduced attribute "control" and made profile_settings and profile_buttons readable, which makes profile[1-5]_settings and profile[1-5]_buttons obsolete. Signed-off-by: Stefan Achatz <erazor_de@users.sourceforge.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/hid/hid-roccat-kovaplus.c10
-rw-r--r--drivers/hid/hid-roccat-kovaplus.h2
2 files changed, 8 insertions, 4 deletions
diff --git a/drivers/hid/hid-roccat-kovaplus.c b/drivers/hid/hid-roccat-kovaplus.c
index 1589fd3bcf0f..b8b37789b864 100644
--- a/drivers/hid/hid-roccat-kovaplus.c
+++ b/drivers/hid/hid-roccat-kovaplus.c
@@ -218,9 +218,10 @@ KOVAPLUS_SYSFS_R(thingy, THINGY)
.write = kovaplus_sysfs_write_ ## thingy \
}
+KOVAPLUS_SYSFS_W(control, CONTROL)
KOVAPLUS_SYSFS_RW(info, INFO)
-KOVAPLUS_SYSFS_W(profile_settings, PROFILE_SETTINGS)
-KOVAPLUS_SYSFS_W(profile_buttons, PROFILE_BUTTONS)
+KOVAPLUS_SYSFS_RW(profile_settings, PROFILE_SETTINGS)
+KOVAPLUS_SYSFS_RW(profile_buttons, PROFILE_BUTTONS)
static ssize_t kovaplus_sysfs_read_profilex_settings(struct file *fp,
struct kobject *kobj, struct bin_attribute *attr, char *buf,
@@ -369,9 +370,10 @@ static struct device_attribute kovaplus_attributes[] = {
};
static struct bin_attribute kovaplus_bin_attributes[] = {
+ KOVAPLUS_BIN_ATTRIBUTE_W(control, CONTROL),
KOVAPLUS_BIN_ATTRIBUTE_RW(info, INFO),
- KOVAPLUS_BIN_ATTRIBUTE_W(profile_settings, PROFILE_SETTINGS),
- KOVAPLUS_BIN_ATTRIBUTE_W(profile_buttons, PROFILE_BUTTONS),
+ KOVAPLUS_BIN_ATTRIBUTE_RW(profile_settings, PROFILE_SETTINGS),
+ KOVAPLUS_BIN_ATTRIBUTE_RW(profile_buttons, PROFILE_BUTTONS),
{
.attr = { .name = "profile1_settings", .mode = 0440 },
.size = KOVAPLUS_SIZE_PROFILE_SETTINGS,
diff --git a/drivers/hid/hid-roccat-kovaplus.h b/drivers/hid/hid-roccat-kovaplus.h
index 1189573daee2..fbb7a16a7e54 100644
--- a/drivers/hid/hid-roccat-kovaplus.h
+++ b/drivers/hid/hid-roccat-kovaplus.h
@@ -15,6 +15,7 @@
#include <linux/types.h>
enum {
+ KOVAPLUS_SIZE_CONTROL = 0x03,
KOVAPLUS_SIZE_INFO = 0x06,
KOVAPLUS_SIZE_PROFILE_SETTINGS = 0x10,
KOVAPLUS_SIZE_PROFILE_BUTTONS = 0x17,
@@ -61,6 +62,7 @@ struct kovaplus_info {
enum kovaplus_commands {
KOVAPLUS_COMMAND_ACTUAL_PROFILE = 0x5,
+ KOVAPLUS_COMMAND_CONTROL = 0x4,
KOVAPLUS_COMMAND_PROFILE_SETTINGS = 0x6,
KOVAPLUS_COMMAND_PROFILE_BUTTONS = 0x7,
KOVAPLUS_COMMAND_INFO = 0x9,