[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 13/45] esp: fix migration version check in esp_is_version_5()
From: |
Paolo Bonzini |
Subject: |
[PULL 13/45] esp: fix migration version check in esp_is_version_5() |
Date: |
Thu, 17 Jun 2021 11:31:02 +0200 |
From: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Commit 4e78f3bf35 "esp: defer command completion interrupt on incoming data
transfers" added a version check for use with VMSTATE_*_TEST macros to allow
migration from older QEMU versions. Unfortunately the version check fails to
work in its current form since if the VMStateDescription version_id is
incremented, the test returns false and so the fields are not included in the
outgoing migration stream.
Change the version check to use >= rather == to ensure that migration works
correctly when the ESPState VMStateDescription has version_id > 5.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Fixes: 4e78f3bf35 ("esp: defer command completion interrupt on incoming data
transfers")
Message-Id: <20210613102614.5438-1-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
hw/scsi/esp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/scsi/esp.c b/hw/scsi/esp.c
index 3e6f4094fc..8fad87be9d 100644
--- a/hw/scsi/esp.c
+++ b/hw/scsi/esp.c
@@ -1128,7 +1128,7 @@ static bool esp_is_version_5(void *opaque, int version_id)
ESPState *s = ESP(opaque);
version_id = MIN(version_id, s->mig_version_id);
- return version_id == 5;
+ return version_id >= 5;
}
int esp_pre_save(void *opaque)
--
2.31.1
- [PULL 05/45] runstate: Initialize Error * to NULL, (continued)
- [PULL 05/45] runstate: Initialize Error * to NULL, Paolo Bonzini, 2021/06/17
- [PULL 06/45] esp: only assert INTR_DC interrupt flag if selection fails, Paolo Bonzini, 2021/06/17
- [PULL 07/45] esp: only set ESP_RSEQ at the start of the select sequence, Paolo Bonzini, 2021/06/17
- [PULL 11/45] esp: revert 75ef849696 "esp: correctly fill bus id with requested lun", Paolo Bonzini, 2021/06/17
- [PULL 14/45] esp: store lun coming from the MESSAGE OUT phase, Paolo Bonzini, 2021/06/17
- [PULL 15/45] softmmu/physmem: Mark shared anonymous memory RAM_SHARED, Paolo Bonzini, 2021/06/17
- [PULL 16/45] softmmu/physmem: Fix ram_block_discard_range() to handle shared anonymous memory, Paolo Bonzini, 2021/06/17
- [PULL 18/45] util/mmap-alloc: Factor out calculation of the pagesize for the guard page, Paolo Bonzini, 2021/06/17
- [PULL 09/45] esp: handle non-DMA transfers from the target one byte at a time, Paolo Bonzini, 2021/06/17
- [PULL 10/45] esp: ensure PDMA write transfers are flushed from the FIFO to the target immediately, Paolo Bonzini, 2021/06/17
- [PULL 13/45] esp: fix migration version check in esp_is_version_5(),
Paolo Bonzini <=
- [PULL 12/45] esp: correctly accumulate extended messages for PDMA, Paolo Bonzini, 2021/06/17
- [PULL 17/45] softmmu/physmem: Fix qemu_ram_remap() to handle shared anonymous memory, Paolo Bonzini, 2021/06/17
- [PULL 19/45] util/mmap-alloc: Factor out reserving of a memory region to mmap_reserve(), Paolo Bonzini, 2021/06/17
- [PULL 20/45] util/mmap-alloc: Factor out activating of memory to mmap_activate(), Paolo Bonzini, 2021/06/17
- [PULL 22/45] softmmu/memory: Pass ram_flags to memory_region_init_ram_shared_nomigrate(), Paolo Bonzini, 2021/06/17
- [PULL 26/45] util/mmap-alloc: Support RAM_NORESERVE via MAP_NORESERVE under Linux, Paolo Bonzini, 2021/06/17
- [PULL 23/45] softmmu/memory: Pass ram_flags to qemu_ram_alloc() and qemu_ram_alloc_internal(), Paolo Bonzini, 2021/06/17
- [PULL 29/45] qmp: Include "share" property of memory backends, Paolo Bonzini, 2021/06/17
- [PULL 33/45] configure: map x32 to cpu_family x86_64 for meson, Paolo Bonzini, 2021/06/17
- [PULL 36/45] target/i386: Added consistency checks for CR0, Paolo Bonzini, 2021/06/17