[LTP] [PATCH v2 2/3] ioperm01: skip test if kernel is locked down
Erico Nunes
ernunes@redhat.com
Tue Jul 28 18:22:06 CEST 2020
ioperm is restricted under kernel lockdown.
Signed-off-by: Erico Nunes <ernunes@redhat.com>
---
v2:
- update to skip the test here rather than relying on the helper
function to skip.
---
testcases/kernel/syscalls/ioperm/ioperm01.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/testcases/kernel/syscalls/ioperm/ioperm01.c b/testcases/kernel/syscalls/ioperm/ioperm01.c
index 4c5c0e6ea..c25baa678 100644
--- a/testcases/kernel/syscalls/ioperm/ioperm01.c
+++ b/testcases/kernel/syscalls/ioperm/ioperm01.c
@@ -42,6 +42,10 @@ static void verify_ioperm(void)
static void setup(void)
{
+ /* ioperm is restricted under kernel lockdown. */
+ if (tst_lockdown_enabled())
+ tst_brk(TCONF, "Kernel is locked down, skip this test");
+
/*
* The value of IO_BITMAP_BITS (include/asm-i386/processor.h) changed
* from kernel 2.6.8 to permit 16-bits ioperm
--
2.26.2
More information about the ltp
mailing list