qemu/hw/ide
Bernhard Beschow 752dfff5ec hw/ide/piix: Move registration of VMStateDescription to DeviceClass
The modern, declarative way to set up VM state handling is to assign to
DeviceClass::vmsd attribute.

There shouldn't be any change in behavior since dc->vmsd causes
vmstate_register_with_alias_id() to be called on the instance during
the instance init phase. vmstate_register() was also called during the
instance init phase which forwards to vmstate_register_with_alias_id()
internally. Checking the migration schema before and after this patch confirms:

before:
> qemu-system-x86_64 -S
> qemu > migrate -d exec:cat>before.mig

after:
> qemu-system-x86_64 -S
> qemu > migrate -d exec:cat>after.mig

> analyze-migration.py -d desc -f before.mig > before.json
> analyze-migration.py -d desc -f after.mig > after.json
> diff before.json after.json
-> empty

Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Message-Id: <20230531211043.41724-8-shentey@gmail.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
2023-07-11 00:11:25 +02:00
..
ahci-allwinner.c ahci: Move QOM macro to header 2020-08-27 14:04:54 -04:00
ahci.c hw/ide/ahci: Remove stray backslash 2023-06-13 11:28:58 +02:00
ahci_internal.h hw: replace most qemu_bh_new calls with qemu_bh_new_guarded 2023-04-28 11:31:54 +02:00
atapi.c hw/ide: Rename ide_set_irq() -> ide_bus_set_irq() 2023-02-27 22:29:02 +01:00
cmd646.c hw/ide: Extract bmdma_status_writeb() 2023-07-11 00:11:25 +02:00
core.c hw: replace most qemu_bh_new calls with qemu_bh_new_guarded 2023-04-28 11:31:54 +02:00
ich.c hw/ide: Un-inline ide_set_irq() 2023-02-27 22:29:02 +01:00
ioport.c hw/ide/ioport: Remove unnecessary includes 2023-02-27 22:29:02 +01:00
isa.c hw/ide: Rename ide_init2() -> ide_bus_init_output_irq() 2023-02-27 22:29:02 +01:00
Kconfig hw/ide/Kconfig: Add missing dependency PCI -> IDE_QDEV 2021-07-20 15:30:42 +02:00
macio.c hw/ide: Rename idebus_active_if() -> ide_bus_active_if() 2023-02-27 22:29:02 +01:00
meson.build meson: Replace softmmu_ss -> system_ss 2023-06-20 10:01:30 +02:00
microdrive.c hw/ide: replace TABs with space 2023-03-24 11:45:33 +01:00
mmio.c hw/ide: Rename ide_init2() -> ide_bus_init_output_irq() 2023-02-27 22:29:02 +01:00
pci.c hw/ide/pci: Replace some magic numbers by constants 2023-07-11 00:11:25 +02:00
piix.c hw/ide/piix: Move registration of VMStateDescription to DeviceClass 2023-07-11 00:11:25 +02:00
qdev.c hw/ide: Rename ide_create_drive() -> ide_bus_create_drive() 2023-02-27 22:29:02 +01:00
sii3112.c hw/ide: Extract bmdma_status_writeb() 2023-07-11 00:11:25 +02:00
trace-events hw/ide: Rename ide_exec_cmd() -> ide_bus_exec_cmd() 2023-02-27 22:29:02 +01:00
trace.h trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00
via.c hw/ide: Extract bmdma_status_writeb() 2023-07-11 00:11:25 +02:00