struct dt_object *mdt_ck_obj;
unsigned long mdt_ck_timeout;
unsigned long mdt_ck_expiry;
- struct timer_list mdt_ck_timer;
+ cfs_timer_t mdt_ck_timer;
struct ptlrpc_thread mdt_ck_thread;
struct lustre_capa_key mdt_capa_keys[2];
unsigned int mdt_capa_conf:1;
struct mdt_thread_info {
/*
* XXX: Part One:
- * The following members will be filled expilictly
+ * The following members will be filled explicitly
* with specific data in mdt_thread_info_init().
*/
-
- /*
- * for req-layout interface. This field should be first to be compatible
- * with "struct com_thread_info" in seq and fld.
+ /* TODO: move this into mdt_session_key(with LCT_SESSION), because
+ * request handling may migrate from one server thread to another.
*/
- struct req_capsule mti_pill;
+ struct req_capsule *mti_pill;
+
/* although we have export in req, there are cases when it is not
* available, e.g. closing files upon export destroy */
struct obd_export *mti_exp;
/*
- * number of buffers in reply message.
- */
- int mti_rep_buf_nr;
- /*
- * sizes of reply buffers.
- */
- int mti_rep_buf_size[REQ_MAX_FIELD_NR];
- /*
* A couple of lock handles.
*/
struct mdt_lock_handle mti_lh[MDT_LH_NR];
static inline struct md_object *mdt_object_child(struct mdt_object *o)
{
+ LASSERT(o);
return lu2md(lu_object_next(&o->mot_obj.mo_lu));
}
static inline struct ptlrpc_request *mdt_info_req(struct mdt_thread_info *info)
{
- return info->mti_pill.rc_req;
+ return info->mti_pill ? info->mti_pill->rc_req : NULL;
}
static inline __u64 mdt_conn_flags(struct mdt_thread_info *info)
return lu_object_fid(&o->mot_obj.mo_lu);
}
+
+static inline void mdt_export_evict(struct obd_export *exp)
+{
+ class_fail_export(exp);
+ class_export_put(exp);
+}
+
int mdt_get_disposition(struct ldlm_reply *rep, int flag);
void mdt_set_disposition(struct mdt_thread_info *info,
struct ldlm_reply *rep, int flag);
const struct lu_attr *attr, const struct lu_fid *fid);
int mdt_getxattr(struct mdt_thread_info *info);
-int mdt_setxattr(struct mdt_thread_info *info);
+int mdt_reint_setxattr(struct mdt_thread_info *info,
+ struct mdt_lock_handle *lh);
void mdt_lock_handle_init(struct mdt_lock_handle *lh);
void mdt_lock_handle_fini(struct mdt_lock_handle *lh);