Blame SOURCES/0005-Correct-calculation-of-nr_nodes-and-re-enable-move_p.patch
|
|
c88143 |
From d1bc1653b3f86b8951b876946a94db681764fa2a Mon Sep 17 00:00:00 2001
|
|
|
c88143 |
From: Filipe Brandenburger <filbranden@google.com>
|
|
|
c88143 |
Date: Fri, 15 Jun 2018 14:16:23 -0700
|
|
|
c88143 |
Subject: [PATCH 5/7] Correct calculation of nr_nodes and re-enable move_pages
|
|
|
c88143 |
test
|
|
|
c88143 |
|
|
|
c88143 |
This was pointed out by @bjsprakash in #8.
|
|
|
c88143 |
|
|
|
c88143 |
After the bug is corrected, we can re-enable the test in `make check`,
|
|
|
c88143 |
since most machines these days will have at least two nodes by default.
|
|
|
c88143 |
|
|
|
c88143 |
Travis-CI still fails with this test (one node only available), so keep
|
|
|
c88143 |
skipping it there.
|
|
|
c88143 |
|
|
|
c88143 |
Signed-off-by: Pingfan Liu <piliu@redhat.com>
|
|
|
c88143 |
---
|
|
|
c88143 |
Makefile.am | 1 +
|
|
|
c88143 |
test/move_pages.c | 2 +-
|
|
|
c88143 |
2 files changed, 2 insertions(+), 1 deletion(-)
|
|
|
c88143 |
|
|
|
c88143 |
diff --git a/Makefile.am b/Makefile.am
|
|
|
c88143 |
index 03b0ab6..1c4266d 100644
|
|
|
c88143 |
--- a/Makefile.am
|
|
|
c88143 |
+++ b/Makefile.am
|
|
|
c88143 |
@@ -134,6 +134,7 @@ TESTS = \
|
|
|
c88143 |
test/checkaffinity \
|
|
|
c88143 |
test/checktopology \
|
|
|
c88143 |
test/distance \
|
|
|
c88143 |
+ test/move_pages \
|
|
|
c88143 |
test/nodemap \
|
|
|
c88143 |
test/numademo \
|
|
|
c88143 |
test/regress \
|
|
|
c88143 |
diff --git a/test/move_pages.c b/test/move_pages.c
|
|
|
c88143 |
index 87d9b3e..c5010e2 100644
|
|
|
c88143 |
--- a/test/move_pages.c
|
|
|
c88143 |
+++ b/test/move_pages.c
|
|
|
c88143 |
@@ -28,7 +28,7 @@ int main(int argc, char **argv)
|
|
|
c88143 |
|
|
|
c88143 |
pagesize = getpagesize();
|
|
|
c88143 |
|
|
|
c88143 |
- nr_nodes = numa_max_node();
|
|
|
c88143 |
+ nr_nodes = numa_max_node() + 1;
|
|
|
c88143 |
|
|
|
c88143 |
if (nr_nodes < 2) {
|
|
|
c88143 |
printf("A minimum of 2 nodes is required for this test.\n");
|
|
|
c88143 |
--
|
|
|
c88143 |
2.7.4
|
|
|
c88143 |
|