public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Jeff Layton <jlayton@kernel.org>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] syscalls/statx06: use a fine-grained timestamp for the second time fetch
Date: Thu, 18 May 2023 07:32:16 -0400	[thread overview]
Message-ID: <20230518113216.126233-1-jlayton@kernel.org> (raw)

I have a patchset in progress to change the kernel to sometimes use
fine-grained timestamps for the mtime/ctime. With this, the statx06 test
sometimes fails.

Change the test to grab a fine-grained timestamp for the "after" value,
which fixes the issue.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
---
 testcases/kernel/syscalls/statx/statx06.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testcases/kernel/syscalls/statx/statx06.c b/testcases/kernel/syscalls/statx/statx06.c
index ce82b905bebd..fa75982b0901 100644
--- a/testcases/kernel/syscalls/statx/statx06.c
+++ b/testcases/kernel/syscalls/statx/statx06.c
@@ -109,7 +109,7 @@ static void test_statx(unsigned int test_nr)
 	clock_wait_tick();
 	tc->operation();
 	clock_wait_tick();
-	SAFE_CLOCK_GETTIME(CLOCK_REALTIME_COARSE, &after_time);
+	SAFE_CLOCK_GETTIME(CLOCK_REALTIME, &after_time);
 
 	TEST(statx(AT_FDCWD, TEST_FILE, 0, STATX_ALL, &buff));
 	if (TST_RET != 0) {
-- 
2.40.1


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

             reply	other threads:[~2023-05-18 11:32 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-18 11:32 Jeff Layton [this message]
2023-05-19  9:16 ` [LTP] [PATCH] syscalls/statx06: use a fine-grained timestamp for the second time fetch Yang Xu (Fujitsu)
2023-05-19 10:07   ` Jeff Layton
2023-05-24  8:46     ` Cyril Hrubis
2023-05-24 10:11       ` Jeff Layton
2023-05-24 12:28         ` Petr Vorel
2023-05-25  1:16           ` Yang Xu (Fujitsu)
2023-05-25  5:13             ` Petr Vorel

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=20230518113216.126233-1-jlayton@kernel.org \
    --to=jlayton@kernel.org \
    --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