mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-08-08 11:01:39 +00:00
hugepages: check if numa node exist only if hugepages are enabled
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
This commit is contained in:
parent
81fff836fb
commit
a2a5ffc928
@ -263,7 +263,7 @@ sub config {
|
|||||||
my $numa_memory = ($static_memory / $sockets);
|
my $numa_memory = ($static_memory / $sockets);
|
||||||
|
|
||||||
for (my $i = 0; $i < $sockets; $i++) {
|
for (my $i = 0; $i < $sockets; $i++) {
|
||||||
die "host NUMA node$i doesn't exist\n" if ! -d "/sys/devices/system/node/node$i/";
|
die "host NUMA node$i doesn't exist\n" if ! -d "/sys/devices/system/node/node$i/" && $conf->{hugepages};
|
||||||
|
|
||||||
my $cpustart = ($cores * $i);
|
my $cpustart = ($cores * $i);
|
||||||
my $cpuend = ($cpustart + $cores - 1) if $cores && $cores > 1;
|
my $cpuend = ($cpustart + $cores - 1) if $cores && $cores > 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user