From: yury Date: Fri, 14 Apr 2006 15:16:15 +0000 (+0000) Subject: - using lu_fid_eq() instead of fid_equals() X-Git-Tag: v1_8_0_110~486^2~2010 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=5fe96bd1e8cf2d49ca48a8f0a7cc167d2245b842;p=fs%2Flustre-release.git - using lu_fid_eq() instead of fid_equals() --- diff --git a/lustre/lmv/lmv_intent.c b/lustre/lmv/lmv_intent.c index 08ac381..2d78fb1 100644 --- a/lustre/lmv/lmv_intent.c +++ b/lustre/lmv/lmv_intent.c @@ -165,7 +165,7 @@ repeat: if (rc == -ERESTART) { /* directory got splitted. time to update local object and * repeat the request with proper MDS */ - LASSERT(fid_equals(pid, &rpid)); + LASSERT(lu_fid_eq(pid, &rpid)); rc = lmv_get_mea_and_update_object(exp, &rpid); if (rc == 0) { ptlrpc_req_finished(*reqp); @@ -263,7 +263,7 @@ int lmv_intent_getattr(struct obd_export *exp, struct lu_fid *pid, if (obj) { /* in fact, we need not this with current intent_lock(), * but it may change some day */ - if (!fid_equals(pid, cid)){ + if (!lu_fid_eq(pid, cid)){ rpid = obj->objs[mds].lo_fid; mds = lmv_fld_lookup(obd, &rpid); } @@ -409,7 +409,7 @@ int lmv_lookup_slaves(struct obd_export *exp, struct ptlrpc_request **reqp) struct lookup_intent it; int mds; - if (fid_equals(&fid, &obj->lo_fid)) + if (lu_fid_eq(&fid, &obj->lo_fid)) /* skip master obj */ continue; @@ -680,7 +680,7 @@ int lmv_revalidate_slaves(struct obd_export *exp, struct ptlrpc_request **reqp, if (!it.d.fs_data) GOTO(cleanup, rc = -ENOMEM); - if (fid_equals(&fid, &obj->lo_fid)) { + if (lu_fid_eq(&fid, &obj->lo_fid)) { if (master_valid) { /* lmv_intent_getattr() already checked * validness and took the lock */ diff --git a/lustre/lmv/lmv_obd.c b/lustre/lmv/lmv_obd.c index b8c3d96..4f192a9 100644 --- a/lustre/lmv/lmv_obd.c +++ b/lustre/lmv/lmv_obd.c @@ -862,7 +862,7 @@ static int lmv_getattr(struct obd_export *exp, struct lu_fid *fid, } /* skip master obj. */ - if (fid_equals(&obj->lo_fid, &obj->objs[i].lo_fid)) + if (lu_fid_eq(&obj->lo_fid, &obj->objs[i].lo_fid)) continue; body->size += obj->objs[i].size; @@ -1519,7 +1519,7 @@ static int lmv_setattr(struct obd_export *exp, struct mdc_op_data *data, data, iattr, ea, ealen, ea2, ea2len, ea3, ea3len, &req); - if (fid_equals(&obj->lo_fid, &obj->objs[i].lo_fid)) { + if (lu_fid_eq(&obj->lo_fid, &obj->objs[i].lo_fid)) { /* * this is master object and this request should * be returned back to llite. @@ -1664,7 +1664,7 @@ static int lmv_readpage(struct obd_export *exp, struct lu_fid *fid, rc = md_readpage(lmv->tgts[i].ltd_exp, &rid, offset, page, request); - if (rc == 0 && !fid_equals(&rid, fid)) + if (rc == 0 && !lu_fid_eq(&rid, fid)) /* this page isn't from master object. To avoid "." and ".." * duplication in directory, we have to remove them from all * slave objects */ diff --git a/lustre/lmv/lmv_objmgr.c b/lustre/lmv/lmv_objmgr.c index ca72df3..23ace7a 100644 --- a/lustre/lmv/lmv_objmgr.c +++ b/lustre/lmv/lmv_objmgr.c @@ -216,7 +216,7 @@ __grab_obj(struct obd_device *obd, struct lu_fid *fid) continue; /* check if this is what we're looking for. */ - if (fid_equals(&obj->lo_fid, fid)) + if (lu_fid_eq(&obj->lo_fid, fid)) return __get_obj(obj); }