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>
This commit is contained in:
parent
6f9f245b93
commit
17b8013acb
@ -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);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user