Lines Matching refs:input
117 struct input_dev __rcu *input; member
406 struct input_dev *input; in steam_register() local
410 input = rcu_dereference(steam->input); in steam_register()
412 if (input) { in steam_register()
428 input = input_allocate_device(); in steam_register()
429 if (!input) in steam_register()
432 input_set_drvdata(input, steam); in steam_register()
433 input->dev.parent = &hdev->dev; in steam_register()
434 input->open = steam_input_open; in steam_register()
435 input->close = steam_input_close; in steam_register()
437 input->name = (steam->quirks & STEAM_QUIRK_WIRELESS) ? in steam_register()
440 input->phys = hdev->phys; in steam_register()
441 input->uniq = steam->serial_no; in steam_register()
442 input->id.bustype = hdev->bus; in steam_register()
443 input->id.vendor = hdev->vendor; in steam_register()
444 input->id.product = hdev->product; in steam_register()
445 input->id.version = hdev->version; in steam_register()
447 input_set_capability(input, EV_KEY, BTN_TR2); in steam_register()
448 input_set_capability(input, EV_KEY, BTN_TL2); in steam_register()
449 input_set_capability(input, EV_KEY, BTN_TR); in steam_register()
450 input_set_capability(input, EV_KEY, BTN_TL); in steam_register()
451 input_set_capability(input, EV_KEY, BTN_Y); in steam_register()
452 input_set_capability(input, EV_KEY, BTN_B); in steam_register()
453 input_set_capability(input, EV_KEY, BTN_X); in steam_register()
454 input_set_capability(input, EV_KEY, BTN_A); in steam_register()
455 input_set_capability(input, EV_KEY, BTN_DPAD_UP); in steam_register()
456 input_set_capability(input, EV_KEY, BTN_DPAD_RIGHT); in steam_register()
457 input_set_capability(input, EV_KEY, BTN_DPAD_LEFT); in steam_register()
458 input_set_capability(input, EV_KEY, BTN_DPAD_DOWN); in steam_register()
459 input_set_capability(input, EV_KEY, BTN_SELECT); in steam_register()
460 input_set_capability(input, EV_KEY, BTN_MODE); in steam_register()
461 input_set_capability(input, EV_KEY, BTN_START); in steam_register()
462 input_set_capability(input, EV_KEY, BTN_GEAR_DOWN); in steam_register()
463 input_set_capability(input, EV_KEY, BTN_GEAR_UP); in steam_register()
464 input_set_capability(input, EV_KEY, BTN_THUMBR); in steam_register()
465 input_set_capability(input, EV_KEY, BTN_THUMBL); in steam_register()
466 input_set_capability(input, EV_KEY, BTN_THUMB); in steam_register()
467 input_set_capability(input, EV_KEY, BTN_THUMB2); in steam_register()
469 input_set_abs_params(input, ABS_HAT2Y, 0, 255, 0, 0); in steam_register()
470 input_set_abs_params(input, ABS_HAT2X, 0, 255, 0, 0); in steam_register()
471 input_set_abs_params(input, ABS_X, -32767, 32767, 0, 0); in steam_register()
472 input_set_abs_params(input, ABS_Y, -32767, 32767, 0, 0); in steam_register()
473 input_set_abs_params(input, ABS_RX, -32767, 32767, in steam_register()
475 input_set_abs_params(input, ABS_RY, -32767, 32767, in steam_register()
477 input_set_abs_params(input, ABS_HAT0X, -32767, 32767, in steam_register()
479 input_set_abs_params(input, ABS_HAT0Y, -32767, 32767, in steam_register()
481 input_abs_set_res(input, ABS_X, STEAM_JOYSTICK_RESOLUTION); in steam_register()
482 input_abs_set_res(input, ABS_Y, STEAM_JOYSTICK_RESOLUTION); in steam_register()
483 input_abs_set_res(input, ABS_RX, STEAM_PAD_RESOLUTION); in steam_register()
484 input_abs_set_res(input, ABS_RY, STEAM_PAD_RESOLUTION); in steam_register()
485 input_abs_set_res(input, ABS_HAT0X, STEAM_PAD_RESOLUTION); in steam_register()
486 input_abs_set_res(input, ABS_HAT0Y, STEAM_PAD_RESOLUTION); in steam_register()
487 input_abs_set_res(input, ABS_HAT2Y, STEAM_TRIGGER_RESOLUTION); in steam_register()
488 input_abs_set_res(input, ABS_HAT2X, STEAM_TRIGGER_RESOLUTION); in steam_register()
490 ret = input_register_device(input); in steam_register()
494 rcu_assign_pointer(steam->input, input); in steam_register()
503 input_free_device(input); in steam_register()
509 struct input_dev *input; in steam_unregister() local
513 input = rcu_dereference(steam->input); in steam_unregister()
522 if (input) { in steam_unregister()
523 RCU_INIT_POINTER(steam->input, NULL); in steam_unregister()
527 input_unregister_device(input); in steam_unregister()
884 struct input_dev *input, u8 *data) in steam_do_input_event() argument
895 input_report_abs(input, ABS_HAT2Y, data[11]); in steam_do_input_event()
896 input_report_abs(input, ABS_HAT2X, data[12]); in steam_do_input_event()
911 input_report_abs(input, lpad_touched ? ABS_HAT0X : ABS_X, x); in steam_do_input_event()
912 input_report_abs(input, lpad_touched ? ABS_HAT0Y : ABS_Y, y); in steam_do_input_event()
915 input_report_abs(input, ABS_X, 0); in steam_do_input_event()
916 input_report_abs(input, ABS_Y, 0); in steam_do_input_event()
920 input_report_abs(input, ABS_HAT0X, 0); in steam_do_input_event()
921 input_report_abs(input, ABS_HAT0Y, 0); in steam_do_input_event()
924 input_report_abs(input, ABS_RX, steam_le16(data + 20)); in steam_do_input_event()
925 input_report_abs(input, ABS_RY, -steam_le16(data + 22)); in steam_do_input_event()
927 input_event(input, EV_KEY, BTN_TR2, !!(b8 & BIT(0))); in steam_do_input_event()
928 input_event(input, EV_KEY, BTN_TL2, !!(b8 & BIT(1))); in steam_do_input_event()
929 input_event(input, EV_KEY, BTN_TR, !!(b8 & BIT(2))); in steam_do_input_event()
930 input_event(input, EV_KEY, BTN_TL, !!(b8 & BIT(3))); in steam_do_input_event()
931 input_event(input, EV_KEY, BTN_Y, !!(b8 & BIT(4))); in steam_do_input_event()
932 input_event(input, EV_KEY, BTN_B, !!(b8 & BIT(5))); in steam_do_input_event()
933 input_event(input, EV_KEY, BTN_X, !!(b8 & BIT(6))); in steam_do_input_event()
934 input_event(input, EV_KEY, BTN_A, !!(b8 & BIT(7))); in steam_do_input_event()
935 input_event(input, EV_KEY, BTN_SELECT, !!(b9 & BIT(4))); in steam_do_input_event()
936 input_event(input, EV_KEY, BTN_MODE, !!(b9 & BIT(5))); in steam_do_input_event()
937 input_event(input, EV_KEY, BTN_START, !!(b9 & BIT(6))); in steam_do_input_event()
938 input_event(input, EV_KEY, BTN_GEAR_DOWN, !!(b9 & BIT(7))); in steam_do_input_event()
939 input_event(input, EV_KEY, BTN_GEAR_UP, !!(b10 & BIT(0))); in steam_do_input_event()
940 input_event(input, EV_KEY, BTN_THUMBR, !!(b10 & BIT(2))); in steam_do_input_event()
941 input_event(input, EV_KEY, BTN_THUMBL, !!(b10 & BIT(6))); in steam_do_input_event()
942 input_event(input, EV_KEY, BTN_THUMB, lpad_touched || lpad_and_joy); in steam_do_input_event()
943 input_event(input, EV_KEY, BTN_THUMB2, !!(b10 & BIT(4))); in steam_do_input_event()
944 input_event(input, EV_KEY, BTN_DPAD_UP, !!(b9 & BIT(0))); in steam_do_input_event()
945 input_event(input, EV_KEY, BTN_DPAD_RIGHT, !!(b9 & BIT(1))); in steam_do_input_event()
946 input_event(input, EV_KEY, BTN_DPAD_LEFT, !!(b9 & BIT(2))); in steam_do_input_event()
947 input_event(input, EV_KEY, BTN_DPAD_DOWN, !!(b9 & BIT(3))); in steam_do_input_event()
949 input_sync(input); in steam_do_input_event()
988 struct input_dev *input; in steam_raw_event() local
1021 input = rcu_dereference(steam->input); in steam_raw_event()
1022 if (likely(input)) { in steam_raw_event()
1023 steam_do_input_event(steam, input, data); in steam_raw_event()