linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Andrea Arcangeli <aarcange@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>, linux-mm@kvack.org
Cc: "Dr. David Alan Gilbert" <dgilbert@redhat.com>,
	Maxime Coquelin <maxime.coquelin@redhat.com>,
	Mike Rapoport <rppt@linux.vnet.ibm.com>,
	Mike Kravetz <mike.kravetz@oracle.com>,
	Alexey Perevalov <a.perevalov@samsung.com>
Subject: [PATCH 3/6] userfaultfd: selftest: explicit failure if the SIGBUS test failed
Date: Wed,  2 Aug 2017 18:51:42 +0200	[thread overview]
Message-ID: <20170802165145.22628-4-aarcange@redhat.com> (raw)
In-Reply-To: <20170802165145.22628-1-aarcange@redhat.com>

Showing zero in the output isn't very self explanatory as a successful
result. Show a more explicit error output if the test fails.

Signed-off-by: Andrea Arcangeli <aarcange@redhat.com>
---
 tools/testing/selftests/vm/userfaultfd.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tools/testing/selftests/vm/userfaultfd.c b/tools/testing/selftests/vm/userfaultfd.c
index d07156de55e8..34838d5b33f3 100644
--- a/tools/testing/selftests/vm/userfaultfd.c
+++ b/tools/testing/selftests/vm/userfaultfd.c
@@ -986,7 +986,9 @@ static int userfaultfd_sig_test(void)
 		return 1;
 
 	printf("done.\n");
-	printf(" Signal test userfaults: %ld\n", userfaults);
+	if (userfaults)
+		fprintf(stderr, "Signal test failed, userfaults: %ld\n",
+			userfaults);
 	close(uffd);
 	return userfaults != 0;
 }

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  parent reply	other threads:[~2017-08-02 16:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-02 16:51 [PATCH 0/6] userfaultfd updates for v4.13-rc3 Andrea Arcangeli
2017-08-02 16:51 ` [PATCH 1/6] userfaultfd: hugetlbfs: remove superfluous page unlock in VM_SHARED case Andrea Arcangeli
2017-08-02 17:12   ` Mike Kravetz
2017-08-02 16:51 ` [PATCH 2/6] userfaultfd: selftest: exercise UFFDIO_COPY/ZEROPAGE -EEXIST Andrea Arcangeli
2017-08-02 21:33   ` Mike Kravetz
2017-08-02 16:51 ` Andrea Arcangeli [this message]
2017-08-02 16:51 ` [PATCH 4/6] userfaultfd: call userfaultfd_unmap_prep only if __split_vma succeeds Andrea Arcangeli
2017-08-02 16:51 ` [PATCH 5/6] userfaultfd: provide pid in userfault msg Andrea Arcangeli
2017-08-02 16:51 ` [PATCH 6/6] userfaultfd: provide pid in userfault msg - add feat union Andrea Arcangeli
2017-08-02 21:29 ` [PATCH 0/6] userfaultfd updates for v4.13-rc3 Andrew Morton
2017-08-02 22:27   ` Andrea Arcangeli

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=20170802165145.22628-4-aarcange@redhat.com \
    --to=aarcange@redhat.com \
    --cc=a.perevalov@samsung.com \
    --cc=akpm@linux-foundation.org \
    --cc=dgilbert@redhat.com \
    --cc=linux-mm@kvack.org \
    --cc=maxime.coquelin@redhat.com \
    --cc=mike.kravetz@oracle.com \
    --cc=rppt@linux.vnet.ibm.com \
    /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;
as well as URLs for NNTP newsgroup(s).