[PATCH 7/7] libnuma: no warnings when there are holes in numbering of nodes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Some machines don't even export their 0th node to acpi tables when there
is no memory installed. This patch removes warning in such cases.

Signed-off-by: Petr Holasek <pholasek@xxxxxxxxxx>
---
 numactl-2.0.8-rc4/distance.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/numactl-2.0.8-rc4/distance.c b/numactl-2.0.8-rc4/distance.c
index 2b48f97..4a26972 100755
--- a/numactl-2.0.8-rc4/distance.c
+++ b/numactl-2.0.8-rc4/distance.c
@@ -64,7 +64,7 @@ static int read_distance_table(void)
 		sprintf(fn, "/sys/devices/system/node/node%d/distance", nd);
 		dfh = fopen(fn, "r");
 		if (!dfh) {
-			if (errno == ENOENT && nd > 0)
+			if (errno == ENOENT)
 				err = 0;
 			if (!err && nd<maxnode)
 				continue;
-- 
1.7.11.4

--
To unsubscribe from this list: send the line "unsubscribe linux-numa" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]     [Devices]

  Powered by Linux