usb storage: first migration support bits.
Tag vmstate as unmigratable for the time being, to be removed when mgration support is finished. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
9490fb0624
commit
f54b656303
12
hw/usb-msd.c
12
hw/usb-msd.c
@ -623,11 +623,23 @@ static USBDevice *usb_msd_init(const char *filename)
|
|||||||
return dev;
|
return dev;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static const VMStateDescription vmstate_usb_msd = {
|
||||||
|
.name = "usb-storage",
|
||||||
|
.unmigratable = 1, /* FIXME: handle transactions which are in flight */
|
||||||
|
.version_id = 1,
|
||||||
|
.minimum_version_id = 1,
|
||||||
|
.fields = (VMStateField []) {
|
||||||
|
VMSTATE_USB_DEVICE(dev, MSDState),
|
||||||
|
VMSTATE_END_OF_LIST()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
static struct USBDeviceInfo msd_info = {
|
static struct USBDeviceInfo msd_info = {
|
||||||
.product_desc = "QEMU USB MSD",
|
.product_desc = "QEMU USB MSD",
|
||||||
.qdev.name = "usb-storage",
|
.qdev.name = "usb-storage",
|
||||||
.qdev.fw_name = "storage",
|
.qdev.fw_name = "storage",
|
||||||
.qdev.size = sizeof(MSDState),
|
.qdev.size = sizeof(MSDState),
|
||||||
|
.qdev.vmsd = &vmstate_usb_msd,
|
||||||
.usb_desc = &desc,
|
.usb_desc = &desc,
|
||||||
.init = usb_msd_initfn,
|
.init = usb_msd_initfn,
|
||||||
.handle_packet = usb_generic_handle_packet,
|
.handle_packet = usb_generic_handle_packet,
|
||||||
|
Loading…
Reference in New Issue
Block a user