From: Mr NeilBrown Date: Thu, 29 Oct 2020 05:13:36 +0000 (+1100) Subject: LU-14291 lustre: clean up lustre_eacl.h and make server-only X-Git-Tag: 2.14.51~19 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=497f520fa341fe2352400c7e5fbc6917b129ff70 LU-14291 lustre: clean up lustre_eacl.h and make server-only lustre_eacl.h contains a number of declarations that are never used: remove them. The declarations which are used are only needed on server-side files, so remove the #include from elsewhere. As obdclass/acl.c is only built server-side, remove the #ifdef HAVE_SERVER_SUPPORT in the file. Test-Parameters: trivial Signed-off-by: Mr NeilBrown Change-Id: If1a3d908bf8357041c38ab9d335efa1e051cef16 Reviewed-on: https://review.whamcloud.com/41126 Reviewed-by: Andreas Dilger Reviewed-by: James Simmons Tested-by: jenkins Tested-by: Maloo --- diff --git a/lustre/include/lustre_eacl.h b/lustre/include/lustre_eacl.h index 4f83a93..68062dc 100644 --- a/lustre/include/lustre_eacl.h +++ b/lustre/include/lustre_eacl.h @@ -48,24 +48,6 @@ # include # include -typedef struct { - __u16 e_tag; - __u16 e_perm; - __u32 e_id; - __u32 e_stat; -} ext_acl_xattr_entry; - -typedef struct { - __u32 a_count; - ext_acl_xattr_entry a_entries[0]; -} ext_acl_xattr_header; - -#define CFS_ACL_XATTR_SIZE(count, prefix) \ - (sizeof(prefix ## _header) + (count) * sizeof(prefix ## _entry)) - -#define CFS_ACL_XATTR_COUNT(size, prefix) \ - (((size) - sizeof(prefix ## _header)) / sizeof(prefix ## _entry)) - #ifdef HAVE_SERVER_SUPPORT struct lu_ucred; struct lu_attr; diff --git a/lustre/llite/llite_internal.h b/lustre/llite/llite_internal.h index 8b3d527..d8a1d9b 100644 --- a/lustre/llite/llite_internal.h +++ b/lustre/llite/llite_internal.h @@ -34,7 +34,6 @@ #define LLITE_INTERNAL_H #include #include /* for s2sbi */ -#include #include /* for struct cl_lock_descr and struct cl_io */ diff --git a/lustre/llite/xattr.c b/lustre/llite/xattr.c index 0a395bc..8aeb09e 100644 --- a/lustre/llite/xattr.c +++ b/lustre/llite/xattr.c @@ -42,7 +42,6 @@ #include #include -#include #include #include "llite_internal.h" diff --git a/lustre/obdclass/acl.c b/lustre/obdclass/acl.c index bdf96ca..2ff7396 100644 --- a/lustre/obdclass/acl.c +++ b/lustre/obdclass/acl.c @@ -41,10 +41,8 @@ #include #include #include -#ifdef HAVE_SERVER_SUPPORT -# include -# include -#endif /* HAVE_SERVER_SUPPORT */ +#include +#include #ifdef CONFIG_LUSTRE_FS_POSIX_ACL diff --git a/lustre/ptlrpc/nodemap_handler.c b/lustre/ptlrpc/nodemap_handler.c index 5fc80bf..4e16ea7 100644 --- a/lustre/ptlrpc/nodemap_handler.c +++ b/lustre/ptlrpc/nodemap_handler.c @@ -31,7 +31,6 @@ #include #include #include -#include #include #include "nodemap_internal.h"