+ stx.stx_attributes_mask = STATX_ATTR_IMMUTABLE |
+ STATX_ATTR_APPEND;
+#ifdef HAVE_LUSTRE_CRYPTO
+ stx.stx_attributes_mask |= STATX_ATTR_ENCRYPTED;
+#endif
+ if (body->mbo_valid & OBD_MD_FLFLAGS) {
+ stx.stx_attributes |= body->mbo_flags;
+ /* if Lustre specific LUSTRE_ENCRYPT_FL flag is
+ * set, also set ext4 equivalent to please statx
+ */
+ if (body->mbo_flags & LUSTRE_ENCRYPT_FL)
+ stx.stx_attributes |= STATX_ATTR_ENCRYPTED;
+ }
+