aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2020-07-03 16:59:44 +0100
committerPeter Maydell <peter.maydell@linaro.org>2020-07-03 16:59:44 +0100
commit40d9d2f7682c789404ed5b249012ac44f9e6ea8f (patch)
treea6d342df859340b1dadde9345881c2b214c0f2ec /hw
parentb064d51f6022c49ceab73c46e84ae05f9f704732 (diff)
hw/misc/max111x: Don't use vmstate_register()
The max111x is a proper qdev device; we can use dc->vmsd rather than directly calling vmstate_register(). It's possible that this is a migration compat break, but the only boards that use this device are the spitz-family ('akita', 'borzoi', 'spitz', 'terrier'). Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Message-id: 20200628142429.17111-8-peter.maydell@linaro.org
Diffstat (limited to 'hw')
-rw-r--r--hw/misc/max111x.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/misc/max111x.c b/hw/misc/max111x.c
index d0e5534e4f..abddfa3c66 100644
--- a/hw/misc/max111x.c
+++ b/hw/misc/max111x.c
@@ -140,8 +140,6 @@ static int max111x_init(SSISlave *d, int inputs)
s->inputs = inputs;
- vmstate_register(VMSTATE_IF(dev), VMSTATE_INSTANCE_ID_ANY,
- &vmstate_max111x, s);
return 0;
}
@@ -206,6 +204,7 @@ static void max111x_class_init(ObjectClass *klass, void *data)
k->transfer = max111x_transfer;
dc->reset = max111x_reset;
+ dc->vmsd = &vmstate_max111x;
}
static const TypeInfo max111x_info = {