int rq_flags;
atomic_t rq_refcount;
+ int rq_request_portal; /* XXX FIXME bug 625069 */
+ int rq_reply_portal; /* XXX FIXME bug 625069 */
+
int rq_reqlen;
struct lustre_msg *rq_reqmsg;
OBD_FAIL_RETURN(OBD_FAIL_LDLM_CP_CALLBACK, 0);
rc = ldlm_handle_cp_callback(req);
RETURN(rc);
+
+ /* XXX FIXME move these three back to mds/handler.c, bug 625069 */
+ case LDLM_ENQUEUE:
+ CDEBUG(D_INODE, "enqueue\n");
+ OBD_FAIL_RETURN(OBD_FAIL_LDLM_ENQUEUE, 0);
+ rc = ldlm_handle_enqueue(req);
+ if (rc)
+ break;
+ RETURN(0);
+ case LDLM_CONVERT:
+ CDEBUG(D_INODE, "convert\n");
+ OBD_FAIL_RETURN(OBD_FAIL_LDLM_CONVERT, 0);
+ rc = ldlm_handle_convert(req);
+ if (rc)
+ break;
+ RETURN(0);
+ case LDLM_CANCEL:
+ CDEBUG(D_INODE, "cancel\n");
+ OBD_FAIL_RETURN(OBD_FAIL_LDLM_CANCEL, 0);
+ rc = ldlm_handle_cancel(req);
+ if (rc)
+ break;
+ RETURN(0);
+ /* XXX FIXME move these three back to mds/handler.c, bug 625069 */
+
default:
CERROR("invalid opcode %d\n", req->rq_reqmsg->opc);
RETURN(-EINVAL);
if (!connection)
CERROR("No LDLM UUID found: assuming ldlm is local.\n");
- /* XXX
- ptlrpc_init_client(LDLM_REQUEST_PORTAL, LDLM_REPLY_PORTAL,
- obddev->u.ldlm.ldlm_client, connection);
- */
-
switch (cmd) {
case IOC_LDLM_TEST:
err = ldlm_test(obddev, conn);
} else if (req->rq_reqmsg->buflens[0] != sizeof(*body))
LBUG();
+ req->rq_request_portal = LDLM_REQUEST_PORTAL; /* XXX FIXME bug 625069 */
+ req->rq_reply_portal = LDLM_REPLY_PORTAL; /* XXX FIXME bug 625069 */
+
/* Dump all of this data into the request buffer */
body = lustre_msg_buf(req->rq_reqmsg, 0);
ldlm_lock2desc(lock, &body->lock_desc);
if (!req)
GOTO(out, rc = -ENOMEM);
+ req->rq_request_portal = LDLM_REQUEST_PORTAL; /* XXX FIXME bug 625069 */
+ req->rq_reply_portal = LDLM_REPLY_PORTAL; /* XXX FIXME bug 625069 */
+
body = lustre_msg_buf(req->rq_reqmsg, 0);
memcpy(&body->lock_handle1, &lock->l_remote_handle,
sizeof(body->lock_handle1));
if (!req)
GOTO(out, rc = -ENOMEM);
+ /* XXX FIXME bug 625069 */
+ req->rq_request_portal = LDLM_REQUEST_PORTAL;
+ req->rq_reply_portal = LDLM_REPLY_PORTAL;
+
body = lustre_msg_buf(req->rq_reqmsg, 0);
memcpy(&body->lock_handle1, &lock->l_remote_handle,
sizeof(body->lock_handle1));
if (loi->loi_id == 0)
continue;
- CERROR("objid "LPX64"[%d] has subobj "LPX64" at idx %u\n",
- oa->o_id, i, loi->loi_id, loi->loi_ost_idx);
+ CDEBUG(D_INFO, "objid "LPX64"[%d] has subobj "LPX64" at idx "
+ "%u\n", oa->o_id, i, loi->loi_id, loi->loi_ost_idx);
/* create data objects with "parent" OA */
memcpy(&tmp, oa, sizeof(tmp));
tmp.o_id = loi->loi_id;
rc = mds_close(req);
break;
- case LDLM_ENQUEUE:
- CDEBUG(D_INODE, "enqueue\n");
- OBD_FAIL_RETURN(OBD_FAIL_LDLM_ENQUEUE, 0);
- rc = ldlm_handle_enqueue(req);
- if (rc)
- break;
- RETURN(0);
-
- case LDLM_CONVERT:
- CDEBUG(D_INODE, "convert\n");
- OBD_FAIL_RETURN(OBD_FAIL_LDLM_CONVERT, 0);
- rc = ldlm_handle_convert(req);
- if (rc)
- break;
- RETURN(0);
-
- case LDLM_CANCEL:
- CDEBUG(D_INODE, "cancel\n");
- OBD_FAIL_RETURN(OBD_FAIL_LDLM_CANCEL, 0);
- rc = ldlm_handle_cancel(req);
- if (rc)
- break;
- RETURN(0);
case LDLM_BL_CALLBACK:
case LDLM_CP_CALLBACK:
CDEBUG(D_INODE, "callback\n");
request->rq_level = LUSTRE_CONN_FULL;
request->rq_type = PTL_RPC_MSG_REQUEST;
request->rq_import = imp;
+
+ /* XXX FIXME bug 625069 */
+ request->rq_request_portal = imp->imp_client->cli_request_portal;
+ request->rq_reply_portal = imp->imp_client->cli_reply_portal;
+
request->rq_connection = ptlrpc_connection_addref(conn);
INIT_LIST_HEAD(&request->rq_list);
}
rc = PtlMEAttach(request->rq_connection->c_peer.peer_ni,
- request->rq_import->imp_client->cli_reply_portal,
+ request->rq_reply_portal,/* XXX FIXME bug 625069 */
source_id, request->rq_xid, 0, PTL_UNLINK,
PTL_INS_AFTER, &request->rq_reply_me_h);
if (rc != PTL_OK) {
CDEBUG(D_NET, "Setup reply buffer: %u bytes, xid "LPU64
", portal %u\n",
request->rq_replen, request->rq_xid,
- request->rq_import->imp_client->cli_reply_portal);
+ request->rq_reply_portal);
}
/* Clear any flags that may be present from previous sends,
* except for REPLAY. */
request->rq_flags &= PTL_RPC_FL_REPLAY;
rc = ptl_send_buf(request, request->rq_connection,
- request->rq_import->imp_client->cli_request_portal);
+ request->rq_request_portal);
RETURN(rc);
cleanup2: