summaryrefslogtreecommitdiff
path: root/tools/testing
diff options
context:
space:
mode:
authorAndy Lutomirski <luto@kernel.org>2020-06-26 20:21:15 +0300
committerThomas Gleixner <tglx@linutronix.de>2020-07-01 11:00:26 +0300
commita61fa2799ef9bf6c4f54cf7295036577cececc72 (patch)
tree523789cd88752720f6fa9732f4ed245d4dc8d658 /tools/testing
parente4ef7de160c6b12639c4fc49bcacb25b860ac76d (diff)
downloadlinux-a61fa2799ef9bf6c4f54cf7295036577cececc72.tar.xz
selftests/x86/syscall_nt: Clear weird flags after each test
Clear the weird flags before logging to improve strace output -- logging results while, say, TF is set does no one any favors. Signed-off-by: Andy Lutomirski <luto@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lkml.kernel.org/r/907bfa5a42d4475b8245e18b67a04b13ca51ffdb.1593191971.git.luto@kernel.org
Diffstat (limited to 'tools/testing')
-rw-r--r--tools/testing/selftests/x86/syscall_nt.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/x86/syscall_nt.c b/tools/testing/selftests/x86/syscall_nt.c
index f060534b66a0..5fc82b9cebed 100644
--- a/tools/testing/selftests/x86/syscall_nt.c
+++ b/tools/testing/selftests/x86/syscall_nt.c
@@ -59,6 +59,7 @@ static void do_it(unsigned long extraflags)
set_eflags(get_eflags() | extraflags);
syscall(SYS_getpid);
flags = get_eflags();
+ set_eflags(X86_EFLAGS_IF | X86_EFLAGS_FIXED);
if ((flags & extraflags) == extraflags) {
printf("[OK]\tThe syscall worked and flags are still set\n");
} else {