qemu-patch-raspberry4/hw/input
Markus Armbruster c6047e9621 virtio-input: Fix device introspection on non-Linux hosts
When CONFIG_LINUX is off, devices "virtio-keyboard-device",
"virtio-mouse-device", "virtio-tablet-device" and
"virtio-input-host-device" aren't compiled in, yet
"virtio-keyboard-pci", "virtio-mouse-pci", "virtio-tablet-pci" and
"virtio-input-host-pci" still are.  Attempts to introspect them crash,
e.g.

    $ qemu-system-x86_64 -device virtio-tablet-pci,help
    **
    ERROR:/work/armbru/qemu/qom/object.c:333:object_initialize_with_type: assertion failed: (type != NULL)

Broken in commit 710e2d9 and commit 006a5ed.

Fix by compiling the "virtio-FOO-pci" exactly when compiling the
"virtio-FOO-device": compile "virtio-keyboard-device",
"virtio-mouse-device", "virtio-tablet-device" regardless of
CONFIG_LINUX, and compile "virtio-input-host-pci" only for
CONFIG_LINUX.

Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <1444320700-26260-3-git-send-email-armbru@redhat.com>
2015-10-09 15:25:56 +02:00
..
adb.c adb.c: include ADBDevice parent state in KBDState and MouseState 2015-03-09 15:00:04 +01:00
hid.c hid: clarify hid_keyboard_process_keycode 2015-07-17 08:44:41 +02:00
lm832x.c vmstate: accept QEMUTimer in VMSTATE_TIMER*, add VMSTATE_TIMER_PTR* 2015-01-26 12:22:44 +01:00
Makefile.objs virtio-input: Fix device introspection on non-Linux hosts 2015-10-09 15:25:56 +02:00
milkymist-softusb.c Fix bad error handling after memory_region_init_ram() 2015-09-18 14:39:29 +02:00
pckbd.c migration: Use normal VMStateDescriptions for Subsections 2015-06-12 06:53:57 +02:00
pl050.c pl050: QOM'ify pl050_keyboard and pl050_mouse 2013-07-29 21:06:57 +02:00
ps2.c migration: Use normal VMStateDescriptions for Subsections 2015-06-12 06:53:57 +02:00
pxa2xx_keypad.c savevm: Remove all the unneeded version_minimum_id_old (arm) 2014-05-13 16:09:35 +01:00
stellaris_input.c typofixes - v4 2015-09-11 10:45:43 +03:00
tsc210x.c hw/input/tsc210x.c: Delete unused array tsc2101_rates 2014-09-29 18:48:48 +01:00
tsc2005.c aio / timers: Switch entire codebase to the new timer API 2013-08-22 19:14:24 +02:00
virtio-input-hid.c virtio-input: fix segfault in virtio_input_hid_properties 2015-07-16 17:34:41 +02:00
virtio-input-host.c virtio-input: move sys/ioctl.h include 2015-07-16 17:34:41 +02:00
virtio-input.c virtio: get_features() can fail 2015-07-27 18:11:53 +03:00
vmmouse.c savevm: Remove all the unneeded version_minimum_id_old (x86) 2014-06-16 04:55:26 +02:00