/kernel/linux/linux-5.10/drivers/input/serio/ |
D | libps2.c | 25 static int ps2_do_sendbyte(struct ps2dev *ps2dev, u8 byte, in ps2_do_sendbyte() argument 27 __releases(&ps2dev->serio->lock) __acquires(&ps2dev->serio->lock) in ps2_do_sendbyte() 32 lockdep_assert_held(&ps2dev->serio->lock); in ps2_do_sendbyte() 35 ps2dev->nak = 1; in ps2_do_sendbyte() 36 ps2dev->flags |= PS2_FLAG_ACK; in ps2_do_sendbyte() 38 serio_continue_rx(ps2dev->serio); in ps2_do_sendbyte() 40 error = serio_write(ps2dev->serio, byte); in ps2_do_sendbyte() 42 dev_dbg(&ps2dev->serio->dev, in ps2_do_sendbyte() 45 wait_event_timeout(ps2dev->wait, in ps2_do_sendbyte() 46 !(ps2dev->flags & PS2_FLAG_ACK), in ps2_do_sendbyte() [all …]
|
/kernel/linux/linux-5.10/include/linux/ |
D | libps2.h | 33 struct ps2dev { struct 48 void ps2_init(struct ps2dev *ps2dev, struct serio *serio); argument 49 int ps2_sendbyte(struct ps2dev *ps2dev, u8 byte, unsigned int timeout); 50 void ps2_drain(struct ps2dev *ps2dev, size_t maxbytes, unsigned int timeout); 51 void ps2_begin_command(struct ps2dev *ps2dev); 52 void ps2_end_command(struct ps2dev *ps2dev); 53 int __ps2_command(struct ps2dev *ps2dev, u8 *param, unsigned int command); 54 int ps2_command(struct ps2dev *ps2dev, u8 *param, unsigned int command); 55 int ps2_sliced_command(struct ps2dev *ps2dev, u8 command); 56 bool ps2_handle_ack(struct ps2dev *ps2dev, u8 data); [all …]
|
/kernel/linux/linux-5.10/drivers/input/mouse/ |
D | sentelic.c | 73 struct ps2dev *ps2dev = &psmouse->ps2dev; in fsp_reg_read() local 86 ps2_begin_command(ps2dev); in fsp_reg_read() 88 if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0) in fsp_reg_read() 92 ps2_sendbyte(ps2dev, 0x66, FSP_CMD_TIMEOUT2); in fsp_reg_read() 94 ps2_sendbyte(ps2dev, 0x88, FSP_CMD_TIMEOUT2); in fsp_reg_read() 96 if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0) in fsp_reg_read() 100 ps2_sendbyte(ps2dev, 0x68, FSP_CMD_TIMEOUT2); in fsp_reg_read() 103 ps2_sendbyte(ps2dev, 0xcc, FSP_CMD_TIMEOUT2); in fsp_reg_read() 107 ps2_sendbyte(ps2dev, 0x66, FSP_CMD_TIMEOUT2); in fsp_reg_read() 111 ps2_sendbyte(ps2dev, addr, FSP_CMD_TIMEOUT); in fsp_reg_read() [all …]
|
D | logips2pp.c | 117 error = ps2_sliced_command(&psmouse->ps2dev, command); in ps2pp_cmd() 121 error = ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_POLL | 0x0300); in ps2pp_cmd() 138 struct ps2dev *ps2dev = &psmouse->ps2dev; in ps2pp_set_smartscroll() local 144 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in ps2pp_set_smartscroll() 145 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in ps2pp_set_smartscroll() 146 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in ps2pp_set_smartscroll() 149 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in ps2pp_set_smartscroll() 189 struct ps2dev *ps2dev = &psmouse->ps2dev; in ps2pp_set_resolution() local 192 ps2_command(ps2dev, NULL, PSMOUSE_CMD_SETSCALE11); in ps2pp_set_resolution() 193 ps2_command(ps2dev, NULL, PSMOUSE_CMD_SETSCALE11); in ps2pp_set_resolution() [all …]
|
D | trackpoint.c | 33 static int trackpoint_power_on_reset(struct ps2dev *ps2dev) in trackpoint_power_on_reset() argument 38 err = ps2_command(ps2dev, param, MAKE_PS2_CMD(1, 2, TP_COMMAND)); in trackpoint_power_on_reset() 52 static int trackpoint_read(struct ps2dev *ps2dev, u8 loc, u8 *results) in trackpoint_read() argument 56 return ps2_command(ps2dev, results, MAKE_PS2_CMD(1, 1, TP_COMMAND)); in trackpoint_read() 59 static int trackpoint_write(struct ps2dev *ps2dev, u8 loc, u8 val) in trackpoint_write() argument 63 return ps2_command(ps2dev, param, MAKE_PS2_CMD(3, 0, TP_COMMAND)); in trackpoint_write() 66 static int trackpoint_toggle_bit(struct ps2dev *ps2dev, u8 loc, u8 mask) in trackpoint_toggle_bit() argument 74 return ps2_command(ps2dev, param, MAKE_PS2_CMD(3, 0, TP_COMMAND)); in trackpoint_toggle_bit() 77 static int trackpoint_update_bit(struct ps2dev *ps2dev, in trackpoint_update_bit() argument 83 retval = trackpoint_read(ps2dev, loc, &data); in trackpoint_update_bit() [all …]
|
D | focaltech.c | 267 struct ps2dev *ps2dev = &psmouse->ps2dev; in focaltech_switch_protocol() local 271 if (ps2_command(ps2dev, param, 0x10f8)) in focaltech_switch_protocol() 274 if (ps2_command(ps2dev, param, 0x10f8)) in focaltech_switch_protocol() 277 if (ps2_command(ps2dev, param, 0x10f8)) in focaltech_switch_protocol() 281 if (ps2_command(ps2dev, param, 0x10f8)) in focaltech_switch_protocol() 284 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETSCALE11)) in focaltech_switch_protocol() 287 if (ps2_command(ps2dev, param, PSMOUSE_CMD_ENABLE)) in focaltech_switch_protocol() 295 ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_RESET_DIS); in focaltech_reset() 347 static int focaltech_read_register(struct ps2dev *ps2dev, int reg, in focaltech_read_register() argument 350 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETSCALE11)) in focaltech_read_register() [all …]
|
D | alps.c | 1420 psmouse->ps2dev.serio->phys, in alps_register_bare_ps2_mouse() 1434 dev3->dev.parent = &psmouse->ps2dev.serio->dev; in alps_register_bare_ps2_mouse() 1582 serio_pause_rx(psmouse->ps2dev.serio); in alps_flush_packet() 1603 serio_continue_rx(psmouse->ps2dev.serio); in alps_flush_packet() 1688 struct ps2dev *ps2dev = &psmouse->ps2dev; in alps_command_mode_send_nibble() local 1700 if (ps2_command(ps2dev, param, command)) in alps_command_mode_send_nibble() 1708 struct ps2dev *ps2dev = &psmouse->ps2dev; in alps_command_mode_set_addr() local 1712 if (ps2_command(ps2dev, NULL, priv->addr_command)) in alps_command_mode_set_addr() 1726 struct ps2dev *ps2dev = &psmouse->ps2dev; in __alps_command_mode_read_reg() local 1729 if (ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO)) in __alps_command_mode_read_reg() [all …]
|
D | psmouse-base.c | 252 psmouse->ps2dev.flags = 0; in __psmouse_set_state() 263 serio_pause_rx(psmouse->ps2dev.serio); in psmouse_set_state() 265 serio_continue_rx(psmouse->ps2dev.serio); in psmouse_set_state() 287 serio_reconnect(psmouse->ps2dev.serio); in psmouse_handle_byte() 355 ps2_cmd_aborted(&psmouse->ps2dev); in psmouse_interrupt() 364 if (unlikely(psmouse->ps2dev.flags & PS2_FLAG_ACK)) in psmouse_interrupt() 365 if (ps2_handle_ack(&psmouse->ps2dev, data)) in psmouse_interrupt() 368 if (unlikely(psmouse->ps2dev.flags & PS2_FLAG_CMD)) in psmouse_interrupt() 369 if (ps2_handle_response(&psmouse->ps2dev, data)) in psmouse_interrupt() 440 error = ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_RESET_BAT); in psmouse_reset() [all …]
|
D | hgpk.c | 494 struct ps2dev *ps2dev = &psmouse->ps2dev; in hgpk_select_mode() local 520 if (ps2_command(ps2dev, NULL, advanced_init[i])) in hgpk_select_mode() 527 if (ps2_command(ps2dev, NULL, cmd)) in hgpk_select_mode() 610 struct ps2dev *ps2dev = &psmouse->ps2dev; in hgpk_reset_device() local 613 if (ps2_command(ps2dev, NULL, 0xf5) || in hgpk_reset_device() 614 ps2_command(ps2dev, NULL, 0xf5) || in hgpk_reset_device() 615 ps2_command(ps2dev, NULL, 0xe6) || in hgpk_reset_device() 616 ps2_command(ps2dev, NULL, 0xf5)) { in hgpk_reset_device() 694 struct ps2dev *ps2dev = &psmouse->ps2dev; in hgpk_toggle_powersave() local 713 if (!ps2_sendbyte(ps2dev, PSMOUSE_CMD_DISABLE, 20)) in hgpk_toggle_powersave() [all …]
|
D | byd.c | 257 serio_pause_rx(psmouse->ps2dev.serio); in byd_clear_touch() 262 serio_continue_rx(psmouse->ps2dev.serio); in byd_clear_touch() 341 struct ps2dev *ps2dev = &psmouse->ps2dev; in byd_reset_touchpad() local 390 if (ps2_command(ps2dev, param, seq[i].command)) in byd_reset_touchpad() 437 struct ps2dev *ps2dev = &psmouse->ps2dev; in byd_detect() local 440 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES)) in byd_detect() 442 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES)) in byd_detect() 444 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES)) in byd_detect() 446 if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES)) in byd_detect() 448 if (ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO)) in byd_detect()
|
D | lifebook.c | 201 struct ps2dev *ps2dev = &psmouse->ps2dev; in lifebook_absolute_mode() local 215 ps2_command(ps2dev, ¶m, PSMOUSE_CMD_SETRES); in lifebook_absolute_mode() 222 struct ps2dev *ps2dev = &psmouse->ps2dev; in lifebook_relative_mode() local 225 ps2_command(ps2dev, ¶m, PSMOUSE_CMD_SETRES); in lifebook_relative_mode() 237 ps2_command(&psmouse->ps2dev, &p, PSMOUSE_CMD_SETRES); in lifebook_set_resolution() 259 strcmp(psmouse->ps2dev.serio->phys, desired_serio_phys)) in lifebook_detect() 283 "%s/input1", psmouse->ps2dev.serio->phys); in lifebook_create_relative_device() 291 dev2->dev.parent = &psmouse->ps2dev.serio->dev; in lifebook_create_relative_device()
|
D | cypress_ps2.c | 40 struct ps2dev *ps2dev = &psmouse->ps2dev; in cypress_ps2_sendbyte() local 42 if (ps2_sendbyte(ps2dev, value & 0xff, CYTP_CMD_TIMEOUT) < 0) { in cypress_ps2_sendbyte() 45 value & 0xff, ps2dev->nak); in cypress_ps2_sendbyte() 46 if (ps2dev->nak == CYTP_PS2_RETRY) in cypress_ps2_sendbyte() 63 struct ps2dev *ps2dev = &psmouse->ps2dev; in cypress_ps2_ext_cmd() local 67 ps2_begin_command(ps2dev); in cypress_ps2_ext_cmd() 93 ps2_end_command(ps2dev); in cypress_ps2_ext_cmd() 103 struct ps2dev *ps2dev = &psmouse->ps2dev; in cypress_ps2_read_cmd_status() local 107 ps2_begin_command(ps2dev); in cypress_ps2_read_cmd_status() 120 wait_event_timeout(ps2dev->wait, in cypress_ps2_read_cmd_status() [all …]
|
D | psmouse.h | 92 struct ps2dev ps2dev; member 199 dev_dbg(&(psmouse)->ps2dev.serio->dev, \ 202 dev_info(&(psmouse)->ps2dev.serio->dev, \ 205 dev_warn(&(psmouse)->ps2dev.serio->dev, \ 208 dev_err(&(psmouse)->ps2dev.serio->dev, \ 211 dev_notice(&(psmouse)->ps2dev.serio->dev, \ 215 &(psmouse)->ps2dev.serio->dev, \
|
D | elantech.c | 38 if (ps2_sliced_command(&psmouse->ps2dev, c) || in synaptics_send_cmd() 39 ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_GETINFO)) { in synaptics_send_cmd() 53 struct ps2dev *ps2dev = &psmouse->ps2dev; in elantech_send_cmd() local 55 if (ps2_command(ps2dev, NULL, ETP_PS2_CUSTOM_COMMAND) || in elantech_send_cmd() 56 ps2_command(ps2dev, NULL, c) || in elantech_send_cmd() 57 ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO)) { in elantech_send_cmd() 71 struct ps2dev *ps2dev = &psmouse->ps2dev; in elantech_ps2_command() local 77 rc = ps2_command(ps2dev, param, command); in elantech_ps2_command() 151 if (ps2_sliced_command(&psmouse->ps2dev, ETP_REGISTER_READ) || in elantech_read_reg() 152 ps2_sliced_command(&psmouse->ps2dev, reg) || in elantech_read_reg() [all …]
|
D | synaptics.c | 84 error = ps2_sliced_command(&psmouse->ps2dev, mode); in synaptics_mode_cmd() 89 error = ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_SETRATE); in synaptics_mode_cmd() 98 struct ps2dev *ps2dev = &psmouse->ps2dev; in synaptics_detect() local 101 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in synaptics_detect() 102 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in synaptics_detect() 103 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in synaptics_detect() 104 ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES); in synaptics_detect() 105 ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO); in synaptics_detect() 210 error = ps2_sliced_command(&psmouse->ps2dev, cmd); in synaptics_send_cmd() 214 error = ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_GETINFO); in synaptics_send_cmd() [all …]
|
D | psmouse-smbus.c | 54 serio_rescan(smbdev->psmouse->ps2dev.serio); in psmouse_smbus_check_adapter() 78 serio_rescan(smbdev->psmouse->ps2dev.serio); in psmouse_smbus_detach_i2c_client()
|
D | touchkit_ps2.c | 66 if (ps2_command(&psmouse->ps2dev, param, command)) in touchkit_ps2_detect()
|
D | vmmouse.c | 443 psmouse->ps2dev.serio->phys); in vmmouse_init() 454 abs_dev->dev.parent = &psmouse->ps2dev.serio->dev; in vmmouse_init()
|
/kernel/linux/linux-5.10/drivers/input/keyboard/ |
D | atkbd.c | 205 struct ps2dev ps2dev; member 433 if (unlikely(atkbd->ps2dev.flags & PS2_FLAG_ACK)) in atkbd_interrupt() 434 if (ps2_handle_ack(&atkbd->ps2dev, data)) in atkbd_interrupt() 437 if (unlikely(atkbd->ps2dev.flags & PS2_FLAG_CMD)) in atkbd_interrupt() 438 if (ps2_handle_response(&atkbd->ps2dev, data)) in atkbd_interrupt() 465 serio_reconnect(atkbd->ps2dev.serio); in atkbd_interrupt() 595 return ps2_command(&atkbd->ps2dev, ¶m, ATKBD_CMD_SETREP); in atkbd_set_repeat_rate() 606 if (ps2_command(&atkbd->ps2dev, param, ATKBD_CMD_SETLEDS)) in atkbd_set_leds() 616 if (ps2_command(&atkbd->ps2dev, param, ATKBD_CMD_EX_SETLEDS)) in atkbd_set_leds() 709 serio_pause_rx(atkbd->ps2dev.serio); in atkbd_enable() [all …]
|