Lines Matching +full:0 +full:xff100000

53 	u8 middlebutton_state; /* 0:Up, 1:Down (undecided), 2:Scrolling */
61 #define TP10UBKBD_FN_LOCK_LED 0x54
62 #define TP10UBKBD_MUTE_LED 0x64
63 #define TP10UBKBD_MICMUTE_LED 0x74
76 data->led_report[0] = TP10UBKBD_LED_OUTPUT_REPORT; in lenovo_led_set_tp10ubkbd()
79 ret = hid_hw_raw_request(hdev, data->led_report[0], data->led_report, 3, in lenovo_led_set_tp10ubkbd()
85 ret = ret < 0 ? ret : -EIO; in lenovo_led_set_tp10ubkbd()
87 ret = 0; in lenovo_led_set_tp10ubkbd()
105 0x05, 0x88, /* Usage Page (Vendor Usage Page 0x88) */
106 0x09, 0x01, /* Usage (Vendor Usage 0x01) */
107 0xa1, 0x01, /* Collection (Application) */
108 0x85, 0x04, /* Report ID (4) */
109 0x19, 0x00, /* Usage Minimum (0) */
110 0x2a, 0xff, 0xff, /* Usage Maximum (65535) */
120 * 0x8801 from the report ID 4 in lenovo_report_fixup()
124 sizeof(lenovo_pro_dock_need_fixup_collection)) == 0) { in lenovo_report_fixup()
125 rdesc[151] = 0x01; in lenovo_report_fixup()
126 rdesc[152] = 0x00; in lenovo_report_fixup()
137 if (usage->hid == (HID_UP_BUTTON | 0x0010)) { in lenovo_input_mapping_tpkbd()
143 return 0; in lenovo_input_mapping_tpkbd()
154 case 0x00f1: /* Fn-F4: Mic mute */ in lenovo_input_mapping_cptkbd()
157 case 0x00f2: /* Fn-F5: Brightness down */ in lenovo_input_mapping_cptkbd()
160 case 0x00f3: /* Fn-F6: Brightness up */ in lenovo_input_mapping_cptkbd()
163 case 0x00f4: /* Fn-F7: External display (projector) */ in lenovo_input_mapping_cptkbd()
166 case 0x00f5: /* Fn-F8: Wireless */ in lenovo_input_mapping_cptkbd()
169 case 0x00f6: /* Fn-F9: Control panel */ in lenovo_input_mapping_cptkbd()
172 case 0x00f8: /* Fn-F11: View open applications (3 boxes) */ in lenovo_input_mapping_cptkbd()
175 case 0x00f9: /* Fn-F12: Open My computer (6 boxes) USB-only */ in lenovo_input_mapping_cptkbd()
179 case 0x00fa: /* Fn-Esc: Fn-lock toggle */ in lenovo_input_mapping_cptkbd()
182 case 0x00fb: /* Middle mouse button (in native mode) */ in lenovo_input_mapping_cptkbd()
192 (usage->hid & HID_USAGE) == 0x003) in lenovo_input_mapping_cptkbd()
195 (usage->hid & HID_USAGE) == 0x238) in lenovo_input_mapping_cptkbd()
198 /* Map wheel emulation reports: 0xffa1 = USB, 0xff10 = BT */ in lenovo_input_mapping_cptkbd()
199 if ((usage->hid & HID_USAGE_PAGE) == 0xff100000 || in lenovo_input_mapping_cptkbd()
200 (usage->hid & HID_USAGE_PAGE) == 0xffa10000) { in lenovo_input_mapping_cptkbd()
206 case 0x0000: in lenovo_input_mapping_cptkbd()
209 case 0x0001: in lenovo_input_mapping_cptkbd()
217 return 0; in lenovo_input_mapping_cptkbd()
228 return 0; in lenovo_input_mapping_scrollpoint()
236 * The ThinkPad 10 Ultrabook Keyboard uses 0x000c0001 usage for in lenovo_input_mapping_tp10_ultrabook_kbd()
239 if (usage->hid == 0x000c0001) { in lenovo_input_mapping_tp10_ultrabook_kbd()
263 if (usage->hid == 0x00070072) in lenovo_input_mapping_tp10_ultrabook_kbd()
266 return 0; in lenovo_input_mapping_tp10_ultrabook_kbd()
293 return 0; in lenovo_input_mapping()
310 buf[0] = 0x18; in lenovo_send_cmd_cptkbd()
316 ret = hid_hw_raw_request(hdev, 0x13, buf, 3, in lenovo_send_cmd_cptkbd()
329 return ret < 0 ? ret : 0; /* BT returns 0, USB returns sizeof(buf) */ in lenovo_send_cmd_cptkbd()
337 ret = lenovo_send_cmd_cptkbd(hdev, 0x05, cptkbd_data->fn_lock); in lenovo_features_set_cptkbd()
341 ret = lenovo_send_cmd_cptkbd(hdev, 0x02, cptkbd_data->sensitivity); in lenovo_features_set_cptkbd()
367 if (value < 0 || value > 1) in attr_fn_lock_store()
448 && data[0] == 0x15 in lenovo_raw_event()
449 && data[1] == 0x94 in lenovo_raw_event()
450 && data[2] == 0x01)) { in lenovo_raw_event()
451 data[1] = 0x00; in lenovo_raw_event()
452 data[2] = 0x01; in lenovo_raw_event()
455 return 0; in lenovo_raw_event()
473 return 0; in lenovo_event_tp10ubkbd()
486 return 0; in lenovo_event_cptkbd()
493 } else if (value == 0) { in lenovo_event_cptkbd()
500 EV_KEY, BTN_MIDDLE, 0); in lenovo_event_cptkbd()
503 cptkbd_data->middlebutton_state = 0; in lenovo_event_cptkbd()
508 return 0; in lenovo_event_cptkbd()
515 return 0; in lenovo_event()
524 return 0; in lenovo_event()
535 report->field[0]->value[0] = data_pointer->press_to_select ? 0x01 : 0x02; in lenovo_features_set_tpkbd()
536 report->field[0]->value[0] |= data_pointer->dragging ? 0x04 : 0x08; in lenovo_features_set_tpkbd()
537 report->field[0]->value[0] |= data_pointer->release_to_select ? 0x10 : 0x20; in lenovo_features_set_tpkbd()
538 report->field[0]->value[0] |= data_pointer->select_right ? 0x80 : 0x40; in lenovo_features_set_tpkbd()
539 report->field[1]->value[0] = 0x03; // unknown setting, imitate windows driver in lenovo_features_set_tpkbd()
540 report->field[2]->value[0] = data_pointer->sensitivity; in lenovo_features_set_tpkbd()
541 report->field[3]->value[0] = data_pointer->press_speed; in lenovo_features_set_tpkbd()
544 return 0; in lenovo_features_set_tpkbd()
568 if (value < 0 || value > 1) in attr_press_to_select_store_tpkbd()
598 if (value < 0 || value > 1) in attr_dragging_store_tpkbd()
628 if (value < 0 || value > 1) in attr_release_to_select_store_tpkbd()
658 if (value < 0 || value > 1) in attr_select_right_store_tpkbd()
775 report->field[0]->value[0] = (data_pointer->led_state >> 0) & 1; in lenovo_led_set_tpkbd()
776 report->field[0]->value[1] = (data_pointer->led_state >> 1) & 1; in lenovo_led_set_tpkbd()
786 int led_nr = 0; in lenovo_led_brightness_get()
803 int led_nr = 0; in lenovo_led_brightness_set()
804 int ret = 0; in lenovo_led_brightness_set()
848 if (ret < 0) in lenovo_register_leds()
857 if (ret < 0) { in lenovo_register_leds()
862 return 0; in lenovo_register_leds()
875 return 0; in lenovo_probe_tpkbd()
880 for (i = 0; i < 4; i++) { in lenovo_probe_tpkbd()
884 if (!hid_validate_values(hdev, HID_OUTPUT_REPORT, 3, 0, 2)) in lenovo_probe_tpkbd()
901 data_pointer->sensitivity = 0xa0; in lenovo_probe_tpkbd()
902 data_pointer->press_speed = 0x38; in lenovo_probe_tpkbd()
912 return 0; in lenovo_probe_tpkbd()
927 return 0; in lenovo_probe_cptkbd()
943 ret = lenovo_send_cmd_cptkbd(hdev, 0x01, 0x03); in lenovo_probe_cptkbd()
948 ret = lenovo_send_cmd_cptkbd(hdev, 0x09, 0x01); in lenovo_probe_cptkbd()
953 cptkbd_data->middlebutton_state = 0; in lenovo_probe_cptkbd()
955 cptkbd_data->sensitivity = 0x05; in lenovo_probe_cptkbd()
962 return 0; in lenovo_probe_cptkbd()
981 return 0; in lenovo_probe_tp10ubkbd()
1010 return 0; in lenovo_probe_tp10ubkbd()
1045 ret = 0; in lenovo_probe()
1051 return 0; in lenovo_probe()
1130 return 0; in lenovo_input_configured()