Lines Matching refs:resp
90 rxe_run_task(&qp->resp.task, must_sched);
98 if (qp->resp.state == QP_STATE_ERROR) {
114 return (qp->resp.res) ? RESPST_READ_REPLY : RESPST_CHK_PSN;
120 int diff = psn_compare(pkt->psn, qp->resp.psn);
126 if (qp->resp.sent_psn_nak)
129 qp->resp.sent_psn_nak = 1;
138 if (qp->resp.sent_psn_nak)
139 qp->resp.sent_psn_nak = 0;
144 if (qp->resp.drop_msg || diff != 0) {
146 qp->resp.drop_msg = 0;
150 qp->resp.drop_msg = 1;
166 switch (qp->resp.opcode) {
207 switch (qp->resp.opcode) {
238 qp->resp.drop_msg = 1;
270 qp->resp.drop_msg = 1;
308 memcpy(&qp->resp.srq_wqe, wqe, sizeof(qp->resp.srq_wqe));
310 qp->resp.wqe = &qp->resp.srq_wqe.wqe;
336 if (qp->resp.state == QP_STATE_ERROR) {
337 if (qp->resp.wqe) {
338 qp->resp.status = IB_WC_WR_FLUSH_ERR;
341 qp->resp.wqe = queue_head(qp->rq.queue);
342 if (qp->resp.wqe) {
343 qp->resp.status = IB_WC_WR_FLUSH_ERR;
368 qp->resp.wqe = queue_head(qp->rq.queue);
369 return (qp->resp.wqe) ? RESPST_CHK_LENGTH : RESPST_ERR_RNR;
404 qp->resp.va = reth_va(pkt);
405 qp->resp.rkey = reth_rkey(pkt);
406 qp->resp.resid = reth_len(pkt);
407 qp->resp.length = reth_len(pkt);
412 qp->resp.va = atmeth_va(pkt);
413 qp->resp.rkey = atmeth_rkey(pkt);
414 qp->resp.resid = sizeof(u64);
427 va = qp->resp.va;
428 rkey = qp->resp.rkey;
429 resid = qp->resp.resid;
469 WARN_ON_ONCE(qp->resp.mr);
471 qp->resp.mr = mem;
485 err = copy_data(qp->pd, IB_ACCESS_LOCAL_WRITE, &qp->resp.wqe->dma,
501 err = rxe_mem_copy(qp->resp.mr, qp->resp.va, payload_addr(pkt),
508 qp->resp.va += data_len;
509 qp->resp.resid -= data_len;
524 struct rxe_mem *mr = qp->resp.mr;
541 qp->resp.atomic_orig = *vaddr;
604 aeth_set_msn(ack, qp->resp.msn);
608 atmack_set_orig(ack, qp->resp.atomic_orig);
640 struct resp_res *res = qp->resp.res;
648 res = &qp->resp.resources[qp->resp.res_head];
656 res->read.va = qp->resp.va;
657 res->read.va_org = qp->resp.va;
670 res->read.resid = qp->resp.resid;
671 res->read.length = qp->resp.resid;
672 res->read.rkey = qp->resp.rkey;
675 res->read.mr = qp->resp.mr;
676 qp->resp.mr = NULL;
678 qp->resp.res = res;
731 qp->resp.res = NULL;
733 qp->resp.opcode = -1;
734 if (psn_compare(res->cur_psn, qp->resp.psn) >= 0)
735 qp->resp.psn = res->cur_psn;
782 qp->resp.msn++;
794 qp->resp.psn = (pkt->psn + 1) & BTH_PSN_MASK;
795 qp->resp.ack_psn = qp->resp.psn;
797 qp->resp.opcode = pkt->opcode;
798 qp->resp.status = IB_WC_SUCCESS;
802 qp->resp.msn++;
816 struct rxe_recv_wqe *wqe = qp->resp.wqe;
825 uwc->status = qp->resp.status;
829 wc->status = qp->resp.status;
842 qp->resp.length : wqe->dma.length - wqe->dma.resid;
915 qp->resp.wqe = NULL;
920 if (qp->resp.state == QP_STATE_ERROR)
969 res = &qp->resp.resources[qp->resp.res_head];
999 if (qp->resp.aeth_syndrome != AETH_ACK_UNLIMITED)
1000 send_ack(qp, pkt, qp->resp.aeth_syndrome, pkt->psn);
1020 if (qp->resp.mr) {
1021 rxe_drop_ref(qp->resp.mr);
1022 qp->resp.mr = NULL;
1033 struct resp_res *res = &qp->resp.resources[i];
1051 u32 prev_psn = (qp->resp.ack_psn - 1) & BTH_PSN_MASK;
1102 qp->resp.res = res;
1134 qp->resp.aeth_syndrome = syndrome;
1135 qp->resp.status = status;
1138 qp->resp.goto_error = 1;
1146 qp->resp.drop_msg = 1;
1147 if (qp->resp.wqe) {
1148 qp->resp.status = IB_WC_REM_INV_REQ_ERR;
1159 if (qp->resp.wqe) {
1160 qp->resp.wqe->dma.resid = qp->resp.wqe->dma.length;
1161 qp->resp.wqe->dma.cur_sge = 0;
1162 qp->resp.wqe->dma.sge_offset = 0;
1163 qp->resp.opcode = -1;
1166 if (qp->resp.mr) {
1167 rxe_drop_ref(qp->resp.mr);
1168 qp->resp.mr = NULL;
1201 qp->resp.aeth_syndrome = AETH_ACK_UNLIMITED;
1208 switch (qp->resp.state) {
1263 send_ack(qp, pkt, AETH_NAK_PSN_SEQ_ERROR, qp->resp.psn);
1291 qp->resp.drop_msg = 1;
1303 qp->resp.drop_msg = 1;
1306 qp->resp.status = IB_WC_REM_ACCESS_ERR;
1323 qp->resp.status = IB_WC_REM_INV_REQ_ERR;
1327 qp->resp.drop_msg = 1;
1345 if (qp->resp.goto_error) {
1353 if (qp->resp.goto_error) {
1362 qp->resp.wqe = NULL;
1366 qp->resp.goto_error = 0;