Skip to content

Commit

Permalink
Merge branches 'for-3.9/logitech', 'for-3.9/multitouch', 'for-3.9/ntr…
Browse files Browse the repository at this point in the history
…ig', 'for-3.9/thingm' and 'for-3.9/upstream' into for-linus
  • Loading branch information
Jiri Kosina committed Feb 21, 2013
5 parents 539cf54 + 483f86a + 7e3cc44 + 1b474fe + 30ba2fb commit 7375951
Show file tree
Hide file tree
Showing 66 changed files with 759 additions and 805 deletions.
23 changes: 23 additions & 0 deletions Documentation/ABI/testing/sysfs-driver-hid-thingm
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
What: /sys/class/leds/blink1::<serial>/rgb
Date: January 2013
Contact: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Description: The ThingM blink1 is an USB RGB LED. The color notation is
3-byte hexadecimal. Read this attribute to get the last set
color. Write the 24-bit hexadecimal color to change the current
LED color. The default color is full white (0xFFFFFF).
For instance, set the color to green with: echo 00FF00 > rgb

What: /sys/class/leds/blink1::<serial>/fade
Date: January 2013
Contact: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Description: This attribute allows to set a fade time in milliseconds for
the next color change. Read the attribute to know the current
fade time. The default value is set to 0 (no fade time). For
instance, set a fade time of 2 seconds with: echo 2000 > fade

What: /sys/class/leds/blink1::<serial>/play
Date: January 2013
Contact: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Description: This attribute is used to play/pause the light patterns. Write 1
to start playing, 0 to stop. Reading this attribute returns the
current playing status.
5 changes: 5 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -7585,6 +7585,11 @@ S: Supported
F: drivers/thermal/
F: include/linux/thermal.h

THINGM BLINK(1) USB RGB LED DRIVER
M: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
S: Maintained
F: drivers/hid/hid-thingm.c

THINKPAD ACPI EXTRAS DRIVER
M: Henrique de Moraes Holschuh <ibm-acpi@hmh.eng.br>
L: ibm-acpi-devel@lists.sourceforge.net
Expand Down
12 changes: 11 additions & 1 deletion drivers/hid/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -655,6 +655,16 @@ config HID_TOPSEED
Say Y if you have a TopSeed Cyberlink or BTC Emprex or Conceptronic
CLLRCMCE remote control.

config HID_THINGM
tristate "ThingM blink(1) USB RGB LED"
depends on USB_HID
depends on LEDS_CLASS
---help---
Support for the ThingM blink(1) USB RGB LED. This driver registers a
Linux LED class instance, plus additional sysfs attributes to control
RGB colors, fade time and playing. The device is exposed through hidraw
to access other functions.

config HID_THRUSTMASTER
tristate "ThrustMaster devices support"
depends on USB_HID
Expand Down Expand Up @@ -719,7 +729,7 @@ config HID_ZYDACRON

config HID_SENSOR_HUB
tristate "HID Sensors framework support"
depends on USB_HID
depends on USB_HID && GENERIC_HARDIRQS
select MFD_CORE
default n
-- help---
Expand Down
1 change: 1 addition & 0 deletions drivers/hid/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ obj-$(CONFIG_HID_SONY) += hid-sony.o
obj-$(CONFIG_HID_SPEEDLINK) += hid-speedlink.o
obj-$(CONFIG_HID_SUNPLUS) += hid-sunplus.o
obj-$(CONFIG_HID_GREENASIA) += hid-gaff.o
obj-$(CONFIG_HID_THINGM) += hid-thingm.o
obj-$(CONFIG_HID_THRUSTMASTER) += hid-tmff.o
obj-$(CONFIG_HID_TIVO) += hid-tivo.o
obj-$(CONFIG_HID_TOPSEED) += hid-topseed.o
Expand Down
13 changes: 1 addition & 12 deletions drivers/hid/hid-a4tech.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,17 +146,6 @@ static struct hid_driver a4_driver = {
.probe = a4_probe,
.remove = a4_remove,
};
module_hid_driver(a4_driver);

static int __init a4_init(void)
{
return hid_register_driver(&a4_driver);
}

static void __exit a4_exit(void)
{
hid_unregister_driver(&a4_driver);
}

module_init(a4_init);
module_exit(a4_exit);
MODULE_LICENSE("GPL");
19 changes: 1 addition & 18 deletions drivers/hid/hid-apple.c
Original file line number Diff line number Diff line change
Expand Up @@ -555,23 +555,6 @@ static struct hid_driver apple_driver = {
.input_mapping = apple_input_mapping,
.input_mapped = apple_input_mapped,
};
module_hid_driver(apple_driver);

static int __init apple_init(void)
{
int ret;

ret = hid_register_driver(&apple_driver);
if (ret)
pr_err("can't register apple driver\n");

return ret;
}

static void __exit apple_exit(void)
{
hid_unregister_driver(&apple_driver);
}

module_init(apple_init);
module_exit(apple_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-aureal.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,17 +37,6 @@ static struct hid_driver aureal_driver = {
.id_table = aureal_devices,
.report_fixup = aureal_report_fixup,
};
module_hid_driver(aureal_driver);

static int __init aureal_init(void)
{
return hid_register_driver(&aureal_driver);
}

static void __exit aureal_exit(void)
{
hid_unregister_driver(&aureal_driver);
}

module_init(aureal_init);
module_exit(aureal_exit);
MODULE_LICENSE("GPL");
14 changes: 1 addition & 13 deletions drivers/hid/hid-axff.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,19 +192,7 @@ static struct hid_driver ax_driver = {
.probe = ax_probe,
.remove = ax_remove,
};

static int __init ax_init(void)
{
return hid_register_driver(&ax_driver);
}

static void __exit ax_exit(void)
{
hid_unregister_driver(&ax_driver);
}

module_init(ax_init);
module_exit(ax_exit);
module_hid_driver(ax_driver);

MODULE_AUTHOR("Sergei Kolzun");
MODULE_DESCRIPTION("Force feedback support for ACRUX game controllers");
Expand Down
13 changes: 1 addition & 12 deletions drivers/hid/hid-belkin.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,17 +86,6 @@ static struct hid_driver belkin_driver = {
.input_mapping = belkin_input_mapping,
.probe = belkin_probe,
};
module_hid_driver(belkin_driver);

static int __init belkin_init(void)
{
return hid_register_driver(&belkin_driver);
}

static void __exit belkin_exit(void)
{
hid_unregister_driver(&belkin_driver);
}

module_init(belkin_init);
module_exit(belkin_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-cherry.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,17 +69,6 @@ static struct hid_driver ch_driver = {
.report_fixup = ch_report_fixup,
.input_mapping = ch_input_mapping,
};
module_hid_driver(ch_driver);

static int __init ch_init(void)
{
return hid_register_driver(&ch_driver);
}

static void __exit ch_exit(void)
{
hid_unregister_driver(&ch_driver);
}

module_init(ch_init);
module_exit(ch_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-chicony.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,17 +70,6 @@ static struct hid_driver ch_driver = {
.id_table = ch_devices,
.input_mapping = ch_input_mapping,
};
module_hid_driver(ch_driver);

static int __init ch_init(void)
{
return hid_register_driver(&ch_driver);
}

static void __exit ch_exit(void)
{
hid_unregister_driver(&ch_driver);
}

module_init(ch_init);
module_exit(ch_exit);
MODULE_LICENSE("GPL");
14 changes: 14 additions & 0 deletions drivers/hid/hid-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1195,6 +1195,7 @@ int hid_report_raw_event(struct hid_device *hid, int type, u8 *data, int size,
{
struct hid_report_enum *report_enum = hid->report_enum + type;
struct hid_report *report;
struct hid_driver *hdrv;
unsigned int a;
int rsize, csize = size;
u8 *cdata = data;
Expand Down Expand Up @@ -1231,6 +1232,9 @@ int hid_report_raw_event(struct hid_device *hid, int type, u8 *data, int size,
if (hid->claimed != HID_CLAIMED_HIDRAW) {
for (a = 0; a < report->maxfield; a++)
hid_input_field(hid, report->field[a], cdata, interrupt);
hdrv = hid->driver;
if (hdrv && hdrv->report)
hdrv->report(hid, report);
}

if (hid->claimed & HID_CLAIMED_INPUT)
Expand Down Expand Up @@ -1599,6 +1603,7 @@ static const struct hid_device_id hid_have_special_driver[] = {
{ HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE_3) },
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK, USB_DEVICE_ID_HOLTEK_ON_LINE_GRIP) },
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD) },
{ HID_USB_DEVICE(USB_VENDOR_ID_JESS2, USB_DEVICE_ID_JESS2_COLOR_RUMBLE_PAD) },
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_ION, USB_DEVICE_ID_ICADE) },
{ HID_USB_DEVICE(USB_VENDOR_ID_KENSINGTON, USB_DEVICE_ID_KS_SLIMBLADE) },
{ HID_USB_DEVICE(USB_VENDOR_ID_KEYTOUCH, USB_DEVICE_ID_KEYTOUCH_IEC) },
Expand Down Expand Up @@ -1698,6 +1703,7 @@ static const struct hid_device_id hid_have_special_driver[] = {
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) },
{ HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE) },
{ HID_USB_DEVICE(USB_VENDOR_ID_SUNPLUS, USB_DEVICE_ID_SUNPLUS_WDESKTOP) },
{ HID_USB_DEVICE(USB_VENDOR_ID_THINGM, USB_DEVICE_ID_BLINK1) },
{ HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb300) },
{ HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb304) },
{ HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb323) },
Expand Down Expand Up @@ -2228,6 +2234,14 @@ bool hid_ignore(struct hid_device *hdev)
hdev->type != HID_TYPE_USBMOUSE)
return true;
break;
case USB_VENDOR_ID_VELLEMAN:
/* These are not HID devices. They are handled by comedi. */
if ((hdev->product >= USB_DEVICE_ID_VELLEMAN_K8055_FIRST &&
hdev->product <= USB_DEVICE_ID_VELLEMAN_K8055_LAST) ||
(hdev->product >= USB_DEVICE_ID_VELLEMAN_K8061_FIRST &&
hdev->product <= USB_DEVICE_ID_VELLEMAN_K8061_LAST))
return true;
break;
}

if (hdev->type == HID_TYPE_USBMOUSE &&
Expand Down
13 changes: 1 addition & 12 deletions drivers/hid/hid-cypress.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,17 +144,6 @@ static struct hid_driver cp_driver = {
.event = cp_event,
.probe = cp_probe,
};
module_hid_driver(cp_driver);

static int __init cp_init(void)
{
return hid_register_driver(&cp_driver);
}

static void __exit cp_exit(void)
{
hid_unregister_driver(&cp_driver);
}

module_init(cp_init);
module_exit(cp_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-dr.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,17 +297,6 @@ static struct hid_driver dr_driver = {
.report_fixup = dr_report_fixup,
.probe = dr_probe,
};
module_hid_driver(dr_driver);

static int __init dr_init(void)
{
return hid_register_driver(&dr_driver);
}

static void __exit dr_exit(void)
{
hid_unregister_driver(&dr_driver);
}

module_init(dr_init);
module_exit(dr_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-elecom.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,6 @@ static struct hid_driver elecom_driver = {
.id_table = elecom_devices,
.report_fixup = elecom_report_fixup
};
module_hid_driver(elecom_driver);

static int __init elecom_init(void)
{
return hid_register_driver(&elecom_driver);
}

static void __exit elecom_exit(void)
{
hid_unregister_driver(&elecom_driver);
}

module_init(elecom_init);
module_exit(elecom_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-emsff.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,18 +150,7 @@ static struct hid_driver ems_driver = {
.id_table = ems_devices,
.probe = ems_probe,
};
module_hid_driver(ems_driver);

static int ems_init(void)
{
return hid_register_driver(&ems_driver);
}

static void ems_exit(void)
{
hid_unregister_driver(&ems_driver);
}

module_init(ems_init);
module_exit(ems_exit);
MODULE_LICENSE("GPL");

13 changes: 1 addition & 12 deletions drivers/hid/hid-ezkey.c
Original file line number Diff line number Diff line change
Expand Up @@ -76,17 +76,6 @@ static struct hid_driver ez_driver = {
.input_mapping = ez_input_mapping,
.event = ez_event,
};
module_hid_driver(ez_driver);

static int __init ez_init(void)
{
return hid_register_driver(&ez_driver);
}

static void __exit ez_exit(void)
{
hid_unregister_driver(&ez_driver);
}

module_init(ez_init);
module_exit(ez_exit);
MODULE_LICENSE("GPL");
13 changes: 1 addition & 12 deletions drivers/hid/hid-gaff.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,17 +176,6 @@ static struct hid_driver ga_driver = {
.id_table = ga_devices,
.probe = ga_probe,
};
module_hid_driver(ga_driver);

static int __init ga_init(void)
{
return hid_register_driver(&ga_driver);
}

static void __exit ga_exit(void)
{
hid_unregister_driver(&ga_driver);
}

module_init(ga_init);
module_exit(ga_exit);
MODULE_LICENSE("GPL");
14 changes: 1 addition & 13 deletions drivers/hid/hid-generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,19 +34,7 @@ static struct hid_driver hid_generic = {
.name = "hid-generic",
.id_table = hid_table,
};

static int __init hid_init(void)
{
return hid_register_driver(&hid_generic);
}

static void __exit hid_exit(void)
{
hid_unregister_driver(&hid_generic);
}

module_init(hid_init);
module_exit(hid_exit);
module_hid_driver(hid_generic);

MODULE_AUTHOR("Henrik Rydberg");
MODULE_DESCRIPTION("HID generic driver");
Expand Down
Loading

0 comments on commit 7375951

Please sign in to comment.