[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 13/17] xen/arm: implement numa_node_to_arch_nid for device tree NUMA
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Wei Chen <wei.chen@xxxxxxx>
- Date: Tue, 10 Jan 2023 16:49:26 +0800
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=A2FodgFJQlHN+jEOT1icBJJm4ueZE52nEYnjQXW8aSU=; b=eOcBKIioqxKMO2/XlvTtP7J6moNy8nfLr9220mQ29ujOm8cTT8YKQXZtkC3PID2Y7y+9d40qmDPsNVjnObb96n2Lz9rl5QRwnRJuM5Sgl7ZOmClXvnU5s2qhHZwW/I/lV9YAETaJ4lxclLwh1PulVG+d3EhT3/IoMToyMtaX62+prFI5ULh3gARcl5hMnZh+n4UIs6iREgG6ECu8Gui7zXrh4/0ICWcEBqWLIiBNeE0BLCyXEot2PBxj68S+ZhfjUWrz/G/Y7mq/VWqntoBhpX3w/0//5d9dLLk0iCeHFu5UxH3FEtG8Y+C/35XDHve4foKfV9CUsMxIhjowK5EsHw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Gujj+nN2Tey337Kxfu8v7LxzA1GHQGNgyOxScgmPs4VFlQSubR3PJqovA6W8jzFw1QJvS8hRPa2o4Bl0AseM1RIa2b65qX7NkR0xpaVo7yu8o8TDR8E/cvaiRfoCUVN5mBLp/r7Ss53ed1FA+2fxNeLw9+xPpBInTUxhvZOe4l2oI1W/VkNhNiL9jIrPG+zgGoncNTMpVNNiHcKmCrqAZDAX4ysxhwDzao8/G/gBwulqiC8PEYiXejY/RbeXTDy4h3gfr6QIs3u2dU7dfcFmcEQaizfLQ1+qlkUWQgOUV8VBra5dTs6GaVFb0kGdHG+30ez70uHnSei4VxaADegBZA==
- Cc: <nd@xxxxxxx>, Wei Chen <wei.chen@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
- Delivery-date: Tue, 10 Jan 2023 08:55:19 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Nodisclaimer: true
Device tree based NUMA doesn't have the proximity domain like
ACPI. So we can return node id directly as arch nid.
Signed-off-by: Wei Chen <wei.chen@xxxxxxx>
---
v1 -> v2:
1. Use numa_node_to_arch_nid instead of dummy node_to_pxm.
---
xen/arch/arm/include/asm/numa.h | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/xen/arch/arm/include/asm/numa.h b/xen/arch/arm/include/asm/numa.h
index 34eec9378c..a0b8d7a11c 100644
--- a/xen/arch/arm/include/asm/numa.h
+++ b/xen/arch/arm/include/asm/numa.h
@@ -47,6 +47,15 @@ extern void numa_detect_cpu_node(unsigned int cpu);
extern int numa_device_tree_init(const void *fdt);
extern void numa_init(void);
+/*
+ * Device tree NUMA doesn't have architecural node id.
+ * So we can just return node id as arch nid.
+ */
+static inline unsigned int numa_node_to_arch_nid(nodeid_t n)
+{
+ return n;
+}
+
#else
/* Fake one node for now. See also node_online_map. */
--
2.25.1
|