/** portals handle must be first */
struct portals_handle mfd_open_handle;
/** open mode provided by client */
- __u64 mfd_mode;
+ u64 mfd_open_flags;
/** protected by med_open_lock */
struct list_head mfd_list;
/** xid of the open request */
unsigned int mdt_capa_conf:1,
/* Enable remote dir on non-MDT0 */
mdt_enable_remote_dir:1,
- mdt_skip_lfsck:1;
-
+ mdt_enable_striped_dir:1,
+ mdt_enable_dir_migration:1,
+ mdt_enable_remote_rename:1,
+ mdt_skip_lfsck:1,
+ mdt_readonly:1;
+
+ /* user with gid can create remote/striped
+ * dir, and set default dir stripe */
gid_t mdt_enable_remote_dir_gid;
/* lock for osfs and md_root */
void *rr_eadata;
int rr_eadatalen;
__u32 rr_flags;
+ __u16 rr_mirror_id;
};
enum mdt_reint_flag {
void *client_nid);
int mdt_lock_new_child(struct mdt_thread_info *info,
- struct mdt_object *o,
- struct mdt_lock_handle *child_lockh);
-
-void mdt_mfd_set_mode(struct mdt_file_data *mfd,
- __u64 mode);
-
-int mdt_reint_open(struct mdt_thread_info *info,
- struct mdt_lock_handle *lhc);
-
+ struct mdt_object *o,
+ struct mdt_lock_handle *child_lockh);
+void mdt_mfd_set_mode(struct mdt_file_data *mfd, u64 open_flags);
+int mdt_reint_open(struct mdt_thread_info *info, struct mdt_lock_handle *lhc);
struct mdt_file_data *mdt_open_handle2mfd(struct mdt_export_data *med,
const struct lustre_handle *open_handle,
bool is_replay);
+int mdt_revoke_remote_lookup_lock(struct mdt_thread_info *info,
+ struct mdt_object *pobj,
+ struct mdt_object *obj);
int mdt_get_info(struct tgt_session_info *tsi);
int mdt_attr_get_complex(struct mdt_thread_info *info,
struct linkea_data *ldata);
int mdt_close_internal(struct mdt_thread_info *info, struct ptlrpc_request *req,
struct mdt_body *repbody);
-int mdt_remote_permission(struct mdt_thread_info *info);
+void mdt_pack_secctx_in_reply(struct mdt_thread_info *info,
+ struct mdt_object *child);
static inline struct mdt_device *mdt_dev(struct lu_device *d)
{
static inline bool mdt_rdonly(struct obd_export *exp)
{
- if (exp_connect_flags(exp) & OBD_CONNECT_RDONLY ||
- mdt_exp2dev(exp)->mdt_bottom->dd_rdonly)
- return true;
- return false;
+ return (exp_connect_flags(exp) & OBD_CONNECT_RDONLY ||
+ mdt_exp2dev(exp)->mdt_bottom->dd_rdonly ||
+ mdt_exp2dev(exp)->mdt_readonly);
}
typedef void (*mdt_reconstruct_t)(struct mdt_thread_info *mti,