diff options
| author | Stefan Hajnoczi <stefanha@redhat.com> | 2025-06-16 13:14:42 -0400 |
|---|---|---|
| committer | Stefan Hajnoczi <stefanha@redhat.com> | 2025-06-16 13:14:42 -0400 |
| commit | 0bc0e92be50058bc3b881b0d5051206b015a3fa7 (patch) | |
| tree | f53256e046ad2abd53c2b0060770a9c54e19ff8e /hw/arm/boot.c | |
| parent | a6f02277595136832c9e9bcaf447ab574f7b1128 (diff) | |
| parent | 5ad2b1f443a96444cf3e7a2fbe17aae696201012 (diff) | |
| download | focaccia-qemu-0bc0e92be50058bc3b881b0d5051206b015a3fa7.tar.gz focaccia-qemu-0bc0e92be50058bc3b881b0d5051206b015a3fa7.zip | |
Merge tag 'pull-target-arm-20250616' of https://git.linaro.org/people/pmaydell/qemu-arm into staging
target-arm queue: * hw/arm/virt: Check bypass iommu is not set for iommu-map DT property * tests/functional: Add a test for the realview-eb-mpcore machine * qemu-options.hx: Fix reversed description of icount sleep behavior * target/arm: Define raw write for PMU CLR registers * docs/interop: convert qed_spec.txt to reStructuredText format * hw/arm: make cpu targeted by arm_load_kernel the primary CPU. * hw/intc/arm_gic: introduce a first-cpu-index property * hw/arm/mps2: Configure the AN500 CPU with 16 MPU regions * linux-user/arm: Fix return value of SYS_cacheflush # -----BEGIN PGP SIGNATURE----- # # iQJNBAABCAA3FiEE4aXFk81BneKOgxXPPCUl7RQ2DN4FAmhQJLgZHHBldGVyLm1h # eWRlbGxAbGluYXJvLm9yZwAKCRA8JSXtFDYM3k+8EACPyIt6Tie/0kuTXG85r06P # Iqlp59ENb4HNB43bOBlLqNNJydx1GplKnDeDVsz4MyjhtFTZ3xvY+52IbDOgb3YL # 66uJfu1VgdnYoKOpfi3hEr9PM9QxNkENF/3+Fokn+X5tHzhNY4eo/RREQfz2tKJ5 # aKKvzmcZNYwqFLn8TKCNaAfjmqrdwVpuF+rt//4hGULZGwatt8qmlsXWLstozTAz # SPx0utJfvblHj6a+49e0lXaL+xU5yho2J01OiNHrIGtED5Oq2Wmj/q0SV3qPiLDH # hchuDXT71shE2JYoVeINaQpjRWzQNSPXvnEl9SyJ3Ghzop3sOZqE2iPVslvO0l5R # rfrbR2rLnGcRPOwgntGnSMHiW+DH9ldhMUp7UvhlU3/5MJmWX2jpDfZJPsmmdyFH # Evrf64yMO7JlLMQSMkTISZampz8aUgdlgrmQDJ4kGpdkp3GWqLE93eQGHCU16k2j # PzjGxCIeOED4HEeGG3GrPTf0P1dy8WKla2z8ou2ANLqofrKpwFHTuGRl77ETn/bD # 8c11hdS+uJ4Sx/efVPXWQhjCPNwLJL+DlCW0kKbGfTmiBdlcPPzPbrzmPNinVzJs # luSGFzNit7Invfn0KZhy3l0iucMWGPdMDqN0B15RA5fFssdkuxZga5H2kOqCswOe # 3hHo1s5PUbg+x1JAvQvi5g== # =9lWk # -----END PGP SIGNATURE----- # gpg: Signature made Mon 16 Jun 2025 10:05:44 EDT # gpg: using RSA key E1A5C593CD419DE28E8315CF3C2525ED14360CDE # gpg: issuer "peter.maydell@linaro.org" # gpg: Good signature from "Peter Maydell <peter.maydell@linaro.org>" [full] # gpg: aka "Peter Maydell <pmaydell@gmail.com>" [full] # gpg: aka "Peter Maydell <pmaydell@chiark.greenend.org.uk>" [full] # gpg: aka "Peter Maydell <peter@archaic.org.uk>" [unknown] # Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83 15CF 3C25 25ED 1436 0CDE * tag 'pull-target-arm-20250616' of https://git.linaro.org/people/pmaydell/qemu-arm: linux-user/arm: Fix return value of SYS_cacheflush hw/arm/mps2: Configure the AN500 CPU with 16 MPU regions hw/intc/arm_gic: introduce a first-cpu-index property hw/arm: make cpu targeted by arm_load_kernel the primary CPU. docs/interop: convert qed_spec.txt to reStructuredText format target/arm: Define raw write for PMU CLR registers qemu-options.hx: Fix reversed description of icount sleep behavior tests/functional: Add a test for the realview-eb-mpcore machine hw/arm/virt: Check bypass iommu is not set for iommu-map DT property Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'hw/arm/boot.c')
| -rw-r--r-- | hw/arm/boot.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/hw/arm/boot.c b/hw/arm/boot.c index 79afb51b8a..3c93d87985 100644 --- a/hw/arm/boot.c +++ b/hw/arm/boot.c @@ -744,7 +744,7 @@ static void do_cpu_reset(void *opaque) } else { if (arm_feature(env, ARM_FEATURE_EL3) && (info->secure_boot || - (info->secure_board_setup && cs == first_cpu))) { + (info->secure_board_setup && cpu == info->primary_cpu))) { /* Start this CPU in Secure SVC */ target_el = 3; } @@ -752,7 +752,7 @@ static void do_cpu_reset(void *opaque) arm_emulate_firmware_reset(cs, target_el); - if (cs == first_cpu) { + if (cpu == info->primary_cpu) { AddressSpace *as = arm_boot_address_space(cpu, info); cpu_set_pc(cs, info->loader_start); @@ -1239,6 +1239,9 @@ void arm_load_kernel(ARMCPU *cpu, MachineState *ms, struct arm_boot_info *info) info->dtb_filename = ms->dtb; info->dtb_limit = 0; + /* We assume the CPU passed as argument is the primary CPU. */ + info->primary_cpu = cpu; + /* Load the kernel. */ if (!info->kernel_filename || info->firmware_loaded) { arm_setup_firmware_boot(cpu, info); @@ -1288,12 +1291,8 @@ void arm_load_kernel(ARMCPU *cpu, MachineState *ms, struct arm_boot_info *info) object_property_set_int(cpuobj, "psci-conduit", info->psci_conduit, &error_abort); - /* - * Secondary CPUs start in PSCI powered-down state. Like the - * code in do_cpu_reset(), we assume first_cpu is the primary - * CPU. - */ - if (cs != first_cpu) { + /* Secondary CPUs start in PSCI powered-down state. */ + if (ARM_CPU(cs) != info->primary_cpu) { object_property_set_bool(cpuobj, "start-powered-off", true, &error_abort); } |