Hi all,
A few years ago, there was an attempt to bring NUMA support to Xen on
ARM, but it got stalled. This patch series revives that work to get
proper NUMA support up and running on ARM.
Note that this series only covers Device Tree environments for now.
ACPI support is skipped and left for the future.
Also, I've put the NUMA DT helper functions into the common code,
so that other DT-based architectures like RISC-V or PPC can easily
reuse them later.
The series is structured as follows:
- Patches 01-09: Basic Device Tree parsing and NUMA initialization
for ARM.
- Patches 10-12: Toolstack enhancements to generate vNUMA device
tree nodes for guests.
- Patches 13-20: Dom0 memory and vCPU allocation adjustments based
on node affinity.
- Patch 21: Update documentation for the 'numa' and 'dom0_nodes'
command-line options.
Thanks,
Hirokazu Takahashi
Hirokazu Takahashi (21):
xen/device-tree: Initial framework for Device Tree NUMA support
xen/arm: NUMA helper functions via Device Tree helpers
xen/arm: Introduce CONFIG_DEVICE_TREE_NUMA config option
xen/arm: Configure NUMA affinity for populated memory banks
xen/arm: Map populated CPUs to their respective NUMA nodes
xen/device-tree: Read NUMA node distance from Device Tree
'distance-map'
xen/device-tree: Parse 'cpu-map' node for CPU topology exploration
xen/sched: Link CPU topology to scheduler and display via xl info
xen/common: Allow building ARM32 Xen with CONFIG_NUMA
tools/libxl: Add 'numa-node-id' property to DomU memory nodes
tools/libxl: Add 'numa-node-id' property to DomU CPU nodes
tools/libxl: Create 'distance-map' node in DomU Device Tree
xen/arm: Introduce dom0_nodes boot command option
xen/arm: Set Domain-0 node affinity from dom0_nodes option
xen/arm: Reflect physical NUMA node IDs in Dom0 memory DT nodes
xen/arm: Balance Dom0 vCPU assignment across NUMA nodes
xen/arm: Export Dom0 vCPU-to-NUMA node mapping to Device Tree
xen/arm: Generate distance-map node for Dom0 Device Tree
xen/arm: Balance Dom0 memory allocation across allowed NUMA nodes
xen/arm: Use dedicated function for Static SHM Device Tree creation
xen/arm: Support numa and numa_nodes boot options
docs/misc/xen-command-line.pandoc | 9 +-
tools/libs/light/libxl_arm.c | 134 +++++++-
xen/arch/arm/Makefile | 1 +
xen/arch/arm/domain_build.c | 428 +++++++++++++++++++-------
xen/arch/arm/include/asm/numa.h | 19 ++
xen/arch/arm/include/asm/processor.h | 6 +-
xen/arch/arm/numa.c | 62 ++++
xen/arch/arm/setup.c | 4 +
xen/arch/arm/smpboot.c | 35 ++-
xen/common/Kconfig | 16 +
xen/common/device-tree/Makefile | 2 +
xen/common/device-tree/bootinfo-fdt.c | 8 +
xen/common/device-tree/cpu_topology.c | 361 ++++++++++++++++++++++
xen/common/device-tree/domain-build.c | 99 +++---
xen/common/device-tree/numa.c | 142 +++++++++
xen/common/numa.c | 2 +-
xen/common/sched/credit2.c | 3 +
xen/common/sysctl.c | 1 +
xen/include/xen/bootinfo.h | 37 +++
xen/include/xen/cpu_topology.h | 45 +++
xen/include/xen/dt-numa.h | 31 ++
xen/include/xen/fdt-domain-build.h | 2 +
22 files changed, 1274 insertions(+), 173 deletions(-)
create mode 100644 xen/arch/arm/include/asm/numa.h
create mode 100644 xen/arch/arm/numa.c
create mode 100644 xen/common/device-tree/cpu_topology.c
create mode 100644 xen/common/device-tree/numa.c
create mode 100644 xen/include/xen/cpu_topology.h
create mode 100644 xen/include/xen/dt-numa.h
--
2.43.0