Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma
[sfrench/cifs-2.6.git] / drivers / infiniband / hw / qedr / verbs.c
index f9b198455fc9c23a61cdff7e5ed9bf462af8008d..f07b8df96f43954e67d4dfc32148e96a751e6974 100644 (file)
@@ -1614,7 +1614,7 @@ static int qedr_create_kernel_qp(struct qedr_dev *dev,
        qp->sq.max_wr = min_t(u32, attrs->cap.max_send_wr * dev->wq_multiplier,
                              dev->attr.max_sqe);
 
-       qp->wqe_wr_id = kzalloc(qp->sq.max_wr * sizeof(*qp->wqe_wr_id),
+       qp->wqe_wr_id = kcalloc(qp->sq.max_wr, sizeof(*qp->wqe_wr_id),
                                GFP_KERNEL);
        if (!qp->wqe_wr_id) {
                DP_ERR(dev, "create qp: failed SQ shadow memory allocation\n");
@@ -1632,7 +1632,7 @@ static int qedr_create_kernel_qp(struct qedr_dev *dev,
        qp->rq.max_wr = (u16) max_t(u32, attrs->cap.max_recv_wr, 1);
 
        /* Allocate driver internal RQ array */
-       qp->rqe_wr_id = kzalloc(qp->rq.max_wr * sizeof(*qp->rqe_wr_id),
+       qp->rqe_wr_id = kcalloc(qp->rq.max_wr, sizeof(*qp->rqe_wr_id),
                                GFP_KERNEL);
        if (!qp->rqe_wr_id) {
                DP_ERR(dev,
@@ -3279,7 +3279,7 @@ int qedr_post_recv(struct ib_qp *ibqp, struct ib_recv_wr *wr,
                                SET_FIELD(flags, RDMA_RQ_SGE_NUM_SGES,
                                          wr->num_sge);
 
-                       SET_FIELD(flags, RDMA_RQ_SGE_L_KEY,
+                       SET_FIELD(flags, RDMA_RQ_SGE_L_KEY_LO,
                                  wr->sg_list[i].lkey);
 
                        RQ_SGE_SET(rqe, wr->sg_list[i].addr,
@@ -3298,7 +3298,7 @@ int qedr_post_recv(struct ib_qp *ibqp, struct ib_recv_wr *wr,
                        /* First one must include the number
                         * of SGE in the list
                         */
-                       SET_FIELD(flags, RDMA_RQ_SGE_L_KEY, 0);
+                       SET_FIELD(flags, RDMA_RQ_SGE_L_KEY_LO, 0);
                        SET_FIELD(flags, RDMA_RQ_SGE_NUM_SGES, 1);
 
                        RQ_SGE_SET(rqe, 0, 0, flags);