Lines Matching defs:ib_wr
3236 fill_wqe_sg_send(struct nes_hw_qp_wqe *wqe, struct ib_send_wr *ib_wr, u32 uselkey)
3240 for (sge_index = 0; sge_index < ib_wr->num_sge; sge_index++) {
3242 ib_wr->sg_list[sge_index].addr);
3244 ib_wr->sg_list[sge_index].length);
3247 (ib_wr->sg_list[sge_index].lkey));
3251 total_payload_length += ib_wr->sg_list[sge_index].length;
3262 static int nes_post_send(struct ib_qp *ibqp, struct ib_send_wr *ib_wr,
3287 while (ib_wr) {
3304 u64temp = (u64)(ib_wr->wr_id);
3307 switch (ib_wr->opcode) {
3310 if (IB_WR_SEND == ib_wr->opcode) {
3311 if (ib_wr->send_flags & IB_SEND_SOLICITED)
3316 if (ib_wr->send_flags & IB_SEND_SOLICITED)
3322 ib_wr->ex.invalidate_rkey);
3325 if (ib_wr->num_sge > nesdev->nesadapter->max_sge) {
3330 if (ib_wr->send_flags & IB_SEND_FENCE)
3333 if ((ib_wr->send_flags & IB_SEND_INLINE) &&
3335 (ib_wr->sg_list[0].length <= 64)) {
3337 (void *)(unsigned long)ib_wr->sg_list[0].addr, ib_wr->sg_list[0].length);
3339 ib_wr->sg_list[0].length);
3342 fill_wqe_sg_send(wqe, ib_wr, 1);
3348 if (ib_wr->num_sge > nesdev->nesadapter->max_sge) {
3349 nes_debug(NES_DBG_IW_TX, "Exceeded max sge, ib_wr=%u, max=%u\n",
3350 ib_wr->num_sge, nesdev->nesadapter->max_sge);
3355 if (ib_wr->send_flags & IB_SEND_FENCE)
3359 ib_wr->wr.rdma.rkey);
3361 ib_wr->wr.rdma.remote_addr);
3363 if ((ib_wr->send_flags & IB_SEND_INLINE) &&
3365 (ib_wr->sg_list[0].length <= 64)) {
3367 (void *)(unsigned long)ib_wr->sg_list[0].addr, ib_wr->sg_list[0].length);
3369 ib_wr->sg_list[0].length);
3372 fill_wqe_sg_send(wqe, ib_wr, 1);
3381 if (ib_wr->num_sge > 1) {
3382 nes_debug(NES_DBG_IW_TX, "Exceeded max sge, ib_wr=%u, max=1\n",
3383 ib_wr->num_sge);
3387 if (ib_wr->opcode == IB_WR_RDMA_READ) {
3392 ib_wr->ex.invalidate_rkey);
3396 ib_wr->wr.rdma.remote_addr);
3398 ib_wr->wr.rdma.rkey);
3400 ib_wr->sg_list->length);
3402 ib_wr->sg_list->addr);
3404 ib_wr->sg_list->lkey);
3410 ib_wr->ex.invalidate_rkey);
3415 int flags = ib_wr->wr.fast_reg.access_flags;
3417 container_of(ib_wr->wr.fast_reg.page_list,
3423 if (ib_wr->wr.fast_reg.page_list_len >
3432 ib_wr->wr.fast_reg.iova_start);
3435 ib_wr->wr.fast_reg.length);
3438 ib_wr->wr.fast_reg.rkey);
3440 if (ib_wr->wr.fast_reg.page_shift == 12) {
3442 } else if (ib_wr->wr.fast_reg.page_shift == 21) {
3446 " ib_wr=%u, max=1\n", ib_wr->num_sge);
3465 if (ib_wr->wr.fast_reg.page_list_len >
3468 " ib_wr=%p, value=%u, max=%u\n",
3469 ib_wr, ib_wr->wr.fast_reg.page_list_len,
3481 ib_wr->wr.fast_reg.page_list_len * 8);
3483 for (i = 0; i < ib_wr->wr.fast_reg.page_list_len; i++)
3489 (void *)ib_wr->wr.fast_reg.iova_start,
3490 ib_wr->wr.fast_reg.length,
3491 ib_wr->wr.fast_reg.rkey,
3493 ib_wr->wr.fast_reg.page_list_len,
3506 if ((ib_wr->send_flags & IB_SEND_SIGNALED) || nesqp->sig_all)
3511 ib_wr = ib_wr->next;
3532 *bad_wr = ib_wr;
3540 static int nes_post_recv(struct ib_qp *ibqp, struct ib_recv_wr *ib_wr,
3566 while (ib_wr) {
3573 if (ib_wr->num_sge > nesdev->nesadapter->max_sge) {
3583 nes_debug(NES_DBG_IW_RX, "ibwr sge count = %u.\n", ib_wr->num_sge);
3589 u64temp = (u64)(ib_wr->wr_id);
3593 for (sge_index=0; sge_index < ib_wr->num_sge; sge_index++) {
3595 ib_wr->sg_list[sge_index].addr);
3597 ib_wr->sg_list[sge_index].length);
3599 ib_wr->sg_list[sge_index].lkey);
3601 total_payload_length += ib_wr->sg_list[sge_index].length;
3606 ib_wr = ib_wr->next;
3625 *bad_wr = ib_wr;