struct dentry *dentry;
struct lookup_intent *it;
int rc = 0;
+ struct mdt_body *body;
ENTRY;
spin_lock(&lli->lli_lock);
if (entry->se_stat != SA_ENTRY_STATED)
GOTO(out, rc = entry->se_stat);
+ body = req_capsule_server_get(&req->rq_pill, &RMF_MDT_BODY);
+ if (body == NULL)
+ GOTO(out, rc = -EFAULT);
+
if (dentry->d_inode == NULL) {
/*
* lookup.
LASSERT(fid_is_zero(&minfo->mi_data.op_fid2));
+ /*
+ * XXX: No fid in reply, this is probaly cross-ref case.
+ * SA can't handle it yet.
+ */
+ if (body->valid & OBD_MD_MDS)
+ GOTO(out, rc = -EAGAIN);
+
rc = ll_lookup_it_finish(req, it, &icbd);
if (!rc)
/*
/*
* revalidate.
*/
- struct mdt_body *body;
-
- body = lustre_msg_buf(req->rq_repmsg, DLM_REPLY_REC_OFF,
- sizeof(*body));
if (!lu_fid_eq(&minfo->mi_data.op_fid2, &body->fid1)) {
ll_unhash_aliases(dentry->d_inode);
GOTO(out, rc = -EAGAIN);
&(*dentryp)->d_name);
if (result) {
LASSERT(result != *dentryp);
- dput(*dentryp);
+ /* BUG 16303: do not drop reference count for
+ * "*dentryp", VFS will do that by itself. */
*dentryp = result;
RETURN(1);
}