migration: Use vmstate_register_any() for vmware_vga
authorJuan Quintela <quintela@redhat.com>
Fri, 20 Oct 2023 09:07:31 +0000 (11:07 +0200)
committerJuan Quintela <quintela@redhat.com>
Wed, 1 Nov 2023 15:13:58 +0000 (16:13 +0100)
I have no idea if we can have more than one vmware_vga device, so play
it safe.

Reviewed-by: Stefan Berger <stefanb@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231020090731.28701-14-quintela@redhat.com>

hw/display/vmware_vga.c

index 09591fbd39f9f1d5e0a1f61a2ab9a09936b13a91..7490d4388112b2929c99f11982248ccccadd62c4 100644 (file)
@@ -1264,7 +1264,7 @@ static void vmsvga_init(DeviceState *dev, struct vmsvga_state_s *s,
 
     vga_common_init(&s->vga, OBJECT(dev), &error_fatal);
     vga_init(&s->vga, OBJECT(dev), address_space, io, true);
-    vmstate_register(NULL, 0, &vmstate_vga_common, &s->vga);
+    vmstate_register_any(NULL, &vmstate_vga_common, &s->vga);
     s->new_depth = 32;
 }