Whamcloud - gitweb
LU-14291 lustre: clean up lustre_eacl.h and make server-only 26/41126/4
authorMr NeilBrown <neilb@suse.de>
Thu, 29 Oct 2020 05:13:36 +0000 (16:13 +1100)
committerOleg Drokin <green@whamcloud.com>
Tue, 16 Mar 2021 18:17:12 +0000 (18:17 +0000)
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 <neilb@suse.de>
Change-Id: If1a3d908bf8357041c38ab9d335efa1e051cef16
Reviewed-on: https://review.whamcloud.com/41126
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/include/lustre_eacl.h
lustre/llite/llite_internal.h
lustre/llite/xattr.c
lustre/obdclass/acl.c
lustre/ptlrpc/nodemap_handler.c

index 4f83a93..68062dc 100644 (file)
 # include <linux/fs.h>
 # include <lustre_compat.h>
 
-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;
index 8b3d527..d8a1d9b 100644 (file)
@@ -34,7 +34,6 @@
 #define LLITE_INTERNAL_H
 #include <obd.h>
 #include <lustre_disk.h>  /* for s2sbi */
-#include <lustre_eacl.h>
 #include <lustre_linkea.h>
 
 /* for struct cl_lock_descr and struct cl_io */
index 0a395bc..8aeb09e 100644 (file)
@@ -42,7 +42,6 @@
 
 #include <obd_support.h>
 #include <lustre_dlm.h>
-#include <lustre_eacl.h>
 #include <lustre_swab.h>
 
 #include "llite_internal.h"
index bdf96ca..2ff7396 100644 (file)
 #include <lustre_acl.h>
 #include <lustre_eacl.h>
 #include <obd_support.h>
-#ifdef HAVE_SERVER_SUPPORT
-# include <lustre_idmap.h>
-# include <md_object.h>
-#endif /* HAVE_SERVER_SUPPORT */
+#include <lustre_idmap.h>
+#include <md_object.h>
 
 #ifdef CONFIG_LUSTRE_FS_POSIX_ACL
 
index 5fc80bf..4e16ea7 100644 (file)
@@ -31,7 +31,6 @@
 #include <uapi/linux/lnet/nidstr.h>
 #include <lustre_net.h>
 #include <lustre_acl.h>
-#include <lustre_eacl.h>
 #include <obd_class.h>
 #include "nodemap_internal.h"