Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 180836
b: refs/heads/master
c: cd9ec30
h: refs/heads/master
v: v3
  • Loading branch information
Johnathon Harris authored and Jiri Kosina committed Jan 26, 2010
1 parent b2bb7ee commit dba7b9b
Show file tree
Hide file tree
Showing 6 changed files with 69 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8b0e58a70a7a41443c779de074288035b014cb94
refs/heads/master: cd9ec30da58bcd8ab154eba9eb54d16c67e7ef3b
7 changes: 7 additions & 0 deletions trunk/drivers/hid/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,13 @@ config HID_NTRIG
---help---
Support for N-Trig touch screen.

config HID_ORTEK
tristate "Ortek" if EMBEDDED
depends on USB_HID
default !EMBEDDED
---help---
Support for Ortek WKB-2000 wireless keyboard + mouse trackpad.

config HID_PANTHERLORD
tristate "Pantherlord support" if EMBEDDED
depends on USB_HID
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/hid/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ obj-$(CONFIG_HID_LOGITECH) += hid-logitech.o
obj-$(CONFIG_HID_MICROSOFT) += hid-microsoft.o
obj-$(CONFIG_HID_MONTEREY) += hid-monterey.o
obj-$(CONFIG_HID_NTRIG) += hid-ntrig.o
obj-$(CONFIG_HID_ORTEK) += hid-ortek.o
obj-$(CONFIG_HID_QUANTA) += hid-quanta.o
obj-$(CONFIG_HID_PANTHERLORD) += hid-pl.o
obj-$(CONFIG_HID_PETALYNX) += hid-petalynx.o
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/hid/hid-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1337,6 +1337,7 @@ static const struct hid_device_id hid_blacklist[] = {
{ HID_USB_DEVICE(USB_VENDOR_ID_MICROSOFT, USB_DEVICE_ID_WIRELESS_OPTICAL_DESKTOP_3_0) },
{ HID_USB_DEVICE(USB_VENDOR_ID_MONTEREY, USB_DEVICE_ID_GENIUS_KB29E) },
{ HID_USB_DEVICE(USB_VENDOR_ID_NTRIG, USB_DEVICE_ID_NTRIG_TOUCH_SCREEN) },
{ HID_USB_DEVICE(USB_VENDOR_ID_ORTEK, USB_DEVICE_ID_ORTEK_WKB2000) },
{ HID_USB_DEVICE(USB_VENDOR_ID_PETALYNX, USB_DEVICE_ID_PETALYNX_MAXTER_REMOTE) },
{ HID_USB_DEVICE(USB_VENDOR_ID_QUANTA, USB_DEVICE_ID_QUANTA_OPTICAL_TOUCH) },
{ HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_IR_REMOTE) },
Expand Down
3 changes: 3 additions & 0 deletions trunk/drivers/hid/hid-ids.h
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,9 @@
#define USB_VENDOR_ID_ONTRAK 0x0a07
#define USB_DEVICE_ID_ONTRAK_ADU100 0x0064

#define USB_VENDOR_ID_ORTEK 0x05a4
#define USB_DEVICE_ID_ORTEK_WKB2000 0x2000

#define USB_VENDOR_ID_PANJIT 0x134c

#define USB_VENDOR_ID_PANTHERLORD 0x0810
Expand Down
56 changes: 56 additions & 0 deletions trunk/drivers/hid/hid-ortek.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
/*
* HID driver for Ortek WKB-2000 (wireless keyboard + mouse trackpad).
* Fixes LogicalMaximum error in USB report description, see
* http://bugzilla.kernel.org/show_bug.cgi?id=14787
*
* Copyright (c) 2010 Johnathon Harris <jmharris@gmail.com>
*/

/*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the Free
* Software Foundation; either version 2 of the License, or (at your option)
* any later version.
*/

#include <linux/device.h>
#include <linux/hid.h>
#include <linux/module.h>

#include "hid-ids.h"

static void ortek_report_fixup(struct hid_device *hdev, __u8 *rdesc,
unsigned int rsize)
{
if (rsize >= 56 && rdesc[54] == 0x25 && rdesc[55] == 0x01) {
dev_info(&hdev->dev, "Fixing up Ortek WKB-2000 "
"report descriptor.\n");
rdesc[55] = 0x92;
}
}

static const struct hid_device_id ortek_devices[] = {
{ HID_USB_DEVICE(USB_VENDOR_ID_ORTEK, USB_DEVICE_ID_ORTEK_WKB2000) },
{ }
};
MODULE_DEVICE_TABLE(hid, ortek_devices);

static struct hid_driver ortek_driver = {
.name = "ortek",
.id_table = ortek_devices,
.report_fixup = ortek_report_fixup
};

static int __init ortek_init(void)
{
return hid_register_driver(&ortek_driver);
}

static void __exit ortek_exit(void)
{
hid_unregister_driver(&ortek_driver);
}

module_init(ortek_init);
module_exit(ortek_exit);
MODULE_LICENSE("GPL");

0 comments on commit dba7b9b

Please sign in to comment.