From: huanghua Date: Mon, 5 Jun 2006 09:48:12 +0000 (+0000) Subject: (1) In MDT, call mo_open of CMM in mdt_md_open; X-Git-Tag: v1_8_0_110~486^2~1667 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=d99389a97ba2e098fdd9e61bd9ac7ce2a1b1fc26;p=fs%2Flustre-release.git (1) In MDT, call mo_open of CMM in mdt_md_open; (2) fix some syntax error in md_objects. --- diff --git a/lustre/include/md_object.h b/lustre/include/md_object.h index bd70ba4..a45bd37 100644 --- a/lustre/include/md_object.h +++ b/lustre/include/md_object.h @@ -185,7 +185,7 @@ static inline int mo_xattr_get(const struct lu_context *cx, struct md_object *m, void *buf, int buf_len, const char *name) { - if (m->mo_ops->moo_xattr_get); + if (m->mo_ops->moo_xattr_get) return m->mo_ops->moo_xattr_get(cx, m, buf, buf_len, name); else return -ENODEV; @@ -243,7 +243,7 @@ static inline int mdo_name_insert(const struct lu_context *cx, const char *name, const struct lu_fid *f, struct lu_attr *at) { - if (p->mo_dir_ops->mdo_name_insert); + if (p->mo_dir_ops->mdo_name_insert) return p->mo_dir_ops->mdo_name_insert(cx, p, name, f, at); else return -ENODEV; diff --git a/lustre/mdt/mdt_reint.c b/lustre/mdt/mdt_reint.c index 2b1c1fe..95b3616 100644 --- a/lustre/mdt/mdt_reint.c +++ b/lustre/mdt/mdt_reint.c @@ -38,9 +38,10 @@ /* object operations */ -static int mdt_md_open(struct mdt_thread_info *info, struct mdt_object *obj) +static int mdt_md_open(struct mdt_thread_info *info, struct mdt_object *child) { - return 0; + return mo_open(info->mti_ctxt, mdt_object_child(child)); + } static int mdt_md_create(struct mdt_thread_info *info) @@ -312,7 +313,7 @@ static int mdt_reint_open(struct mdt_thread_info *info) /*FIXME add permission checking here */ if (S_ISREG(mode)) ; - + /* Open it now. */ result = mdt_md_open(info, child); out_child: