[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241015021841.35713-1-yangyicong@huawei.com>
Date: Tue, 15 Oct 2024 10:18:37 +0800
From: Yicong Yang <yangyicong@...wei.com>
To: <catalin.marinas@....com>, <will@...nel.org>, <sudeep.holla@....com>,
<tglx@...utronix.de>, <peterz@...radead.org>, <mpe@...erman.id.au>,
<linux-arm-kernel@...ts.infradead.org>, <mingo@...hat.com>, <bp@...en8.de>,
<dave.hansen@...ux.intel.com>, <pierre.gondois@....com>,
<dietmar.eggemann@....com>
CC: <linuxppc-dev@...ts.ozlabs.org>, <x86@...nel.org>,
<linux-kernel@...r.kernel.org>, <morten.rasmussen@....com>,
<msuchanek@...e.de>, <gregkh@...uxfoundation.org>, <rafael@...nel.org>,
<jonathan.cameron@...wei.com>, <prime.zeng@...ilicon.com>,
<linuxarm@...wei.com>, <yangyicong@...ilicon.com>, <xuwei5@...wei.com>,
<guohanjun@...wei.com>
Subject: [PATCH v6 0/4] Support SMT control on arm64
From: Yicong Yang <yangyicong@...ilicon.com>
The core CPU control framework supports runtime SMT control which
is not yet supported on arm64. Besides the general vulnerabilities
concerns we want this runtime control on our arm64 server for:
- better single CPU performance in some cases
- saving overall power consumption
This patchset implements it in the following aspects:
- Provides a default topology_is_primary_thread()
- support retrieve SMT thread number on OF based system
- support retrieve SMT thread number on ACPI based system
- select HOTPLUG_SMT for arm64
Tests has been done on our real ACPI based arm64 server and on
ACPI/OF based QEMU VMs.
Change since v5:
- Drop the dependency on CONFIG_SMP since it's always on on arm64, per Pierre
- Avoid potential multiple calls of cpu_smt_set_num_threads() on asymmetric system, per Dietmar
- Detect heterogenous SMT topology and issue a warning for partly support, per Pierre
- Thanks Dietmar for testing, didn't pickup the tag due to code changes. Thanks testing by Pierre
Link: https://lore.kernel.org/linux-arm-kernel/20240806085320.63514-1-yangyicong@huawei.com/
Change since v4:
- Provide a default topology_is_primary_thread() in the framework, Per Will
Link: https://lore.kernel.org/linux-arm-kernel/20231121092602.47792-1-yangyicong@huawei.com/
Change since v3:
- Fix some build and kconfig error reported by kernel test robot <lkp@...el.com>
Link: https://lore.kernel.org/linux-arm-kernel/20231114040110.54590-1-yangyicong@huawei.com/
Change since v2:
- Detect SMT thread number at topology build from ACPI/DT, avoid looping CPUs
- Split patches into ACPI/OF/arch_topology path and enable the kconfig for arm64
Link: https://lore.kernel.org/linux-arm-kernel/20231010115335.13862-1-yangyicong@huawei.com/
Yicong Yang (4):
cpu/SMT: Provide a default topology_is_primary_thread()
arch_topology: Support SMT control for OF based system
arm64: topology: Support SMT control on ACPI based system
arm64: Kconfig: Enable HOTPLUG_SMT
arch/arm64/Kconfig | 1 +
arch/arm64/kernel/topology.c | 61 +++++++++++++++++++++++++++++
arch/powerpc/include/asm/topology.h | 1 +
arch/x86/include/asm/topology.h | 2 +-
drivers/base/arch_topology.c | 21 ++++++++++
include/linux/topology.h | 14 +++++++
6 files changed, 99 insertions(+), 1 deletion(-)
--
2.24.0
Powered by blists - more mailing lists