summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorAnh Tuan Phan <tuananhlfc@gmail.com>2023-03-24 05:14:15 +0300
committerShuah Khan <skhan@linuxfoundation.org>2023-03-31 18:18:45 +0300
commitf1594bc676579133a3cd906d7d27733289edfb86 (patch)
tree9f48cb8bb0cc173d8b7cc8c969ae22464eb1738f /tools
parent05107edc910135d27fe557267dc45be9630bf3dd (diff)
downloadlinux-f1594bc676579133a3cd906d7d27733289edfb86.tar.xz
selftests mount: Fix mount_setattr_test builds failed
When compiling selftests with target mount_setattr I encountered some errors with the below messages: mount_setattr_test.c: In function ‘mount_setattr_thread’: mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type 343 | struct mount_attr attr = { | ^~~~~~~~~~ These errors might be because of linux/mount.h is not included. This patch resolves that issue. Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com> Acked-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/testing/selftests/mount_setattr/mount_setattr_test.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
index 582669ca38e9..c6a8c732b802 100644
--- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
+++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
@@ -18,6 +18,7 @@
#include <grp.h>
#include <stdbool.h>
#include <stdarg.h>
+#include <linux/mount.h>
#include "../kselftest_harness.h"