From fc67e5d18a70ca8b5f01abc89eabdbfc78381f7c Mon Sep 17 00:00:00 2001 From: James Simmons Date: Wed, 22 Nov 2023 10:29:58 -0500 Subject: [PATCH] LU-16739 uapi: restore LUSTRE_NODEMAP_NAME_LENGTH in lustre_disk.h sanity test 400b fails with: lustre_disk.h:266:18: error: 'LUSTRE_NODEMAP_NAME_LENGTH' undeclared here (not in a function) char ncr_name[LUSTRE_NODEMAP_NAME_LENGTH + 1]; This is due to the move of LUSTRE_NODEMAP_NAME_LENGTH to lustre_idl.h. Move it back and this time add a message to avoid this in the future. Test-Parameters: trivial Fixes: 8d828762d1 ("LU-17015 gss: support large kerberos token for rpc sec init") Change-Id: I5479bbf13f26bfd3b4f6e5f7c0c1688d810fca53 Signed-off-by: James Simmons Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/53208 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Andreas Dilger Reviewed-by: Sebastien Buisson Reviewed-by: Oleg Drokin --- lustre/include/uapi/linux/lustre/lustre_disk.h | 5 +++++ lustre/include/uapi/linux/lustre/lustre_idl.h | 2 -- lustre/include/upcall_cache.h | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lustre/include/uapi/linux/lustre/lustre_disk.h b/lustre/include/uapi/linux/lustre/lustre_disk.h index a097bcf..e264f27 100644 --- a/lustre/include/uapi/linux/lustre/lustre_disk.h +++ b/lustre/include/uapi/linux/lustre/lustre_disk.h @@ -255,6 +255,11 @@ enum nodemap_idx_type { NODEMAP_GLOBAL_IDX = 15, /* stores nodemap activation status */ }; +/* This is needed for struct nodemap_clustre_rec. Please don't move + * to lustre_idl.h which will break user land builds. + */ +#define LUSTRE_NODEMAP_NAME_LENGTH 16 + /* lu_nodemap flags */ enum nm_flag_bits { NM_FL_ALLOW_ROOT_ACCESS = 0x1, diff --git a/lustre/include/uapi/linux/lustre/lustre_idl.h b/lustre/include/uapi/linux/lustre/lustre_idl.h index c54c4c5..de53338 100644 --- a/lustre/include/uapi/linux/lustre/lustre_idl.h +++ b/lustre/include/uapi/linux/lustre/lustre_idl.h @@ -3727,8 +3727,6 @@ struct llog_update_record { SELINUX_POLICY_VER_LEN + \ SELINUX_POLICY_HASH_LEN + 3) -#define LUSTRE_NODEMAP_NAME_LENGTH 16 - /** enums containing the types of ids contained in a nodemap * kept so other modules (mgs, mdt, etc) can define the type * of search easily diff --git a/lustre/include/upcall_cache.h b/lustre/include/upcall_cache.h index 84816b3..e5891aa 100644 --- a/lustre/include/upcall_cache.h +++ b/lustre/include/upcall_cache.h @@ -34,6 +34,7 @@ #include #include +#include #include #include -- 1.8.3.1