From: Jan Stancek <jstancek@redhat.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] utimensat_tests.sh: returns EPERM on 4.4.27 and above
Date: Wed, 27 Sep 2017 09:55:13 -0400 (EDT) [thread overview]
Message-ID: <1297668995.23147365.1506520513918.JavaMail.zimbra@redhat.com> (raw)
In-Reply-To: <20170925144624.GB31931@rei>
----- Original Message -----
> Hi!
> > I'd think so too - perhaps a better check is to check for (if 4.4.X,
> > then if > .27) OR (greater than 4.8.0)?
>
> The safest bet would be allowing both for kernels between 4.4 and 4.8.
But also less strict. Why not just add check for 3rd digit?
We already do that in other tests.
diff --git a/testcases/kernel/syscalls/utimensat/utimensat_tests.sh b/testcases/kernel/syscalls/utimensat/utimensat_tests.sh
index 48154d6e65b2..6d7fc5030aff 100755
--- a/testcases/kernel/syscalls/utimensat/utimensat_tests.sh
+++ b/testcases/kernel/syscalls/utimensat/utimensat_tests.sh
@@ -32,13 +32,16 @@ fi
# Starting with 4.8.0 operations on immutable files return EPERM instead of
# EACCES.
-if tst_kvcmp -lt "4.8.0"; then
+# This patch has also been merged to stable 4.4 with
+# b3b4283 ("vfs: move permission checking into notify_change() for utimes(NULL)")
+if tst_kvcmp -ge "4.4.27" -a -lt "4.5.0"; then
+ imaccess=EPERM
+else if tst_kvcmp -lt "4.8.0"; then
imaccess=EACCES
else
imaccess=EPERM
fi
Regards,
Jan
next prev parent reply other threads:[~2017-09-27 13:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-06 11:30 [LTP] [PATCH] utimensat_tests.sh: returns EPERM on 4.4.27 and above naresh.kamboju
2017-09-06 11:54 ` Jan Stancek
2017-09-06 15:29 ` Sumit Semwal
2017-09-25 14:46 ` Cyril Hrubis
2017-09-27 11:39 ` Cyril Hrubis
2017-09-27 13:55 ` Jan Stancek [this message]
2017-09-27 15:12 ` Cyril Hrubis
2017-09-27 22:38 ` Naresh Kamboju
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=1297668995.23147365.1506520513918.JavaMail.zimbra@redhat.com \
--to=jstancek@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