migration/next for 20140515
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABCAAGBQJTdBkpAAoJEPSH7xhYctcj5jAQAJKiJ/43TBk0S0wlpoPjw1yA WSC/oJ2yvf+i6EndJPdnxIA/3K3s7suRFBJVYwLVnGJTUZ6gwGcI7cc/EX/iK0vf 1Ffv/RAuh3nkohFw1ZMLQGqACFskSer0K1wZgQg+YjiJRPzzpVOpaAVm3+c04LRN AjO9LTqudi2pFaDHfGQMFES3j/5+h2srdad7YLMu4h/17SLtcowO7Yf7GT+GHRyD c3OHcL6vNoCKkIJQULC8X5czh6zapQZG3SRZ/nLt58yjEyVuq4L2cNRA/614K+5b 1YLz4dX6slj8y17tg8On60emU0Sdu4mOws9HtYSytfmEu045iuF+Wr4kNjO74UGd NnnjD1pdnuF7356pz87PiVBf7qer5yrv+Bog1KRUwn3ETFqpSOMiKJo0JAGBMKdN w6Mbkg9C7IR62OfmM5157Mj2Xd681GImNiYzerBMfuFAWk5XsMxuz9Xh03I7WpzS ASow6SCBIr7bsiKENV7twuz1mIQclsYWXaVt8ldH8bMsTCqiefVeDs4o6A3Na+WC LztUHzlhVLZU92uJDiIsyQnwmsw032RjhKY9sV/NMa5HLAhF/zZLcn1OfXshrv8t mVnWngGbY185kml0GmLu9TSnSCBSD8lcwZlRA9JVyxfusxElJUOrQzKzvu69Rn6U XBWPBwppnDQ0MjOgSZD+ =gg8m -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/juanquintela/tags/migration/20140515' into staging migration/next for 20140515 # gpg: Signature made Thu 15 May 2014 02:32:25 BST using RSA key ID 5872D723 # gpg: Can't check signature: public key not found * remotes/juanquintela/tags/migration/20140515: usb: fix up post load checks migration: show average throughput when migration finishes savevm: Remove all the unneeded version_minimum_id_old (rest) savevm: Remove all the unneeded version_minimum_id_old (usb) Split ram_save_block arch_init: Simplify code for load_xbzrle() Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
895527eea5
101
arch_init.c
101
arch_init.c
|
@ -560,45 +560,22 @@ static void migration_bitmap_sync(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ram_save_block: Writes a page of memory to the stream f
|
* ram_save_page: Send the given page to the stream
|
||||||
*
|
*
|
||||||
* Returns: The number of bytes written.
|
* Returns: Number of bytes written.
|
||||||
* 0 means no dirty pages
|
|
||||||
*/
|
*/
|
||||||
|
static int ram_save_page(QEMUFile *f, RAMBlock* block, ram_addr_t offset,
|
||||||
static int ram_save_block(QEMUFile *f, bool last_stage)
|
bool last_stage)
|
||||||
{
|
{
|
||||||
RAMBlock *block = last_seen_block;
|
int bytes_sent;
|
||||||
ram_addr_t offset = last_offset;
|
int cont;
|
||||||
bool complete_round = false;
|
|
||||||
int bytes_sent = 0;
|
|
||||||
MemoryRegion *mr;
|
|
||||||
ram_addr_t current_addr;
|
ram_addr_t current_addr;
|
||||||
|
MemoryRegion *mr = block->mr;
|
||||||
if (!block)
|
|
||||||
block = QTAILQ_FIRST(&ram_list.blocks);
|
|
||||||
|
|
||||||
while (true) {
|
|
||||||
mr = block->mr;
|
|
||||||
offset = migration_bitmap_find_and_reset_dirty(mr, offset);
|
|
||||||
if (complete_round && block == last_seen_block &&
|
|
||||||
offset >= last_offset) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if (offset >= block->length) {
|
|
||||||
offset = 0;
|
|
||||||
block = QTAILQ_NEXT(block, next);
|
|
||||||
if (!block) {
|
|
||||||
block = QTAILQ_FIRST(&ram_list.blocks);
|
|
||||||
complete_round = true;
|
|
||||||
ram_bulk_stage = false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
int ret;
|
|
||||||
uint8_t *p;
|
uint8_t *p;
|
||||||
|
int ret;
|
||||||
bool send_async = true;
|
bool send_async = true;
|
||||||
int cont = (block == last_sent_block) ?
|
|
||||||
RAM_SAVE_FLAG_CONTINUE : 0;
|
cont = (block == last_sent_block) ? RAM_SAVE_FLAG_CONTINUE : 0;
|
||||||
|
|
||||||
p = memory_region_get_ram_ptr(mr) + offset;
|
p = memory_region_get_ram_ptr(mr) + offset;
|
||||||
|
|
||||||
|
@ -652,6 +629,46 @@ static int ram_save_block(QEMUFile *f, bool last_stage)
|
||||||
}
|
}
|
||||||
|
|
||||||
XBZRLE_cache_unlock();
|
XBZRLE_cache_unlock();
|
||||||
|
|
||||||
|
return bytes_sent;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* ram_find_and_save_block: Finds a page to send and sends it to f
|
||||||
|
*
|
||||||
|
* Returns: The number of bytes written.
|
||||||
|
* 0 means no dirty pages
|
||||||
|
*/
|
||||||
|
|
||||||
|
static int ram_find_and_save_block(QEMUFile *f, bool last_stage)
|
||||||
|
{
|
||||||
|
RAMBlock *block = last_seen_block;
|
||||||
|
ram_addr_t offset = last_offset;
|
||||||
|
bool complete_round = false;
|
||||||
|
int bytes_sent = 0;
|
||||||
|
MemoryRegion *mr;
|
||||||
|
|
||||||
|
if (!block)
|
||||||
|
block = QTAILQ_FIRST(&ram_list.blocks);
|
||||||
|
|
||||||
|
while (true) {
|
||||||
|
mr = block->mr;
|
||||||
|
offset = migration_bitmap_find_and_reset_dirty(mr, offset);
|
||||||
|
if (complete_round && block == last_seen_block &&
|
||||||
|
offset >= last_offset) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if (offset >= block->length) {
|
||||||
|
offset = 0;
|
||||||
|
block = QTAILQ_NEXT(block, next);
|
||||||
|
if (!block) {
|
||||||
|
block = QTAILQ_FIRST(&ram_list.blocks);
|
||||||
|
complete_round = true;
|
||||||
|
ram_bulk_stage = false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
bytes_sent = ram_save_page(f, block, offset, last_stage);
|
||||||
|
|
||||||
/* if page is unmodified, continue to the next */
|
/* if page is unmodified, continue to the next */
|
||||||
if (bytes_sent > 0) {
|
if (bytes_sent > 0) {
|
||||||
last_sent_block = block;
|
last_sent_block = block;
|
||||||
|
@ -850,7 +867,7 @@ static int ram_save_iterate(QEMUFile *f, void *opaque)
|
||||||
while ((ret = qemu_file_rate_limit(f)) == 0) {
|
while ((ret = qemu_file_rate_limit(f)) == 0) {
|
||||||
int bytes_sent;
|
int bytes_sent;
|
||||||
|
|
||||||
bytes_sent = ram_save_block(f, false);
|
bytes_sent = ram_find_and_save_block(f, false);
|
||||||
/* no more blocks to sent */
|
/* no more blocks to sent */
|
||||||
if (bytes_sent == 0) {
|
if (bytes_sent == 0) {
|
||||||
break;
|
break;
|
||||||
|
@ -912,7 +929,7 @@ static int ram_save_complete(QEMUFile *f, void *opaque)
|
||||||
while (true) {
|
while (true) {
|
||||||
int bytes_sent;
|
int bytes_sent;
|
||||||
|
|
||||||
bytes_sent = ram_save_block(f, true);
|
bytes_sent = ram_find_and_save_block(f, true);
|
||||||
/* no more blocks to sent */
|
/* no more blocks to sent */
|
||||||
if (bytes_sent == 0) {
|
if (bytes_sent == 0) {
|
||||||
break;
|
break;
|
||||||
|
@ -946,7 +963,6 @@ static uint64_t ram_save_pending(QEMUFile *f, void *opaque, uint64_t max_size)
|
||||||
|
|
||||||
static int load_xbzrle(QEMUFile *f, ram_addr_t addr, void *host)
|
static int load_xbzrle(QEMUFile *f, ram_addr_t addr, void *host)
|
||||||
{
|
{
|
||||||
int ret, rc = 0;
|
|
||||||
unsigned int xh_len;
|
unsigned int xh_len;
|
||||||
int xh_flags;
|
int xh_flags;
|
||||||
|
|
||||||
|
@ -971,18 +987,13 @@ static int load_xbzrle(QEMUFile *f, ram_addr_t addr, void *host)
|
||||||
qemu_get_buffer(f, xbzrle_decoded_buf, xh_len);
|
qemu_get_buffer(f, xbzrle_decoded_buf, xh_len);
|
||||||
|
|
||||||
/* decode RLE */
|
/* decode RLE */
|
||||||
ret = xbzrle_decode_buffer(xbzrle_decoded_buf, xh_len, host,
|
if (xbzrle_decode_buffer(xbzrle_decoded_buf, xh_len, host,
|
||||||
TARGET_PAGE_SIZE);
|
TARGET_PAGE_SIZE) == -1) {
|
||||||
if (ret == -1) {
|
|
||||||
fprintf(stderr, "Failed to load XBZRLE page - decode error!\n");
|
fprintf(stderr, "Failed to load XBZRLE page - decode error!\n");
|
||||||
rc = -1;
|
return -1;
|
||||||
} else if (ret > TARGET_PAGE_SIZE) {
|
|
||||||
fprintf(stderr, "Failed to load XBZRLE page - size %d exceeds %d!\n",
|
|
||||||
ret, TARGET_PAGE_SIZE);
|
|
||||||
abort();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return rc;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void *host_from_stream_offset(QEMUFile *f,
|
static inline void *host_from_stream_offset(QEMUFile *f,
|
||||||
|
|
|
@ -1812,8 +1812,7 @@ static const VMStateDescription vmstate_audio = {
|
||||||
.name = "audio",
|
.name = "audio",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
1
cpus.c
1
cpus.c
|
@ -430,7 +430,6 @@ static const VMStateDescription vmstate_timers = {
|
||||||
.name = "timer",
|
.name = "timer",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT64(cpu_ticks_offset, TimersState),
|
VMSTATE_INT64(cpu_ticks_offset, TimersState),
|
||||||
VMSTATE_INT64(dummy, TimersState),
|
VMSTATE_INT64(dummy, TimersState),
|
||||||
|
|
|
@ -139,7 +139,7 @@ static const VMStateDescription vmstate_kbd = {
|
||||||
.name = "pckbd",
|
.name = "pckbd",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 3,
|
.minimum_version_id = 3,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(write_cmd, KBDState),
|
VMSTATE_UINT8(write_cmd, KBDState),
|
||||||
VMSTATE_UINT8(status, KBDState),
|
VMSTATE_UINT8(status, KBDState),
|
||||||
VMSTATE_UINT8(mode, KBDState),
|
VMSTATE_UINT8(mode, KBDState),
|
||||||
|
@ -257,7 +257,7 @@ const VMStateDescription vmstate_ide_drive_pio_state = {
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.pre_save = ide_drive_pio_pre_save,
|
.pre_save = ide_drive_pio_pre_save,
|
||||||
.post_load = ide_drive_pio_post_load,
|
.post_load = ide_drive_pio_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(req_nb_sectors, IDEState),
|
VMSTATE_INT32(req_nb_sectors, IDEState),
|
||||||
VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1,
|
VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1,
|
||||||
vmstate_info_uint8, uint8_t),
|
vmstate_info_uint8, uint8_t),
|
||||||
|
@ -275,7 +275,7 @@ const VMStateDescription vmstate_ide_drive = {
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.post_load = ide_drive_post_load,
|
.post_load = ide_drive_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
.... several fields ....
|
.... several fields ....
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
},
|
},
|
||||||
|
|
3
exec.c
3
exec.c
|
@ -429,9 +429,8 @@ const VMStateDescription vmstate_cpu_common = {
|
||||||
.name = "cpu_common",
|
.name = "cpu_common",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = cpu_common_post_load,
|
.post_load = cpu_common_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(halted, CPUState),
|
VMSTATE_UINT32(halted, CPUState),
|
||||||
VMSTATE_UINT32(interrupt_request, CPUState),
|
VMSTATE_UINT32(interrupt_request, CPUState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -316,7 +316,6 @@ static const VMStateDescription vmstate_milkymist_ac97 = {
|
||||||
.name = "milkymist-ac97",
|
.name = "milkymist-ac97",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = ac97_post_load,
|
.post_load = ac97_post_load,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistAC97State, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistAC97State, R_MAX),
|
||||||
|
|
|
@ -653,7 +653,6 @@ static const VMStateDescription vmstate_m25p80 = {
|
||||||
.name = "xilinx_spi",
|
.name = "xilinx_spi",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.pre_save = m25p80_pre_save,
|
.pre_save = m25p80_pre_save,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(state, Flash),
|
VMSTATE_UINT8(state, Flash),
|
||||||
|
|
|
@ -124,7 +124,6 @@ static const VMStateDescription vmstate_scc2698_channel = {
|
||||||
.name = "scc2698_channel",
|
.name = "scc2698_channel",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BOOL(rx_enabled, SCC2698Channel),
|
VMSTATE_BOOL(rx_enabled, SCC2698Channel),
|
||||||
VMSTATE_UINT8_ARRAY(mr, SCC2698Channel, 2),
|
VMSTATE_UINT8_ARRAY(mr, SCC2698Channel, 2),
|
||||||
|
@ -141,7 +140,6 @@ static const VMStateDescription vmstate_scc2698_block = {
|
||||||
.name = "scc2698_block",
|
.name = "scc2698_block",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(imr, SCC2698Block),
|
VMSTATE_UINT8(imr, SCC2698Block),
|
||||||
VMSTATE_UINT8(isr, SCC2698Block),
|
VMSTATE_UINT8(isr, SCC2698Block),
|
||||||
|
@ -153,7 +151,6 @@ static const VMStateDescription vmstate_ipoctal = {
|
||||||
.name = "ipoctal232",
|
.name = "ipoctal232",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_IPACK_DEVICE(parent_obj, IPOctalState),
|
VMSTATE_IPACK_DEVICE(parent_obj, IPOctalState),
|
||||||
VMSTATE_STRUCT_ARRAY(ch, IPOctalState, N_CHANNELS, 1,
|
VMSTATE_STRUCT_ARRAY(ch, IPOctalState, N_CHANNELS, 1,
|
||||||
|
|
|
@ -129,7 +129,6 @@ static const VMStateDescription vmstate_lm32_juart = {
|
||||||
.name = "lm32-juart",
|
.name = "lm32-juart",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(jtx, LM32JuartState),
|
VMSTATE_UINT32(jtx, LM32JuartState),
|
||||||
VMSTATE_UINT32(jrx, LM32JuartState),
|
VMSTATE_UINT32(jrx, LM32JuartState),
|
||||||
|
|
|
@ -270,7 +270,6 @@ static const VMStateDescription vmstate_lm32_uart = {
|
||||||
.name = "lm32-uart",
|
.name = "lm32-uart",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, LM32UartState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, LM32UartState, R_MAX),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -221,7 +221,6 @@ static const VMStateDescription vmstate_milkymist_uart = {
|
||||||
.name = "milkymist-uart",
|
.name = "milkymist-uart",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistUartState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistUartState, R_MAX),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -291,7 +291,6 @@ static const VMStateDescription vmstate_sclplmconsole = {
|
||||||
.name = "sclplmconsole",
|
.name = "sclplmconsole",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BOOL(event.event_pending, SCLPConsoleLM),
|
VMSTATE_BOOL(event.event_pending, SCLPConsoleLM),
|
||||||
VMSTATE_UINT32(write_errors, SCLPConsoleLM),
|
VMSTATE_UINT32(write_errors, SCLPConsoleLM),
|
||||||
|
|
|
@ -185,7 +185,6 @@ static const VMStateDescription vmstate_sclpconsole = {
|
||||||
.name = "sclpconsole",
|
.name = "sclpconsole",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BOOL(event.event_pending, SCLPConsole),
|
VMSTATE_BOOL(event.event_pending, SCLPConsole),
|
||||||
VMSTATE_UINT8_ARRAY(iov, SCLPConsole, SIZE_BUFFER_VT220),
|
VMSTATE_UINT8_ARRAY(iov, SCLPConsole, SIZE_BUFFER_VT220),
|
||||||
|
|
|
@ -206,7 +206,6 @@ const VMStateDescription vmstate_ptimer = {
|
||||||
.name = "ptimer",
|
.name = "ptimer",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(enabled, ptimer_state),
|
VMSTATE_UINT8(enabled, ptimer_state),
|
||||||
VMSTATE_UINT64(limit, ptimer_state),
|
VMSTATE_UINT64(limit, ptimer_state),
|
||||||
|
|
|
@ -459,7 +459,6 @@ static const VMStateDescription vmstate_g364fb = {
|
||||||
.name = "g364fb",
|
.name = "g364fb",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = g364fb_post_load,
|
.post_load = g364fb_post_load,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_VBUFFER_UINT32(vram, G364State, 1, NULL, 0, vram_size),
|
VMSTATE_VBUFFER_UINT32(vram, G364State, 1, NULL, 0, vram_size),
|
||||||
|
|
|
@ -250,7 +250,6 @@ static const VMStateDescription vmstate_jazz_led = {
|
||||||
.name = "jazz-led",
|
.name = "jazz-led",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.post_load = jazz_led_post_load,
|
.post_load = jazz_led_post_load,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(segments, LedState),
|
VMSTATE_UINT8(segments, LedState),
|
||||||
|
|
|
@ -463,7 +463,6 @@ static const VMStateDescription vmstate_milkymist_tmu2 = {
|
||||||
.name = "milkymist-tmu2",
|
.name = "milkymist-tmu2",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistTMU2State, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistTMU2State, R_MAX),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -305,7 +305,6 @@ static const VMStateDescription vmstate_milkymist_vgafb = {
|
||||||
.name = "milkymist-vgafb",
|
.name = "milkymist-vgafb",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = vgafb_post_load,
|
.post_load = vgafb_post_load,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistVgafbState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistVgafbState, R_MAX),
|
||||||
|
|
|
@ -416,9 +416,8 @@ static const VMStateDescription vmstate_tcx = {
|
||||||
.name ="tcx",
|
.name ="tcx",
|
||||||
.version_id = 4,
|
.version_id = 4,
|
||||||
.minimum_version_id = 4,
|
.minimum_version_id = 4,
|
||||||
.minimum_version_id_old = 4,
|
|
||||||
.post_load = vmstate_tcx_post_load,
|
.post_load = vmstate_tcx_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT16(height, TCXState),
|
VMSTATE_UINT16(height, TCXState),
|
||||||
VMSTATE_UINT16(width, TCXState),
|
VMSTATE_UINT16(width, TCXState),
|
||||||
VMSTATE_UINT16(depth, TCXState),
|
VMSTATE_UINT16(depth, TCXState),
|
||||||
|
|
|
@ -263,8 +263,7 @@ static const VMStateDescription vmstate_dma = {
|
||||||
.name ="sparc32_dma",
|
.name ="sparc32_dma",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 2,
|
.minimum_version_id = 2,
|
||||||
.minimum_version_id_old = 2,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32_ARRAY(dmaregs, DMAState, DMA_REGS),
|
VMSTATE_UINT32_ARRAY(dmaregs, DMAState, DMA_REGS),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
|
|
@ -327,8 +327,7 @@ static const VMStateDescription vmstate_iommu = {
|
||||||
.name ="iommu",
|
.name ="iommu",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 2,
|
.minimum_version_id = 2,
|
||||||
.minimum_version_id_old = 2,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32_ARRAY(regs, IOMMUState, IOMMU_NREGS),
|
VMSTATE_UINT32_ARRAY(regs, IOMMUState, IOMMU_NREGS),
|
||||||
VMSTATE_UINT64(iostart, IOMMUState),
|
VMSTATE_UINT64(iostart, IOMMUState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -52,10 +52,9 @@ static const VMStateDescription vmstate_i2c_bus = {
|
||||||
.name = "i2c_bus",
|
.name = "i2c_bus",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.pre_save = i2c_bus_pre_save,
|
.pre_save = i2c_bus_pre_save,
|
||||||
.post_load = i2c_bus_post_load,
|
.post_load = i2c_bus_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(saved_address, I2CBus),
|
VMSTATE_UINT8(saved_address, I2CBus),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
@ -194,9 +193,8 @@ const VMStateDescription vmstate_i2c_slave = {
|
||||||
.name = "I2CSlave",
|
.name = "I2CSlave",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = i2c_slave_post_load,
|
.post_load = i2c_slave_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(address, I2CSlave),
|
VMSTATE_UINT8(address, I2CSlave),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,7 +48,6 @@ static const VMStateDescription vmstate_ich9_smbus = {
|
||||||
.name = "ich9_smb",
|
.name = "ich9_smb",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PCI_DEVICE(dev, struct ICH9SMBState),
|
VMSTATE_PCI_DEVICE(dev, struct ICH9SMBState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -2342,8 +2342,7 @@ static const VMStateDescription vmstate_ide_atapi_gesn_state = {
|
||||||
.name ="ide_drive/atapi/gesn_state",
|
.name ="ide_drive/atapi/gesn_state",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_BOOL(events.new_media, IDEState),
|
VMSTATE_BOOL(events.new_media, IDEState),
|
||||||
VMSTATE_BOOL(events.eject_request, IDEState),
|
VMSTATE_BOOL(events.eject_request, IDEState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
@ -2354,7 +2353,6 @@ static const VMStateDescription vmstate_ide_tray_state = {
|
||||||
.name = "ide_drive/tray_state",
|
.name = "ide_drive/tray_state",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BOOL(tray_open, IDEState),
|
VMSTATE_BOOL(tray_open, IDEState),
|
||||||
VMSTATE_BOOL(tray_locked, IDEState),
|
VMSTATE_BOOL(tray_locked, IDEState),
|
||||||
|
@ -2366,10 +2364,9 @@ static const VMStateDescription vmstate_ide_drive_pio_state = {
|
||||||
.name = "ide_drive/pio_state",
|
.name = "ide_drive/pio_state",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.pre_save = ide_drive_pio_pre_save,
|
.pre_save = ide_drive_pio_pre_save,
|
||||||
.post_load = ide_drive_pio_post_load,
|
.post_load = ide_drive_pio_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(req_nb_sectors, IDEState),
|
VMSTATE_INT32(req_nb_sectors, IDEState),
|
||||||
VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1,
|
VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1,
|
||||||
vmstate_info_uint8, uint8_t),
|
vmstate_info_uint8, uint8_t),
|
||||||
|
@ -2386,9 +2383,8 @@ const VMStateDescription vmstate_ide_drive = {
|
||||||
.name = "ide_drive",
|
.name = "ide_drive",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.post_load = ide_drive_post_load,
|
.post_load = ide_drive_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(mult_sectors, IDEState),
|
VMSTATE_INT32(mult_sectors, IDEState),
|
||||||
VMSTATE_INT32(identify_set, IDEState),
|
VMSTATE_INT32(identify_set, IDEState),
|
||||||
VMSTATE_BUFFER_TEST(identify_data, IDEState, is_identify_set),
|
VMSTATE_BUFFER_TEST(identify_data, IDEState, is_identify_set),
|
||||||
|
@ -2431,8 +2427,7 @@ static const VMStateDescription vmstate_ide_error_status = {
|
||||||
.name ="ide_bus/error",
|
.name ="ide_bus/error",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_INT32(error_status, IDEBus),
|
VMSTATE_INT32(error_status, IDEBus),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
@ -2442,8 +2437,7 @@ const VMStateDescription vmstate_ide_bus = {
|
||||||
.name = "ide_bus",
|
.name = "ide_bus",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT8(cmd, IDEBus),
|
VMSTATE_UINT8(cmd, IDEBus),
|
||||||
VMSTATE_UINT8(unit, IDEBus),
|
VMSTATE_UINT8(unit, IDEBus),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -480,8 +480,7 @@ static const VMStateDescription vmstate_pmac = {
|
||||||
.name = "ide",
|
.name = "ide",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_IDE_BUS(bus, MACIOIDEState),
|
VMSTATE_IDE_BUS(bus, MACIOIDEState),
|
||||||
VMSTATE_IDE_DRIVES(bus.ifs, MACIOIDEState),
|
VMSTATE_IDE_DRIVES(bus.ifs, MACIOIDEState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -332,8 +332,7 @@ static const VMStateDescription vmstate_microdrive = {
|
||||||
.name = "microdrive",
|
.name = "microdrive",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT8(opt, MicroDriveState),
|
VMSTATE_UINT8(opt, MicroDriveState),
|
||||||
VMSTATE_UINT8(stat, MicroDriveState),
|
VMSTATE_UINT8(stat, MicroDriveState),
|
||||||
VMSTATE_UINT8(pins, MicroDriveState),
|
VMSTATE_UINT8(pins, MicroDriveState),
|
||||||
|
|
|
@ -109,8 +109,7 @@ static const VMStateDescription vmstate_ide_mmio = {
|
||||||
.name = "mmio-ide",
|
.name = "mmio-ide",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_IDE_BUS(bus, MMIOState),
|
VMSTATE_IDE_BUS(bus, MMIOState),
|
||||||
VMSTATE_IDE_DRIVES(bus.ifs, MMIOState),
|
VMSTATE_IDE_DRIVES(bus.ifs, MMIOState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -303,7 +303,6 @@ static const VMStateDescription vmstate_adb_kbd = {
|
||||||
.name = "adb_kbd",
|
.name = "adb_kbd",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BUFFER(data, KBDState),
|
VMSTATE_BUFFER(data, KBDState),
|
||||||
VMSTATE_INT32(rptr, KBDState),
|
VMSTATE_INT32(rptr, KBDState),
|
||||||
|
@ -518,7 +517,6 @@ static const VMStateDescription vmstate_adb_mouse = {
|
||||||
.name = "adb_mouse",
|
.name = "adb_mouse",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(buttons_state, MouseState),
|
VMSTATE_INT32(buttons_state, MouseState),
|
||||||
VMSTATE_INT32(last_buttons_state, MouseState),
|
VMSTATE_INT32(last_buttons_state, MouseState),
|
||||||
|
|
|
@ -295,7 +295,6 @@ static const VMStateDescription vmstate_milkymist_softusb = {
|
||||||
.name = "milkymist-softusb",
|
.name = "milkymist-softusb",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistSoftUsbState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistSoftUsbState, R_MAX),
|
||||||
VMSTATE_HID_KEYBOARD_DEVICE(hid_kbd, MilkymistSoftUsbState),
|
VMSTATE_HID_KEYBOARD_DEVICE(hid_kbd, MilkymistSoftUsbState),
|
||||||
|
|
|
@ -169,7 +169,6 @@ static const VMStateDescription vmstate_lm32_pic = {
|
||||||
.name = "lm32-pic",
|
.name = "lm32-pic",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(im, LM32PicState),
|
VMSTATE_UINT32(im, LM32PicState),
|
||||||
VMSTATE_UINT32(ip, LM32PicState),
|
VMSTATE_UINT32(ip, LM32PicState),
|
||||||
|
|
|
@ -381,8 +381,7 @@ static const VMStateDescription vmstate_intctl_cpu = {
|
||||||
.name ="slavio_intctl_cpu",
|
.name ="slavio_intctl_cpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32(intreg_pending, SLAVIO_CPUINTCTLState),
|
VMSTATE_UINT32(intreg_pending, SLAVIO_CPUINTCTLState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
@ -392,9 +391,8 @@ static const VMStateDescription vmstate_intctl = {
|
||||||
.name ="slavio_intctl",
|
.name ="slavio_intctl",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = vmstate_intctl_post_load,
|
.post_load = vmstate_intctl_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_STRUCT_ARRAY(slaves, SLAVIO_INTCTLState, MAX_CPUS, 1,
|
VMSTATE_STRUCT_ARRAY(slaves, SLAVIO_INTCTLState, MAX_CPUS, 1,
|
||||||
vmstate_intctl_cpu, SLAVIO_CPUINTCTLState),
|
vmstate_intctl_cpu, SLAVIO_CPUINTCTLState),
|
||||||
VMSTATE_UINT32(intregm_pending, SLAVIO_INTCTLState),
|
VMSTATE_UINT32(intregm_pending, SLAVIO_INTCTLState),
|
||||||
|
|
|
@ -89,7 +89,6 @@ const VMStateDescription vmstate_ipack_device = {
|
||||||
.name = "ipack_device",
|
.name = "ipack_device",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(slot, IPackDevice),
|
VMSTATE_INT32(slot, IPackDevice),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -629,7 +629,6 @@ static const VMStateDescription vmstate_tpci200 = {
|
||||||
.name = "tpci200",
|
.name = "tpci200",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PCI_DEVICE(dev, TPCI200State),
|
VMSTATE_PCI_DEVICE(dev, TPCI200State),
|
||||||
VMSTATE_BOOL_ARRAY(big_endian, TPCI200State, 3),
|
VMSTATE_BOOL_ARRAY(big_endian, TPCI200State, 3),
|
||||||
|
|
|
@ -266,8 +266,7 @@ static const VMStateDescription vmstate_ecc = {
|
||||||
.name ="ECC",
|
.name ="ECC",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 3,
|
.minimum_version_id = 3,
|
||||||
.minimum_version_id_old = 3,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32_ARRAY(regs, ECCState, ECC_NREGS),
|
VMSTATE_UINT32_ARRAY(regs, ECCState, ECC_NREGS),
|
||||||
VMSTATE_BUFFER(diag, ECCState),
|
VMSTATE_BUFFER(diag, ECCState),
|
||||||
VMSTATE_UINT32(version, ECCState),
|
VMSTATE_UINT32(version, ECCState),
|
||||||
|
|
|
@ -141,7 +141,6 @@ static const VMStateDescription vmstate_lm32_sys = {
|
||||||
.name = "lm32-sys",
|
.name = "lm32-sys",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, LM32SysState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, LM32SysState, R_MAX),
|
||||||
VMSTATE_BUFFER(testname, LM32SysState),
|
VMSTATE_BUFFER(testname, LM32SysState),
|
||||||
|
|
|
@ -617,7 +617,6 @@ static const VMStateDescription vmstate_cuda_timer = {
|
||||||
.name = "cuda_timer",
|
.name = "cuda_timer",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT16(latch, CUDATimer),
|
VMSTATE_UINT16(latch, CUDATimer),
|
||||||
VMSTATE_UINT16(counter_value, CUDATimer),
|
VMSTATE_UINT16(counter_value, CUDATimer),
|
||||||
|
@ -632,7 +631,6 @@ static const VMStateDescription vmstate_cuda = {
|
||||||
.name = "cuda",
|
.name = "cuda",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(a, CUDAState),
|
VMSTATE_UINT8(a, CUDAState),
|
||||||
VMSTATE_UINT8(b, CUDAState),
|
VMSTATE_UINT8(b, CUDAState),
|
||||||
|
|
|
@ -719,7 +719,6 @@ static const VMStateDescription vmstate_dbdma_channel = {
|
||||||
.name = "dbdma_channel",
|
.name = "dbdma_channel",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, struct DBDMA_channel, DBDMA_REGS),
|
VMSTATE_UINT32_ARRAY(regs, struct DBDMA_channel, DBDMA_REGS),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
@ -730,7 +729,6 @@ static const VMStateDescription vmstate_dbdma = {
|
||||||
.name = "dbdma",
|
.name = "dbdma",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 2,
|
.minimum_version_id = 2,
|
||||||
.minimum_version_id_old = 2,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_STRUCT_ARRAY(channels, DBDMAState, DBDMA_CHANNELS, 1,
|
VMSTATE_STRUCT_ARRAY(channels, DBDMAState, DBDMA_CHANNELS, 1,
|
||||||
vmstate_dbdma_channel, DBDMA_channel),
|
vmstate_dbdma_channel, DBDMA_channel),
|
||||||
|
|
|
@ -143,7 +143,6 @@ static const VMStateDescription vmstate_milkymist_hpdmc = {
|
||||||
.name = "milkymist-hpdmc",
|
.name = "milkymist-hpdmc",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistHpdmcState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistHpdmcState, R_MAX),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -513,7 +513,6 @@ static const VMStateDescription vmstate_milkymist_pfpu = {
|
||||||
.name = "milkymist-pfpu",
|
.name = "milkymist-pfpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistPFPUState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistPFPUState, R_MAX),
|
||||||
VMSTATE_UINT32_ARRAY(gp_regs, MilkymistPFPUState, 128),
|
VMSTATE_UINT32_ARRAY(gp_regs, MilkymistPFPUState, 128),
|
||||||
|
|
|
@ -400,8 +400,7 @@ static const VMStateDescription vmstate_misc = {
|
||||||
.name ="slavio_misc",
|
.name ="slavio_misc",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32(dummy, MiscState),
|
VMSTATE_UINT32(dummy, MiscState),
|
||||||
VMSTATE_UINT8(config, MiscState),
|
VMSTATE_UINT8(config, MiscState),
|
||||||
VMSTATE_UINT8(aux1, MiscState),
|
VMSTATE_UINT8(aux1, MiscState),
|
||||||
|
|
|
@ -110,8 +110,7 @@ static const VMStateDescription vmstate_lance = {
|
||||||
.name = "pcnet",
|
.name = "pcnet",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 2,
|
.minimum_version_id = 2,
|
||||||
.minimum_version_id_old = 2,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_STRUCT(state, SysBusPCNetState, 0, vmstate_pcnet, PCNetState),
|
VMSTATE_STRUCT(state, SysBusPCNetState, 0, vmstate_pcnet, PCNetState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
|
|
@ -492,7 +492,6 @@ static const VMStateDescription vmstate_milkymist_minimac2_mdio = {
|
||||||
.name = "milkymist-minimac2-mdio",
|
.name = "milkymist-minimac2-mdio",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(last_clk, MilkymistMinimac2MdioState),
|
VMSTATE_INT32(last_clk, MilkymistMinimac2MdioState),
|
||||||
VMSTATE_INT32(count, MilkymistMinimac2MdioState),
|
VMSTATE_INT32(count, MilkymistMinimac2MdioState),
|
||||||
|
@ -509,7 +508,6 @@ static const VMStateDescription vmstate_milkymist_minimac2 = {
|
||||||
.name = "milkymist-minimac2",
|
.name = "milkymist-minimac2",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistMinimac2State, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistMinimac2State, R_MAX),
|
||||||
VMSTATE_UINT16_ARRAY(phy_regs, MilkymistMinimac2State, R_PHY_MAX),
|
VMSTATE_UINT16_ARRAY(phy_regs, MilkymistMinimac2State, R_PHY_MAX),
|
||||||
|
|
|
@ -198,7 +198,6 @@ static const VMStateDescription vmstate_mipsnet = {
|
||||||
.name = "mipsnet",
|
.name = "mipsnet",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(busy, MIPSnetState),
|
VMSTATE_UINT32(busy, MIPSnetState),
|
||||||
VMSTATE_UINT32(rx_count, MIPSnetState),
|
VMSTATE_UINT32(rx_count, MIPSnetState),
|
||||||
|
|
|
@ -95,7 +95,6 @@ static const VMStateDescription vmstate_nvram = {
|
||||||
.name = "nvram",
|
.name = "nvram",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.post_load = nvram_post_load,
|
.post_load = nvram_post_load,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_VARRAY_UINT32(contents, NvRamState, chip_size, 0,
|
VMSTATE_VARRAY_UINT32(contents, NvRamState, chip_size, 0,
|
||||||
|
|
|
@ -96,7 +96,6 @@ static const VMStateDescription vmstate_macio_nvram = {
|
||||||
.name = "macio_nvram",
|
.name = "macio_nvram",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_VBUFFER_UINT32(data, MacIONVRAMState, 0, NULL, 0, size),
|
VMSTATE_VBUFFER_UINT32(data, MacIONVRAMState, 0, NULL, 0, size),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -687,8 +687,7 @@ static const VMStateDescription vmstate_bonito = {
|
||||||
.name = "Bonito",
|
.name = "Bonito",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_PCI_DEVICE(dev, PCIBonitoState),
|
VMSTATE_PCI_DEVICE(dev, PCIBonitoState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
|
|
@ -319,7 +319,6 @@ static const VMStateDescription vmstate_event_facility = {
|
||||||
.name = "vmstate-event-facility",
|
.name = "vmstate-event-facility",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(receive_mask, SCLPEventFacility),
|
VMSTATE_UINT32(receive_mask, SCLPEventFacility),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -69,7 +69,6 @@ static const VMStateDescription vmstate_sclpquiesce = {
|
||||||
.name = "sclpquiesce",
|
.name = "sclpquiesce",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_BOOL(event_pending, SCLPEvent),
|
VMSTATE_BOOL(event_pending, SCLPEvent),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -310,7 +310,6 @@ static const VMStateDescription vmstate_esp_pci_scsi = {
|
||||||
.name = "pciespscsi",
|
.name = "pciespscsi",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PCI_DEVICE(parent_obj, PCIESPState),
|
VMSTATE_PCI_DEVICE(parent_obj, PCIESPState),
|
||||||
VMSTATE_BUFFER_UNSAFE(dma_regs, PCIESPState, 0, 8 * sizeof(uint32_t)),
|
VMSTATE_BUFFER_UNSAFE(dma_regs, PCIESPState, 0, 8 * sizeof(uint32_t)),
|
||||||
|
|
|
@ -560,8 +560,7 @@ const VMStateDescription vmstate_esp = {
|
||||||
.name ="esp",
|
.name ="esp",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 3,
|
.minimum_version_id = 3,
|
||||||
.minimum_version_id_old = 3,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_BUFFER(rregs, ESPState),
|
VMSTATE_BUFFER(rregs, ESPState),
|
||||||
VMSTATE_BUFFER(wregs, ESPState),
|
VMSTATE_BUFFER(wregs, ESPState),
|
||||||
VMSTATE_INT32(ti_size, ESPState),
|
VMSTATE_INT32(ti_size, ESPState),
|
||||||
|
@ -706,7 +705,6 @@ static const VMStateDescription vmstate_sysbus_esp_scsi = {
|
||||||
.name = "sysbusespscsi",
|
.name = "sysbusespscsi",
|
||||||
.version_id = 0,
|
.version_id = 0,
|
||||||
.minimum_version_id = 0,
|
.minimum_version_id = 0,
|
||||||
.minimum_version_id_old = 0,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_STRUCT(esp, SysBusESPState, 0, vmstate_esp, ESPState),
|
VMSTATE_STRUCT(esp, SysBusESPState, 0, vmstate_esp, ESPState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -272,7 +272,6 @@ static const VMStateDescription vmstate_milkymist_memcard = {
|
||||||
.name = "milkymist-memcard",
|
.name = "milkymist-memcard",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_INT32(command_write_ptr, MilkymistMemcardState),
|
VMSTATE_INT32(command_write_ptr, MilkymistMemcardState),
|
||||||
VMSTATE_INT32(response_read_ptr, MilkymistMemcardState),
|
VMSTATE_INT32(response_read_ptr, MilkymistMemcardState),
|
||||||
|
|
|
@ -196,7 +196,6 @@ static const VMStateDescription vmstate_lm32_timer = {
|
||||||
.name = "lm32-timer",
|
.name = "lm32-timer",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PTIMER(ptimer, LM32TimerState),
|
VMSTATE_PTIMER(ptimer, LM32TimerState),
|
||||||
VMSTATE_UINT32(freq_hz, LM32TimerState),
|
VMSTATE_UINT32(freq_hz, LM32TimerState),
|
||||||
|
|
|
@ -295,7 +295,6 @@ static const VMStateDescription vmstate_milkymist_sysctl = {
|
||||||
.name = "milkymist-sysctl",
|
.name = "milkymist-sysctl",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, MilkymistSysctlState, R_MAX),
|
VMSTATE_UINT32_ARRAY(regs, MilkymistSysctlState, R_MAX),
|
||||||
VMSTATE_PTIMER(ptimer0, MilkymistSysctlState),
|
VMSTATE_PTIMER(ptimer0, MilkymistSysctlState),
|
||||||
|
|
|
@ -329,8 +329,7 @@ static const VMStateDescription vmstate_timer = {
|
||||||
.name ="timer",
|
.name ="timer",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 3,
|
.minimum_version_id = 3,
|
||||||
.minimum_version_id_old = 3,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT64(limit, CPUTimerState),
|
VMSTATE_UINT64(limit, CPUTimerState),
|
||||||
VMSTATE_UINT32(count, CPUTimerState),
|
VMSTATE_UINT32(count, CPUTimerState),
|
||||||
VMSTATE_UINT32(counthigh, CPUTimerState),
|
VMSTATE_UINT32(counthigh, CPUTimerState),
|
||||||
|
@ -345,8 +344,7 @@ static const VMStateDescription vmstate_slavio_timer = {
|
||||||
.name ="slavio_timer",
|
.name ="slavio_timer",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 3,
|
.minimum_version_id = 3,
|
||||||
.minimum_version_id_old = 3,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_STRUCT_ARRAY(cputimer, SLAVIO_TIMERState, MAX_CPUS + 1, 3,
|
VMSTATE_STRUCT_ARRAY(cputimer, SLAVIO_TIMERState, MAX_CPUS + 1, 3,
|
||||||
vmstate_timer, CPUTimerState),
|
vmstate_timer, CPUTimerState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -51,8 +51,8 @@ static int usb_device_post_load(void *opaque, int version_id)
|
||||||
}
|
}
|
||||||
if (dev->setup_index < 0 ||
|
if (dev->setup_index < 0 ||
|
||||||
dev->setup_len < 0 ||
|
dev->setup_len < 0 ||
|
||||||
dev->setup_index >= sizeof(dev->data_buf) ||
|
dev->setup_index > dev->setup_len ||
|
||||||
dev->setup_len >= sizeof(dev->data_buf)) {
|
dev->setup_len > sizeof(dev->data_buf)) {
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -63,7 +63,7 @@ const VMStateDescription vmstate_usb_device = {
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.post_load = usb_device_post_load,
|
.post_load = usb_device_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT8(addr, USBDevice),
|
VMSTATE_UINT8(addr, USBDevice),
|
||||||
VMSTATE_INT32(state, USBDevice),
|
VMSTATE_INT32(state, USBDevice),
|
||||||
VMSTATE_INT32(remote_wakeup, USBDevice),
|
VMSTATE_INT32(remote_wakeup, USBDevice),
|
||||||
|
|
|
@ -622,7 +622,7 @@ static const VMStateDescription vmstate_usb_ptr = {
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.post_load = usb_ptr_post_load,
|
.post_load = usb_ptr_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_USB_DEVICE(dev, USBHIDState),
|
VMSTATE_USB_DEVICE(dev, USBHIDState),
|
||||||
VMSTATE_HID_POINTER_DEVICE(hid, USBHIDState),
|
VMSTATE_HID_POINTER_DEVICE(hid, USBHIDState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
@ -633,7 +633,7 @@ static const VMStateDescription vmstate_usb_kbd = {
|
||||||
.name = "usb-kbd",
|
.name = "usb-kbd",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_USB_DEVICE(dev, USBHIDState),
|
VMSTATE_USB_DEVICE(dev, USBHIDState),
|
||||||
VMSTATE_HID_KEYBOARD_DEVICE(hid, USBHIDState),
|
VMSTATE_HID_KEYBOARD_DEVICE(hid, USBHIDState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -540,7 +540,7 @@ static const VMStateDescription vmstate_usb_hub_port = {
|
||||||
.name = "usb-hub-port",
|
.name = "usb-hub-port",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT16(wPortStatus, USBHubPort),
|
VMSTATE_UINT16(wPortStatus, USBHubPort),
|
||||||
VMSTATE_UINT16(wPortChange, USBHubPort),
|
VMSTATE_UINT16(wPortChange, USBHubPort),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
@ -551,7 +551,7 @@ static const VMStateDescription vmstate_usb_hub = {
|
||||||
.name = "usb-hub",
|
.name = "usb-hub",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_USB_DEVICE(dev, USBHubState),
|
VMSTATE_USB_DEVICE(dev, USBHubState),
|
||||||
VMSTATE_STRUCT_ARRAY(ports, USBHubState, NUM_PORTS, 0,
|
VMSTATE_STRUCT_ARRAY(ports, USBHubState, NUM_PORTS, 0,
|
||||||
vmstate_usb_hub_port, USBHubPort),
|
vmstate_usb_hub_port, USBHubPort),
|
||||||
|
|
|
@ -716,7 +716,7 @@ static const VMStateDescription vmstate_usb_msd = {
|
||||||
.name = "usb-storage",
|
.name = "usb-storage",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_USB_DEVICE(dev, MSDState),
|
VMSTATE_USB_DEVICE(dev, MSDState),
|
||||||
VMSTATE_UINT32(mode, MSDState),
|
VMSTATE_UINT32(mode, MSDState),
|
||||||
VMSTATE_UINT32(scsi_len, MSDState),
|
VMSTATE_UINT32(scsi_len, MSDState),
|
||||||
|
|
|
@ -422,8 +422,7 @@ static const VMStateDescription vmstate_uhci_port = {
|
||||||
.name = "uhci port",
|
.name = "uhci port",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT16(ctrl, UHCIPort),
|
VMSTATE_UINT16(ctrl, UHCIPort),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
|
@ -444,9 +443,8 @@ static const VMStateDescription vmstate_uhci = {
|
||||||
.name = "uhci",
|
.name = "uhci",
|
||||||
.version_id = 3,
|
.version_id = 3,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.post_load = uhci_post_load,
|
.post_load = uhci_post_load,
|
||||||
.fields = (VMStateField []) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PCI_DEVICE(dev, UHCIState),
|
VMSTATE_PCI_DEVICE(dev, UHCIState),
|
||||||
VMSTATE_UINT8_EQUAL(num_ports_vmstate, UHCIState),
|
VMSTATE_UINT8_EQUAL(num_ports_vmstate, UHCIState),
|
||||||
VMSTATE_STRUCT_ARRAY(ports, UHCIState, NB_PORTS, 1,
|
VMSTATE_STRUCT_ARRAY(ports, UHCIState, NB_PORTS, 1,
|
||||||
|
|
|
@ -662,8 +662,13 @@ static void *migration_thread(void *opaque)
|
||||||
qemu_mutex_lock_iothread();
|
qemu_mutex_lock_iothread();
|
||||||
if (s->state == MIG_STATE_COMPLETED) {
|
if (s->state == MIG_STATE_COMPLETED) {
|
||||||
int64_t end_time = qemu_clock_get_ms(QEMU_CLOCK_REALTIME);
|
int64_t end_time = qemu_clock_get_ms(QEMU_CLOCK_REALTIME);
|
||||||
|
uint64_t transferred_bytes = qemu_ftell(s->file);
|
||||||
s->total_time = end_time - s->total_time;
|
s->total_time = end_time - s->total_time;
|
||||||
s->downtime = end_time - start_time;
|
s->downtime = end_time - start_time;
|
||||||
|
if (s->total_time) {
|
||||||
|
s->mbps = (((double) transferred_bytes * 8.0) /
|
||||||
|
((double) s->total_time)) / 1000;
|
||||||
|
}
|
||||||
runstate_set(RUN_STATE_POSTMIGRATE);
|
runstate_set(RUN_STATE_POSTMIGRATE);
|
||||||
} else {
|
} else {
|
||||||
if (old_vm_running) {
|
if (old_vm_running) {
|
||||||
|
|
|
@ -72,7 +72,6 @@ static const VMStateDescription vmstate_env = {
|
||||||
.name = "env",
|
.name = "env",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = vmstate_env_fields,
|
.fields = vmstate_env_fields,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -86,6 +85,5 @@ const VMStateDescription vmstate_alpha_cpu = {
|
||||||
.name = "cpu",
|
.name = "cpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = vmstate_cpu_fields,
|
.fields = vmstate_cpu_fields,
|
||||||
};
|
};
|
||||||
|
|
|
@ -5,7 +5,6 @@ static const VMStateDescription vmstate_env = {
|
||||||
.name = "env",
|
.name = "env",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(regs, CPULM32State, 32),
|
VMSTATE_UINT32_ARRAY(regs, CPULM32State, 32),
|
||||||
VMSTATE_UINT32(pc, CPULM32State),
|
VMSTATE_UINT32(pc, CPULM32State),
|
||||||
|
@ -26,7 +25,6 @@ const VMStateDescription vmstate_lm32_cpu = {
|
||||||
.name = "cpu",
|
.name = "cpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_STRUCT(env, LM32CPU, 1, vmstate_env, CPULM32State),
|
VMSTATE_STRUCT(env, LM32CPU, 1, vmstate_env, CPULM32State),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
|
|
|
@ -5,7 +5,6 @@ const VMStateDescription vmstate_moxie_cpu = {
|
||||||
.name = "cpu",
|
.name = "cpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(flags, CPUMoxieState),
|
VMSTATE_UINT32(flags, CPUMoxieState),
|
||||||
VMSTATE_UINT32_ARRAY(gregs, CPUMoxieState, 16),
|
VMSTATE_UINT32_ARRAY(gregs, CPUMoxieState, 16),
|
||||||
|
|
|
@ -24,7 +24,6 @@ static const VMStateDescription vmstate_env = {
|
||||||
.name = "env",
|
.name = "env",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32_ARRAY(gpr, CPUOpenRISCState, 32),
|
VMSTATE_UINT32_ARRAY(gpr, CPUOpenRISCState, 32),
|
||||||
VMSTATE_UINT32(sr, CPUOpenRISCState),
|
VMSTATE_UINT32(sr, CPUOpenRISCState),
|
||||||
|
@ -43,7 +42,6 @@ const VMStateDescription vmstate_openrisc_cpu = {
|
||||||
.name = "cpu",
|
.name = "cpu",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_CPU(),
|
VMSTATE_CPU(),
|
||||||
VMSTATE_STRUCT(env, OpenRISCCPU, 1, vmstate_env, CPUOpenRISCState),
|
VMSTATE_STRUCT(env, OpenRISCCPU, 1, vmstate_env, CPUOpenRISCState),
|
||||||
|
|
|
@ -65,7 +65,6 @@ static const VMStateDescription vmstate_simple = {
|
||||||
.name = "test",
|
.name = "test",
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_UINT32(a, TestStruct),
|
VMSTATE_UINT32(a, TestStruct),
|
||||||
VMSTATE_UINT32(b, TestStruct),
|
VMSTATE_UINT32(b, TestStruct),
|
||||||
|
@ -131,8 +130,7 @@ static const VMStateDescription vmstate_versioned = {
|
||||||
.name = "test",
|
.name = "test",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32(a, TestStruct),
|
VMSTATE_UINT32(a, TestStruct),
|
||||||
VMSTATE_UINT32_V(b, TestStruct, 2), /* Versioned field in the middle, so
|
VMSTATE_UINT32_V(b, TestStruct, 2), /* Versioned field in the middle, so
|
||||||
* we catch bugs more easily.
|
* we catch bugs more easily.
|
||||||
|
@ -207,8 +205,7 @@ static const VMStateDescription vmstate_skipping = {
|
||||||
.name = "test",
|
.name = "test",
|
||||||
.version_id = 2,
|
.version_id = 2,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.minimum_version_id_old = 1,
|
.fields = (VMStateField[]) {
|
||||||
.fields = (VMStateField []) {
|
|
||||||
VMSTATE_UINT32(a, TestStruct),
|
VMSTATE_UINT32(a, TestStruct),
|
||||||
VMSTATE_UINT32(b, TestStruct),
|
VMSTATE_UINT32(b, TestStruct),
|
||||||
VMSTATE_UINT32_TEST(c, TestStruct, test_skip),
|
VMSTATE_UINT32_TEST(c, TestStruct, test_skip),
|
||||||
|
|
Loading…
Reference in a new issue