mbox series

[00/23] hw/mips: Remove all uses of &first_cpu

Message ID 20250113004748.41658-1-philmd@linaro.org
Headers show
Series hw/mips: Remove all uses of &first_cpu | expand

Message

Philippe Mathieu-Daudé Jan. 13, 2025, 12:47 a.m. UTC
- Keep references to vCPUs in CPS and MaltaState,
- Refactor the MIPS Bootloader API to take CPU argument
- Access first CPU propagate from machine_init()

Based-on: <20250112215835.29320-1-philmd@linaro.org>
"hw/mips/loongson3: Remove uses of &first_cpu global"

Philippe Mathieu-Daudé (23):
  hw/mips/cps: Keep reference of vCPUs in MIPSCPSState
  hw/mips/malta: Check CPU index instead of using &first_cpu
  hw/mips/boston: Replace bl_gen_write_ulong() -> bl_gen_write_u64()
  hw/mips/bootloader: Propagate CPU env to bootcpu_supports_isa()
  hw/mips/bootloader: Propagate CPU env to bl_gen_nop()
  hw/mips/bootloader: Propagate CPU env to bl_gen_dsll()
  hw/mips/bootloader: Propagate CPU env to bl_gen_jalr()
  hw/mips/bootloader: Propagate CPU env to bl_gen_sw()
  hw/mips/bootloader: Propagate CPU env to bl_gen_sd()
  hw/mips/bootloader: Propagate CPU env to bl_gen_li()
  hw/mips/bootloader: Propagate CPU env to bl_gen_dli()
  hw/mips/bootloader: Propagate CPU env to bl_gen_load_ulong()
  hw/mips/bootloader: Propagate CPU to bl_gen_jump_to()
  hw/mips/bootloader: Propagate CPU to bl_gen_jump_kernel()
  hw/mips/bootloader: Propagate CPU to bl_gen_write_ulong()
  hw/mips/bootloader: Propagate CPU to bl_gen_write_u32()
  hw/mips/bootloader: Propagate CPU to bl_gen_write_u64()
  hw/mips/boston: Propagate CPU to gen_firmware()
  hw/mips/fuloong: Propagate CPU to write_bootloader()
  hw/mips/malta: Keep reference of vCPUs in MaltaState
  hw/mips/malta: Propagate MaltaState to write_bootloader()
  hw/mips/malta: Propagate MaltaState to bl_setup_gt64120_jump_kernel()
  hw/mips/malta: Remove all uses of &first_cpu global

 include/hw/mips/bootloader.h |  14 +++--
 include/hw/mips/cps.h        |   1 +
 hw/mips/bootloader.c         | 103 +++++++++++++++++++----------------
 hw/mips/boston.c             |  21 ++++---
 hw/mips/cps.c                |   4 +-
 hw/mips/fuloong2e.c          |   6 +-
 hw/mips/malta.c              |  59 +++++++++++---------
 7 files changed, 118 insertions(+), 90 deletions(-)