summary refs log tree commit diff stats
path: root/hw/virtio/virtio-input-pci.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2019-07-26 15:40:28 +0100
committerPeter Maydell <peter.maydell@linaro.org>2019-07-26 16:17:56 +0100
commit372e458ebc41c980d4fa23e3234a5222813cd405 (patch)
treef066fbca8a73f10f0efb3fd7d5dcc0256a1ef48b /hw/virtio/virtio-input-pci.c
parent830fc739d05b87b547ae281435335b366a279e20 (diff)
downloadfocaccia-qemu-372e458ebc41c980d4fa23e3234a5222813cd405.tar.gz
focaccia-qemu-372e458ebc41c980d4fa23e3234a5222813cd405.zip
stellaris_input: Fix vmstate description of buttons field
gamepad_state::buttons is a pointer to an array of structs,
not an array of structs, so should be declared in the vmstate
with VMSTATE_STRUCT_VARRAY_POINTER_INT32; otherwise we
corrupt memory on incoming migration.

We bump the vmstate version field as the easiest way to
deal with the migration break, since migration wouldn't have
worked reliably before anyway.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Damien Hedde <damien.hedde@greensocs.com>
Message-id: 20190725163710.11703-2-peter.maydell@linaro.org
Diffstat (limited to 'hw/virtio/virtio-input-pci.c')
0 files changed, 0 insertions, 0 deletions