if (ours == NULL)
return -ENOMEM;
+ if (size < OUT_UPDATE_INIT_BUFFER_SIZE)
+ size = OUT_UPDATE_INIT_BUFFER_SIZE;
+
ours->ours_req = object_update_request_alloc(size);
if (IS_ERR(ours->ours_req)) {
args->oaua_waitq = NULL;
args->oaua_flow_control = false;
req->rq_interpret_reply = osp_update_interpret;
- ptlrpcd_add_req(req, PDL_POLICY_LOCAL, -1);
+ ptlrpcd_add_req(req);
}
return rc;
oth->ot_our = our;
our->our_th = oth;
- if (oth->ot_super.th_sync)
- oth->ot_our->our_flags |= UPDATE_FL_SYNC;
-
return 0;
}
atomic_inc(args->oaua_count);
}
- ptlrpcd_add_req(req, PDL_POLICY_LOCAL, -1);
+ ptlrpcd_add_req(req);
req = NULL;
} else {
osp_thandle_get(oth); /* hold for commit callback */
if (top_device->ld_obd->obd_recovering)
req->rq_allow_replay = 1;
- osp_get_rpc_lock(osp);
+ if (osp->opd_connect_mdt)
+ osp_get_rpc_lock(osp);
rc = ptlrpc_queue_wait(req);
- osp_put_rpc_lock(osp);
+ if (osp->opd_connect_mdt)
+ osp_put_rpc_lock(osp);
if ((rc == -ENOMEM && req->rq_set == NULL) ||
(req->rq_transno == 0 && !req->rq_committed)) {
if (args->oaua_update != NULL) {
{
struct osp_thandle *oth = thandle_to_osp_thandle(th);
+ if (oth->ot_super.th_sync)
+ oth->ot_our->our_flags |= UPDATE_FL_SYNC;
/* For remote thandle, if there are local thandle, start it here*/
if (is_only_remote_trans(th) && oth->ot_storage_th != NULL)
return dt_trans_start(env, oth->ot_storage_th->th_dev,
}
if (!osp->opd_connect_mdt) {
+ osp_trans_callback(env, oth, th->th_result);
rc = osp_send_update_req(env, osp, oth->ot_our);
GOTO(out, rc);
}