[lxc-devel] [lxd/master] lxd/qemu: Restrict NUMA layout to x86_64

stgraber on Github lxc-bot at linuxcontainers.org
Sat May 2 19:32:45 UTC 2020


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 511 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20200502/6e889d1b/attachment.bin>
-------------- next part --------------
From e45d492839e3ddcffb034cfa6ff41de45e98b0bb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Sat, 2 May 2020 15:31:42 -0400
Subject: [PATCH] lxd/qemu: Restrict NUMA layout to x86_64
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

At least on aarch64, core_id doesn't appear to be supported.
So this will need more testing and potentially a different approach on
some architectures.

Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
 lxd/instance/drivers/driver_qemu_templates.go | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lxd/instance/drivers/driver_qemu_templates.go b/lxd/instance/drivers/driver_qemu_templates.go
index b2f8f9def5..b56e0a7238 100644
--- a/lxd/instance/drivers/driver_qemu_templates.go
+++ b/lxd/instance/drivers/driver_qemu_templates.go
@@ -155,6 +155,7 @@ sockets = "{{.cpuSockets}}"
 cores = "{{.cpuCores}}"
 threads = "{{.cpuThreads}}"
 
+{{if eq .architecture "x86_64" -}}
 {{range $index, $element := .cpuNumaNodes}}
 [numa]
 type = "node"
@@ -169,6 +170,7 @@ socket-id = "{{.socket}}"
 core-id = "{{.core}}"
 thread-id = "{{.thread}}"
 {{end}}
+{{end}}
 `))
 
 var qemuControlSocket = template.Must(template.New("qemuControlSocket").Parse(`


More information about the lxc-devel mailing list