14 #include <linux/device.h>
15 #include <linux/hid.h>
16 #include <linux/module.h>
34 rdesc[0x96] == 0xbc && rdesc[0x97] == 0xff &&
35 rdesc[0xca] == 0xbc && rdesc[0xcb] == 0xff &&
36 rdesc[0xe1] == 0xbc && rdesc[0xe2] == 0xff) {
38 "fixing up zydacron remote control report descriptor\n");
39 rdesc[0x96] = rdesc[0xca] = rdesc[0xe1] = 0x0c;
40 rdesc[0x97] = rdesc[0xcb] = rdesc[0xe2] = 0x00;
45 #define zc_map_key_clear(c) \
46 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, (c))
50 unsigned long **
bit,
int *
max)
53 struct zc_device *zc = hid_get_drvdata(hdev);
59 dbg_hid(
"zynacron input mapping event [0x%x]\n",
106 for (i = 0; i < 4; i++)
115 struct zc_device *zc = hid_get_drvdata(hdev);
118 unsigned short index;
120 if (report->
id == data[0]) {
123 for (index = 0; index < 4; index++) {
132 switch (report->
id) {
174 hid_err(hdev,
"can't alloc descriptor\n");
178 hid_set_drvdata(hdev, zc);
180 ret = hid_parse(hdev);
182 hid_err(hdev,
"parse failed\n");
188 hid_err(hdev,
"hw start failed\n");
199 static void zc_remove(
struct hid_device *hdev)
201 struct zc_device *zc = hid_get_drvdata(hdev);
215 .id_table = zc_devices,
216 .report_fixup = zc_report_fixup,
217 .input_mapping = zc_input_mapping,
218 .raw_event = zc_raw_event,
223 static int __init zc_init(
void)
228 static void __exit zc_exit(
void)