|
|
Log in / Subscribe / Register

arm64: Add HOTPLUG_PARALLEL support for secondary CPUs

From:  Jinjie Ruan <ruanjinjie-AT-huawei.com>
To:  <catalin.marinas-AT-arm.com>, <will-AT-kernel.org>, <tsbogend-AT-alpha.franken.de>, <pjw-AT-kernel.org>, <palmer-AT-dabbelt.com>, <aou-AT-eecs.berkeley.edu>, <alex-AT-ghiti.fr>, <tglx-AT-kernel.org>, <mingo-AT-redhat.com>, <bp-AT-alien8.de>, <dave.hansen-AT-linux.intel.com>, <hpa-AT-zytor.com>, <peterz-AT-infradead.org>, <kees-AT-kernel.org>, <nathan-AT-kernel.org>, <linusw-AT-kernel.org>, <ojeda-AT-kernel.org>, <ruanjinjie-AT-huawei.com>, <david.kaplan-AT-amd.com>, <lukas.bulwahn-AT-redhat.com>, <ryan.roberts-AT-arm.com>, <maz-AT-kernel.org>, <timothy.hayes-AT-arm.com>, <lpieralisi-AT-kernel.org>, <thuth-AT-redhat.com>, <oupton-AT-kernel.org>, <yeoreum.yun-AT-arm.com>, <miko.lenczewski-AT-arm.com>, <broonie-AT-kernel.org>, <kevin.brodsky-AT-arm.com>, <james.clark-AT-linaro.org>, <tabba-AT-google.com>, <mrigendra.chaubey-AT-gmail.com>, <arnd-AT-arndb.de>, <anshuman.khandual-AT-arm.com>, <x86-AT-kernel.org>, <linux-kernel-AT-vger.kernel.org>, <linux-arm-kernel-AT-lists.infradead.org>, <linux-mips-AT-vger.kernel.org>, <linux-riscv-AT-lists.infradead.org>
Subject:  [PATCH RFC 0/3] arm64: Add HOTPLUG_PARALLEL support for secondary CPUs
Date:  Thu, 11 Jun 2026 21:38:06 +0800
Message-ID:  <20260611133809.3854977-1-ruanjinjie@huawei.com>
Archive-link:  Article

Support for parallel secondary CPU bringup is already utilized by x86,
MIPS, and RISC-V. This patch brings this capability to the arm64
architecture.

Introduce CONFIG_PARALLEL_SMT_PRIMARY_FIRST to avoid primary SMT threads
to boot first constraint.

And Add a 'cpu' parameter to update_cpu_boot_status() to allow updating the
boot status at a per-CPU granularity during parallel bringup.

Rework the global `secondary_data` accessed during early boot into
a per-CPU array. This array maps logical CPU IDs to MPIDR_EL1 values,
enabling the early boot code in head.S to resolve each secondary CPU's
logical ID concurrently.

Jinjie Ruan (3):
  cpu/hotplug: Introduce CONFIG_PARALLEL_SMT_PRIMARY_FIRST
  arm64: smp: Pass CPU ID to update_cpu_boot_status()
  arm64: Add HOTPLUG_PARALLEL support for secondary CPUs

 arch/Kconfig                   |  4 ++++
 arch/arm64/Kconfig             |  1 +
 arch/arm64/include/asm/smp.h   | 14 +++++++++++---
 arch/arm64/kernel/cpufeature.c |  2 +-
 arch/arm64/kernel/head.S       | 23 ++++++++++++++++++++++
 arch/arm64/kernel/smp.c        | 35 ++++++++++++++++++++++++++++++----
 arch/arm64/mm/context.c        |  2 +-
 arch/mips/Kconfig              |  1 +
 arch/riscv/Kconfig             |  1 +
 arch/x86/Kconfig               |  1 +
 kernel/cpu.c                   |  6 +++++-
 11 files changed, 80 insertions(+), 10 deletions(-)

-- 
2.34.1




Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds