aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/ABI/testing/sysfs-driver-hid-roccat-pyra98
-rw-r--r--drivers/hid/Kconfig7
-rw-r--r--drivers/hid/Makefile1
-rw-r--r--drivers/hid/hid-core.c1
-rw-r--r--drivers/hid/hid-ids.h2
-rw-r--r--drivers/hid/hid-roccat-pyra.c964
-rw-r--r--drivers/hid/hid-roccat-pyra.h186
7 files changed, 1259 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-driver-hid-roccat-pyra b/Documentation/ABI/testing/sysfs-driver-hid-roccat-pyra
new file mode 100644
index 000000000000..ad1125b02ff4
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-driver-hid-roccat-pyra
@@ -0,0 +1,98 @@
1What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/actual_cpi
2Date: August 2010
3Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
4Description: It is possible to switch the cpi setting of the mouse with the
5 press of a button.
6 When read, this file returns the raw number of the actual cpi
7 setting reported by the mouse. This number has to be further
8 processed to receive the real dpi value.
9
10 VALUE DPI
11 1 400
12 2 800
13 4 1600
14
15 This file is readonly.
16
17What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/actual_profile
18Date: August 2010
19Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
20Description: When read, this file returns the number of the actual profile in
21 range 0-4.
22 This file is readonly.
23
24What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/firmware_version
25Date: August 2010
26Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
27Description: When read, this file returns the raw integer version number of the
28 firmware reported by the mouse. Using the integer value eases
29 further usage in other programs. To receive the real version
30 number the decimal point has to be shifted 2 positions to the
31 left. E.g. a returned value of 138 means 1.38
32 This file is readonly.
33
34What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/profile_settings
35Date: August 2010
36Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
37Description: The mouse can store 5 profiles which can be switched by the
38 press of a button. A profile is split in settings and buttons.
39 profile_settings holds informations like resolution, sensitivity
40 and light effects.
41 When written, this file lets one write the respective profile
42 settings back to the mouse. The data has to be 13 bytes long.
43 The mouse will reject invalid data.
44 Which profile to write is determined by the profile number
45 contained in the data.
46 This file is writeonly.
47
48What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/profile[1-5]_settings
49Date: August 2010
50Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
51Description: The mouse can store 5 profiles which can be switched by the
52 press of a button. A profile is split in settings and buttons.
53 profile_settings holds informations like resolution, sensitivity
54 and light effects.
55 When read, these files return the respective profile settings.
56 The returned data is 13 bytes in size.
57 This file is readonly.
58
59What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/profile_buttons
60Date: August 2010
61Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
62Description: The mouse can store 5 profiles which can be switched by the
63 press of a button. A profile is split in settings and buttons.
64 profile_buttons holds informations about button layout.
65 When written, this file lets one write the respective profile
66 buttons back to the mouse. The data has to be 19 bytes long.
67 The mouse will reject invalid data.
68 Which profile to write is determined by the profile number
69 contained in the data.
70 This file is writeonly.
71
72What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/profile[1-5]_buttons
73Date: August 2010
74Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
75Description: The mouse can store 5 profiles which can be switched by the
76 press of a button. A profile is split in settings and buttons.
77 profile_buttons holds informations about button layout.
78 When read, these files return the respective profile buttons.
79 The returned data is 19 bytes in size.
80 This file is readonly.
81
82What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/startup_profile
83Date: August 2010
84Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
85Description: The integer value of this attribute ranges from 0-4.
86 When read, this attribute returns the number of the profile
87 that's active when the mouse is powered on.
88 This file is readonly.
89
90What: /sys/bus/usb/devices/<busnum>-<devnum>:<config num>.<interface num>/settings
91Date: August 2010
92Contact: Stefan Achatz <erazor_de@users.sourceforge.net>
93Description: When read, this file returns the settings stored in the mouse.
94 The size of the data is 3 bytes and holds information on the
95 startup_profile.
96 When written, this file lets write settings back to the mouse.
97 The data has to be 3 bytes long. The mouse will reject invalid
98 data.
diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
index 6369ba7f96f8..b07440a172b5 100644
--- a/drivers/hid/Kconfig
+++ b/drivers/hid/Kconfig
@@ -376,6 +376,13 @@ config HID_ROCCAT_KONE
376 ---help--- 376 ---help---
377 Support for Roccat Kone mouse. 377 Support for Roccat Kone mouse.
378 378
379config HID_ROCCAT_PYRA
380 tristate "Roccat Pyra mouse support"
381 depends on USB_HID
382 select HID_ROCCAT
383 ---help---
384 Support for Roccat Pyra mouse.
385
379config HID_SAMSUNG 386config HID_SAMSUNG
380 tristate "Samsung" 387 tristate "Samsung"
381 depends on USB_HID 388 depends on USB_HID
diff --git a/drivers/hid/Makefile b/drivers/hid/Makefile
index 46f037f3df80..d224fa342187 100644
--- a/drivers/hid/Makefile
+++ b/drivers/hid/Makefile
@@ -52,6 +52,7 @@ obj-$(CONFIG_HID_PETALYNX) += hid-petalynx.o
52obj-$(CONFIG_HID_PICOLCD) += hid-picolcd.o 52obj-$(CONFIG_HID_PICOLCD) += hid-picolcd.o
53obj-$(CONFIG_HID_ROCCAT) += hid-roccat.o 53obj-$(CONFIG_HID_ROCCAT) += hid-roccat.o
54obj-$(CONFIG_HID_ROCCAT_KONE) += hid-roccat-kone.o 54obj-$(CONFIG_HID_ROCCAT_KONE) += hid-roccat-kone.o
55obj-$(CONFIG_HID_ROCCAT_PYRA) += hid-roccat-pyra.o
55obj-$(CONFIG_HID_SAMSUNG) += hid-samsung.o 56obj-$(CONFIG_HID_SAMSUNG) += hid-samsung.o
56obj-$(CONFIG_HID_SMARTJOYPLUS) += hid-sjoy.o 57obj-$(CONFIG_HID_SMARTJOYPLUS) += hid-sjoy.o
57obj-$(CONFIG_HID_SONY) += hid-sony.o 58obj-$(CONFIG_HID_SONY) += hid-sony.o
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
index 0c52899be964..18608b89e76b 100644
--- a/drivers/hid/hid-core.c
+++ b/drivers/hid/hid-core.c
@@ -1367,6 +1367,7 @@ static const struct hid_device_id hid_blacklist[] = {
1367 { HID_USB_DEVICE(USB_VENDOR_ID_QUANTA, USB_DEVICE_ID_QUANTA_OPTICAL_TOUCH) }, 1367 { HID_USB_DEVICE(USB_VENDOR_ID_QUANTA, USB_DEVICE_ID_QUANTA_OPTICAL_TOUCH) },
1368 { HID_USB_DEVICE(USB_VENDOR_ID_QUANTA, USB_DEVICE_ID_PIXART_IMAGING_INC_OPTICAL_TOUCH_SCREEN) }, 1368 { HID_USB_DEVICE(USB_VENDOR_ID_QUANTA, USB_DEVICE_ID_PIXART_IMAGING_INC_OPTICAL_TOUCH_SCREEN) },
1369 { HID_USB_DEVICE(USB_VENDOR_ID_ROCCAT, USB_DEVICE_ID_ROCCAT_KONE) }, 1369 { HID_USB_DEVICE(USB_VENDOR_ID_ROCCAT, USB_DEVICE_ID_ROCCAT_KONE) },
1370 { HID_USB_DEVICE(USB_VENDOR_ID_ROCCAT, USB_DEVICE_ID_ROCCAT_PYRA_WIRED) },
1370 { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_IR_REMOTE) }, 1371 { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_IR_REMOTE) },
1371 { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_WIRELESS_KBD_MOUSE) }, 1372 { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_WIRELESS_KBD_MOUSE) },
1372 { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) }, 1373 { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) },
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index 85c6d13c9ffa..5787b1a1339f 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -459,6 +459,8 @@
459 459
460#define USB_VENDOR_ID_ROCCAT 0x1e7d 460#define USB_VENDOR_ID_ROCCAT 0x1e7d
461#define USB_DEVICE_ID_ROCCAT_KONE 0x2ced 461#define USB_DEVICE_ID_ROCCAT_KONE 0x2ced
462#define USB_DEVICE_ID_ROCCAT_PYRA_WIRED 0x2c24
463#define USB_DEVICE_ID_ROCCAT_PYRA_WIRELESS 0x2cf6
462 464
463#define USB_VENDOR_ID_SAITEK 0x06a3 465#define USB_VENDOR_ID_SAITEK 0x06a3
464#define USB_DEVICE_ID_SAITEK_RUMBLEPAD 0xff17 466#define USB_DEVICE_ID_SAITEK_RUMBLEPAD 0xff17
diff --git a/drivers/hid/hid-roccat-pyra.c b/drivers/hid/hid-roccat-pyra.c
new file mode 100644
index 000000000000..6c09c15d93ed
--- /dev/null
+++ b/drivers/hid/hid-roccat-pyra.c
@@ -0,0 +1,964 @@
1/*
2 * Roccat Pyra driver for Linux
3 *
4 * Copyright (c) 2010 Stefan Achatz <erazor_de@users.sourceforge.net>
5 */
6
7/*
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU General Public License as published by the Free
10 * Software Foundation; either version 2 of the License, or (at your option)
11 * any later version.
12 */
13
14/*
15 * Roccat Pyra is a mob