[LTP] [PATCH 2/2] Remove duplicate include of <sys/mount.h>
Petr Vorel
pvorel@suse.cz
Tue May 3 17:29:48 CEST 2022
<sys/mount.h> is already included by lapi/mount.h.
Fixes: c0cb5d196 ("lapi/mount.h: Include kernel/libc header")
Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
lib/tst_cgroup.c | 1 -
testcases/kernel/syscalls/open/open12.c | 1 -
testcases/kernel/syscalls/pivot_root/pivot_root01.c | 2 --
testcases/kernel/syscalls/statx/statx06.c | 1 -
testcases/kernel/syscalls/umount2/umount2_01.c | 1 -
testcases/kernel/syscalls/umount2/umount2_02.c | 1 -
6 files changed, 7 deletions(-)
diff --git a/lib/tst_cgroup.c b/lib/tst_cgroup.c
index feb5b3d07..081dfa9c6 100644
--- a/lib/tst_cgroup.c
+++ b/lib/tst_cgroup.c
@@ -11,7 +11,6 @@
#include <stddef.h>
#include <stdlib.h>
#include <mntent.h>
-#include <sys/mount.h>
#include "tst_test.h"
#include "lapi/fcntl.h"
diff --git a/testcases/kernel/syscalls/open/open12.c b/testcases/kernel/syscalls/open/open12.c
index 4702d08db..bdf29a9a8 100644
--- a/testcases/kernel/syscalls/open/open12.c
+++ b/testcases/kernel/syscalls/open/open12.c
@@ -24,7 +24,6 @@
#include <stdio.h>
#include <sys/types.h>
#include <sys/wait.h>
-#include <sys/mount.h>
#include <unistd.h>
#include <mntent.h>
#include <errno.h>
diff --git a/testcases/kernel/syscalls/pivot_root/pivot_root01.c b/testcases/kernel/syscalls/pivot_root/pivot_root01.c
index 1fbe8c189..2d80928b7 100644
--- a/testcases/kernel/syscalls/pivot_root/pivot_root01.c
+++ b/testcases/kernel/syscalls/pivot_root/pivot_root01.c
@@ -9,8 +9,6 @@
#include <errno.h>
#include <lapi/syscalls.h>
#include <sched.h>
-
-#include <sys/mount.h>
#include <stdlib.h>
#include "tst_test.h"
diff --git a/testcases/kernel/syscalls/statx/statx06.c b/testcases/kernel/syscalls/statx/statx06.c
index 4a0685a65..28badb038 100644
--- a/testcases/kernel/syscalls/statx/statx06.c
+++ b/testcases/kernel/syscalls/statx/statx06.c
@@ -20,7 +20,6 @@
#define _GNU_SOURCE
#include <stdio.h>
-#include <sys/mount.h>
#include <time.h>
#include "tst_test.h"
diff --git a/testcases/kernel/syscalls/umount2/umount2_01.c b/testcases/kernel/syscalls/umount2/umount2_01.c
index 46a6d59c3..53817bf68 100644
--- a/testcases/kernel/syscalls/umount2/umount2_01.c
+++ b/testcases/kernel/syscalls/umount2/umount2_01.c
@@ -23,7 +23,6 @@
*/
#include <errno.h>
-#include <sys/mount.h>
#include "test.h"
#include "safe_macros.h"
diff --git a/testcases/kernel/syscalls/umount2/umount2_02.c b/testcases/kernel/syscalls/umount2/umount2_02.c
index b23f37b04..f4b228f97 100644
--- a/testcases/kernel/syscalls/umount2/umount2_02.c
+++ b/testcases/kernel/syscalls/umount2/umount2_02.c
@@ -20,7 +20,6 @@
* - succeed when target is a mount point
*/
-#include <sys/mount.h>
#include "lapi/mount.h"
#include "tst_test.h"
--
2.36.0
More information about the ltp
mailing list