qemu/hw/input
Peter Maydell 7c76f397fd hw/input/stellaris_gamepad: Convert to qemu_input_handler_register()
Now that we have converted to qdev, we can use the newer
qemu_input_handler_register() API rather than the legacy
qemu_add_kbd_event_handler().

Since we only have one user, take the opportunity to convert
from scancodes to QCodes, rather than using
qemu_input_key_value_to_scancode() (which adds an 0xe0
prefix and encodes up/down indication in the scancode,
which our old handler function then had to reverse). That
lets us drop the old state field which was tracking whether
we were halfway through a two-byte scancode.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-id: 20231030114802.3671871-7-peter.maydell@linaro.org
2023-11-02 12:52:06 +00:00
..
adb-internal.h
adb-kbd.c ui/input: Constify QemuInputHandler structure 2023-10-19 23:13:28 +02:00
adb-mouse.c Use OBJECT_DECLARE_TYPE when possible 2020-09-18 14:12:32 -04:00
adb.c Replace use of qdev_reset_all() with device_cold_reset() 2022-12-16 15:55:32 +00:00
ads7846.c replace TABs with spaces 2023-03-20 12:43:50 +01:00
hid.c ui/input: Constify QemuInputHandler structure 2023-10-19 23:13:28 +02:00
Kconfig hw/input/stellaris_input: Rename to stellaris_gamepad 2023-11-02 12:52:06 +00:00
lasips2.c lasips2: LASI PS/2 devices are not user-createable 2023-10-17 23:13:19 +02:00
lm832x.c hw/input/lm832x: Define TYPE_LM8323 in public header 2021-07-08 14:15:01 -05:00
meson.build hw/input/stellaris_input: Rename to stellaris_gamepad 2023-11-02 12:52:06 +00:00
pckbd.c pckbd: remove legacy i8042_mm_init() function 2022-07-18 19:28:46 +01:00
pl050.c pl050: don't use legacy ps2_mouse_init() function 2022-07-18 19:28:46 +01:00
ps2.c ui/input: Constify QemuInputHandler structure 2023-10-19 23:13:28 +02:00
pxa2xx_keypad.c Use g_new() & friends where that makes obvious sense 2022-03-21 15:44:44 +01:00
stellaris_gamepad.c hw/input/stellaris_gamepad: Convert to qemu_input_handler_register() 2023-11-02 12:52:06 +00:00
trace-events ps2: remove unused legacy ps2_mouse_init() function 2022-07-18 19:28:46 +01:00
trace.h
tsc210x.c audio: propagate Error * out of audio_init 2023-10-03 10:29:40 +02:00
tsc2005.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
vhost-user-input.c vhost-user: fully use new backend/frontend naming 2023-06-26 09:50:00 -04:00
virtio-input-hid.c ui/input: Constify QemuInputHandler structure 2023-10-19 23:13:28 +02:00
virtio-input-host.c hw: replace qemu_set_nonblock() 2022-05-03 15:52:33 +04:00
virtio-input.c virtio: drop name parameter for virtio_init() 2022-05-16 04:38:40 -04:00