[PATCH-for-11.1 00/10] migration: Reduce uses of target-specific macros

Philippe Mathieu-Daudé posted 10 patches 1 week, 1 day ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260325211728.89204-1-philmd@linaro.org
Maintainers: Paolo Bonzini <pbonzini@redhat.com>, Zhao Liu <zhao1.liu@intel.com>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Jiaxun Yang <jiaxun.yang@flygoat.com>, Palmer Dabbelt <palmer@dabbelt.com>, Alistair Francis <alistair.francis@wdc.com>, Weiwei Li <liwei1518@gmail.com>, Daniel Henrique Barboza <daniel.barboza@oss.qualcomm.com>, Liu Zhiwei <zhiwei_liu@linux.alibaba.com>, Chao Liu <chao.liu.zevorn@gmail.com>, Peter Xu <peterx@redhat.com>, Fabiano Rosas <farosas@suse.de>, Michael Rolnik <mrolnik@gmail.com>, Song Gao <gaosong@loongson.cn>, Huacai Chen <chenhuacai@kernel.org>, Aurelien Jarno <aurelien@aurel32.net>, Aleksandar Rikalo <arikalo@gmail.com>, Nicholas Piggin <npiggin@gmail.com>, Chinmay Rath <rathc@linux.ibm.com>, Glenn Miles <milesg@linux.ibm.com>, Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>, Artyom Tarasenko <atar4qemu@gmail.com>
configs/targets/i386-softmmu.mak     |  1 +
configs/targets/mips-softmmu.mak     |  1 +
configs/targets/mips64-softmmu.mak   |  1 +
configs/targets/mips64el-softmmu.mak |  1 +
configs/targets/mipsel-softmmu.mak   |  1 +
configs/targets/ppc-softmmu.mak      |  1 +
configs/targets/ppc64-softmmu.mak    |  1 +
configs/targets/riscv32-softmmu.mak  |  1 +
configs/targets/riscv64-softmmu.mak  |  1 +
configs/targets/sparc-softmmu.mak    |  1 +
configs/targets/sparc64-softmmu.mak  |  1 +
configs/targets/x86_64-softmmu.mak   |  1 +
include/migration/cpu.h              | 59 ++++++----------------------
include/migration/vmstate.h          | 22 ++---------
migration/vmstate.c                  |  4 --
target/avr/machine.c                 |  3 +-
target/i386/machine.c                |  8 +++-
target/loongarch/machine.c           |  2 +-
target/mips/system/machine.c         | 14 ++++++-
target/ppc/machine.c                 |  1 +
target/sparc/machine.c               | 24 +++++++----
scripts/make-config-poison.sh        |  1 +
target/avr/meson.build               |  3 +-
target/loongarch/meson.build         |  2 +-
24 files changed, 67 insertions(+), 88 deletions(-)
[PATCH-for-11.1 00/10] migration: Reduce uses of target-specific macros
Posted by Philippe Mathieu-Daudé 1 week, 1 day ago
For the single binary (read heterogeneous emulation) project
we are trying to remove the uses of the 'target_ulong' type
in common code (or code that should be common code but is
compiled a target-specific one).

This series aims to reduce the use of migration target-specific
macros. Since there is still a lot of work to be done, we
introduce the TARGET_USING_LEGACY_MIGRATION_VMSTATE_UINTTL_API
definition to protect the targets which are already not using
these legacy migration macros.

Except for the SPARC targets, there should be no functional
change.

Philippe Mathieu-Daudé (10):
  target/avr: Avoid target-specific migration headers in machine.c
  target/loongarch: Avoid target-specific migration headers in machine.c
  migration: Revert "Add VMSTATE_UINTTL_2DARRAY()"
  migration: Remove unused target-specific macros
  target/sparc: Inline qemu_get/put_betl()
  target/mips: Inline qemu_get/put_betls()
  target/i386: Expand VMSTATE_UINTTL_SUB_ARRAY for APX registers
  target/i386: Inline VMSTATE_UINTTL_SUB_ARRAY() macro
  target/sparc: Replace VMSTATE_VARRAY_MULTIPLY -> VMSTATE_UINTTL_ARRAY
  migration: Restrict legacy VMSTATE_UINTTL() macros to few targets

 configs/targets/i386-softmmu.mak     |  1 +
 configs/targets/mips-softmmu.mak     |  1 +
 configs/targets/mips64-softmmu.mak   |  1 +
 configs/targets/mips64el-softmmu.mak |  1 +
 configs/targets/mipsel-softmmu.mak   |  1 +
 configs/targets/ppc-softmmu.mak      |  1 +
 configs/targets/ppc64-softmmu.mak    |  1 +
 configs/targets/riscv32-softmmu.mak  |  1 +
 configs/targets/riscv64-softmmu.mak  |  1 +
 configs/targets/sparc-softmmu.mak    |  1 +
 configs/targets/sparc64-softmmu.mak  |  1 +
 configs/targets/x86_64-softmmu.mak   |  1 +
 include/migration/cpu.h              | 59 ++++++----------------------
 include/migration/vmstate.h          | 22 ++---------
 migration/vmstate.c                  |  4 --
 target/avr/machine.c                 |  3 +-
 target/i386/machine.c                |  8 +++-
 target/loongarch/machine.c           |  2 +-
 target/mips/system/machine.c         | 14 ++++++-
 target/ppc/machine.c                 |  1 +
 target/sparc/machine.c               | 24 +++++++----
 scripts/make-config-poison.sh        |  1 +
 target/avr/meson.build               |  3 +-
 target/loongarch/meson.build         |  2 +-
 24 files changed, 67 insertions(+), 88 deletions(-)

-- 
2.53.0