diff options
author | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2022-07-12 22:52:23 +0100 |
---|---|---|
committer | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2022-07-18 19:28:46 +0100 |
commit | 17b8013acbfacdbb5906719b4df54c362ef182af (patch) | |
tree | d187c09aae27da6ba50ffd4aa99f913d088fe3d4 /hw/input | |
parent | 6f9f245b932de0c05f618fb1ff2c251dce23cd29 (diff) | |
download | qemu-17b8013acbfacdbb5906719b4df54c362ef182af.zip qemu-17b8013acbfacdbb5906719b4df54c362ef182af.tar.gz qemu-17b8013acbfacdbb5906719b4df54c362ef182af.tar.bz2 |
lasips2: don't use vmstate_register() in lasips2_realize()
Since lasips2 is a qdev device then vmstate_ps2_mouse can be registered using
the DeviceClass vmsd field instead.
Note that due to the use of the base parameter in the original vmstate_register()
function call, this is actually a migration break for the HPPA B160L machine.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Tested-by: Helge Deller <deller@gmx.de>
Acked-by: Helge Deller <deller@gmx.de>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-Id: <20220712215251.7944-13-mark.cave-ayland@ilande.co.uk>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Diffstat (limited to 'hw/input')
-rw-r--r-- | hw/input/lasips2.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/input/lasips2.c b/hw/input/lasips2.c index 9223cb0..d4fa248 100644 --- a/hw/input/lasips2.c +++ b/hw/input/lasips2.c @@ -272,8 +272,6 @@ static void lasips2_realize(DeviceState *dev, Error **errp) { LASIPS2State *s = LASIPS2(dev); - vmstate_register(NULL, s->base, &vmstate_lasips2, s); - s->kbd.dev = ps2_kbd_init(); qdev_connect_gpio_out(DEVICE(s->kbd.dev), PS2_DEVICE_IRQ, qdev_get_gpio_in_named(dev, "ps2-kbd-input-irq", @@ -319,6 +317,7 @@ static void lasips2_class_init(ObjectClass *klass, void *data) DeviceClass *dc = DEVICE_CLASS(klass); dc->realize = lasips2_realize; + dc->vmsd = &vmstate_lasips2; device_class_set_props(dc, lasips2_properties); set_bit(DEVICE_CATEGORY_INPUT, dc->categories); } |