[PATCH v2 0/7] Improve traces on migration failure due to cpreg number mismatch

Eric Auger posted 7 patches 1 month, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260303143928.1747116-1-eric.auger@redhat.com
Maintainers: Peter Xu <peterx@redhat.com>, Fabiano Rosas <farosas@suse.de>, Peter Maydell <peter.maydell@linaro.org>, Paolo Bonzini <pbonzini@redhat.com>, Pedro Barbuda <pbarbuda@microsoft.com>, Mohamed Mediouni <mohamed@unpredictable.fr>
There is a newer version of this series
include/migration/vmstate.h |  10 ++++
target/arm/kvm_arm.h        |   8 +++
target/arm/helper.c         |   5 --
target/arm/kvm-stub.c       |   5 ++
target/arm/kvm.c            |   9 +--
target/arm/machine.c        | 112 ++++++++++++++++++++++++++++++------
target/arm/whpx/whpx-all.c  |   7 ---
target/arm/trace-events     |   3 +
8 files changed, 123 insertions(+), 36 deletions(-)
[PATCH v2 0/7] Improve traces on migration failure due to cpreg number mismatch
Posted by Eric Auger 1 month, 1 week ago
This series comes as a follow-up of discussions held in
[PATCH v6 00/11] Mitigation of "failed to load
cpu:cpreg_vmstate_array_len" migration failures
(https://lore.kernel.org/all/20260126165445.3033335-1-eric.auger@redhat.com/)

It only covers the improvement of the traces. Actual mitigations
are handled in a follow-up series:
[PATCH v7 0/7] Mitigation of "failed to load cpu:cpreg_vmstate_array_len"
migration failures
(https://lore.kernel.org/all/20260302103640.1362564-1-eric.auger@redhat.com/)

When the number of CPU registers received in an incoming migration
stream is bigger than the number of CPU registers seen by the
destination we currently get the following error:

"failed to load cpu:cpreg_vmstate_array_len"

This series removes this cryptic message and explicitly outputs
which spurious registers cause the failures.

---

Available at:
https://github.com/eauger/qemu/tree/cpreg_vmstate_array_len_traces_v2_mitig_v2

v1 -> v2:
- Tool all comments from Peter on v1. See individual history logs
- Also added last patch which was previously included in the follow-up
  mitigation series ([PATCH v7 0/7] Mitigation of "failed to load
  cpu:cpreg_vmstate_array_len" migration failures) but actually belongs
  to those functional changes.


Eric Auger (7):
  vmstate: Introduce VMSTATE_VARRAY_INT32_ALLOC
  target/arm/machine: Use VMSTATE_VARRAY_INT32_ALLOC for cpreg arrays
  target/arm/kvm: Export kvm_print_register_name()
  target/arm/kvm: Tweak print_register_name() for arm64 system register
  target/arm/machine: Trace cpreg names which do not match on migration
  target/arm/machine: Trace all register mismatches
  target/arm/machine: Fix detection of unknown incoming cpregs

 include/migration/vmstate.h |  10 ++++
 target/arm/kvm_arm.h        |   8 +++
 target/arm/helper.c         |   5 --
 target/arm/kvm-stub.c       |   5 ++
 target/arm/kvm.c            |   9 +--
 target/arm/machine.c        | 112 ++++++++++++++++++++++++++++++------
 target/arm/whpx/whpx-all.c  |   7 ---
 target/arm/trace-events     |   3 +
 8 files changed, 123 insertions(+), 36 deletions(-)

-- 
2.53.0