Whamcloud - gitweb
LU-17907 enc: enc flag should not remove other flags
authorSebastien Buisson <sbuisson@ddn.com>
Wed, 5 Jun 2024 12:35:02 +0000 (14:35 +0200)
committerAndreas Dilger <adilger@whamcloud.com>
Wed, 3 Jul 2024 04:34:36 +0000 (04:34 +0000)
commit1cc465430d297dcd14893e3b73354c5bf5ea8220
tree60e554eff23b737d8e9a98696d38a90721c5edc5
parentdd0af0599f6a82580c56be9b071905ff52268526
LU-17907 enc: enc flag should not remove other flags

When updating inode flags, the lli_flags must be taken into account
so that they do not get lost. So provide helper functions for callers
of ll_update_inode_flags(), as an overlay to ll_inode_to_ext_flags().
And on server side, the mdd layer must fetch the existing flags when
setting LUSTRE_ENCRYPT_FL attr flag.

Lustre-change: https://review.whamcloud.com/55317
Lustre-commit: cfde96fb2e77c33a8ab9afede79cdf093ee8ff9e

Fixes: 40d91eafe2 ("LU-12275 sec: atomicity of encryption context getting/setting")
Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Change-Id: I150f2d87cef112beab81d1d2030133671d4b7361
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/55318
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Lai Siyao <lai.siyao@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/llite/crypto.c
lustre/llite/file.c
lustre/llite/llite_internal.h
lustre/llite/llite_lib.c
lustre/mdd/mdd_internal.h
lustre/tests/sanity-sec.sh