Skip to content

arm64: spin-table fallback park loop for platforms without PSCI #19

Closed as not planned

Description

@congwang-mk

Part of the arm64 port. Only needed for DT platforms without EL3 firmware (enable-method = "spin-table"). Do not build the common path around this.

Where PSCI is absent, a minimal software park is required:

  • Host parks a CPU with cpu_install_idmap() + cpu_soft_restart(el2_switch, park_pa, mailbox_pa, mpidr, 0) (arch/arm64/kernel/cpu-reset.S), the path kexec already uses, including the hyp-stub HVC_SOFT_RESTART handling. Requires the same cpu_hyp_reset() ordering machine_kexec() has.
  • Park loop, MMU off, in a host-owned page (~30 instructions): load mailbox, compare MPIDR, wfe, on match mov x0, dtb; br entry. With the MMU off data accesses are Device-nGnRnE, so no page tables and no cache maintenance in the loop; the writer needs dcache_clean_poc + sev.
  • The spawn boots its secondaries with stock smp_spin_table and a cpu-release-addr pointing at the host-owned mailbox.
  • Confirm-parked = the CPU has written its MPIDR into a per-CPU "parked" word.
  • No forced halt beyond a plain SGI.

Activity

  1. congwang-mk commented on Sep 21, 2026

    @congwang-mk
    Author

    Closing as won't-do. This fallback only matters on machines without PSCI, and the servers multikernel targets all have it: Arm's server firmware requirements (SystemReady/SBBR) mandate PSCI, which is the path the arm64 port already uses to hold, start and stop CPUs.

    The machines that boot with spin-table are embedded boards, and they mostly lack the GICv3 and ITS the port depends on for the doorbell, tenant mode and MSI routing. Supporting them would also mean rebuilding the software CPU lifecycle (park loop, mailboxes, confirm-parked) that arm64 gets to skip, with nothing available to test it on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    arm64arm64 port

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions