From: Li Wang <liwang@redhat.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] move_pages12: fix Warning on system which not support hugepage
Date: Mon, 8 May 2017 13:42:47 +0800 [thread overview]
Message-ID: <20170508054247.994-1-liwang@redhat.com> (raw)
WARNING:
tst_test.c:847: INFO: Timeout per run is 0h 05m 00s
move_pages_support.c:407: CONF: at least 2 allowed NUMA nodes are required
safe_file_ops.c:301: WARN: Failed to close FILE '/proc/sys/vm/nr_hugepages' at move_pages12.c:159: EOPNOTSUPP
Signed-off-by: Li Wang <liwang@redhat.com>
---
testcases/kernel/syscalls/move_pages/move_pages12.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/testcases/kernel/syscalls/move_pages/move_pages12.c b/testcases/kernel/syscalls/move_pages/move_pages12.c
index de00346..f93311f 100644
--- a/testcases/kernel/syscalls/move_pages/move_pages12.c
+++ b/testcases/kernel/syscalls/move_pages/move_pages12.c
@@ -158,7 +158,8 @@ static void setup(void)
static void cleanup(void)
{
- SAFE_FILE_PRINTF(PATH_NR_HUGEPAGES, "%ld", orig_hugepages);
+ if (!access(PATH_HUGEPAGES, F_OK))
+ SAFE_FILE_PRINTF(PATH_NR_HUGEPAGES, "%ld", orig_hugepages);
}
static struct tst_test test = {
--
2.9.3
next reply other threads:[~2017-05-08 5:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-08 5:42 Li Wang [this message]
2017-05-09 12:39 ` [LTP] [PATCH] move_pages12: fix Warning on system which not support hugepage Jan Stancek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170508054247.994-1-liwang@redhat.com \
--to=liwang@redhat.com \
--cc=ltp@lists.linux.it \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox