Lines Matching +full:short +full:- +full:descriptor
1 // SPDX-License-Identifier: GPL-2.0-or-later
15 #include "hid-ids.h"
19 unsigned short last_key[4];
24 * Zydacron remote control has an invalid HID report descriptor,
35 "fixing up zydacron remote control report descriptor\n"); in zc_report_fixup()
51 zc->input_ep81 = hi->input; in zc_input_mapping()
53 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_CONSUMER) in zc_input_mapping()
57 usage->hid & HID_USAGE); in zc_input_mapping()
59 switch (usage->hid & HID_USAGE) { in zc_input_mapping()
104 zc->last_key[i] = 0; in zc_input_mapping()
115 unsigned short index; in zc_raw_event()
117 if (report->id == data[0]) { in zc_raw_event()
121 key = zc->last_key[index]; in zc_raw_event()
123 input_event(zc->input_ep81, EV_KEY, key, 0); in zc_raw_event()
124 zc->last_key[index] = 0; in zc_raw_event()
129 switch (report->id) { in zc_raw_event()
152 input_event(zc->input_ep81, EV_KEY, key, 1); in zc_raw_event()
153 zc->last_key[index] = key; in zc_raw_event()
169 zc = devm_kzalloc(&hdev->dev, sizeof(*zc), GFP_KERNEL); in zc_probe()
171 hid_err(hdev, "can't alloc descriptor\n"); in zc_probe()
172 return -ENOMEM; in zc_probe()