All of lore.kernel.org
 help / color / mirror / Atom feed
From: XiaoLi Feng <xifeng@redhat.com>
To: linux-nvdimm@lists.01.org
Cc: Xiaoli Feng <xifeng@redhat.com>
Subject: [PATCH v1] test/dax.sh: correct the pmd pagefault counts generated by dax-pmd
Date: Fri, 20 Mar 2020 10:12:55 +0800	[thread overview]
Message-ID: <20200320021255.1778-1-xifeng@redhat.com> (raw)

From: Xiaoli Feng <xifeng@redhat.com>

For directIO, cannot generate pmd pagefault by pread|pwrite|read|write
if do not map fd to memory. In dax-pmd.c, case 1 and case 4 each only
generate once pmd pagefault. So change the all counts from 10 to 8.

Signed-off-by: Xiaoli Feng <xifeng@redhat.com>
---
 test/dax.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/test/dax.sh b/test/dax.sh
index 3933107..bd08641 100755
--- a/test/dax.sh
+++ b/test/dax.sh
@@ -40,13 +40,13 @@ run_test() {
 	# Fragile hack to double check the kernel services this test
 	# with successful pmd faults. If dax-pmd.c ever changes the
 	# number of times the dax_pmd_fault_done trace point fires the
-	# hack needs to be updated from 10 expected firings and the
+	# hack needs to be updated from 8 expected firings and the
 	# result of success (NOPAGE).
 	count=0
 	rc=1
 	while read -r p; do
 		[[ $p ]] || continue
-		if [ "$count" -lt 10 ]; then
+		if [ "$count" -lt 8 ]; then
 			if [ "$p" != "0x100" ] && [ "$p" != "NOPAGE" ]; then
 				cleanup "$1"
 			fi
@@ -54,7 +54,7 @@ run_test() {
 		count=$((count + 1))
 	done < <(trace-cmd report | awk '{ print $21 }')
 
-	if [ $count -lt 10 ]; then
+	if [ $count -lt 8 ]; then
 		cleanup "$1"
 	fi
 }
-- 
2.18.1
_______________________________________________
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-leave@lists.01.org

             reply	other threads:[~2020-03-20  2:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-20  2:12 XiaoLi Feng [this message]
2020-03-20  2:36 ` [PATCH v1] test/dax.sh: correct the pmd pagefault counts generated by dax-pmd Dan Williams
2020-03-20  3:18   ` Xiaoli Feng
2020-03-20  3:37     ` Dan Williams
2020-03-20  5:16       ` Xiaoli Feng

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=20200320021255.1778-1-xifeng@redhat.com \
    --to=xifeng@redhat.com \
    --cc=linux-nvdimm@lists.01.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.