hugepages: check if numa node exist only if hugepages are enabled

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
This commit is contained in:
Alexandre Derumier 2016-07-29 05:17:33 +02:00 committed by Wolfgang Bumiller
parent 81fff836fb
commit a2a5ffc928

View File

@ -263,7 +263,7 @@ sub config {
my $numa_memory = ($static_memory / $sockets);
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 $cpuend = ($cpustart + $cores - 1) if $cores && $cores > 1;