[PATCH hw-next] infiniband/hw:remove unneeded variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Minghao Chi <chi.minghao@xxxxxxxxxx>

Return status directly from function called.

Reported-by: Zeal Robot <zealci@xxxxxxxxxx>
Signed-off-by: Minghao Chi <chi.minghao@xxxxxxxxxx>
---
 drivers/infiniband/hw/irdma/uk.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/infiniband/hw/irdma/uk.c b/drivers/infiniband/hw/irdma/uk.c
index 57a9444e9ea7..fe2ba1dd1b03 100644
--- a/drivers/infiniband/hw/irdma/uk.c
+++ b/drivers/infiniband/hw/irdma/uk.c
@@ -244,7 +244,6 @@ __le64 *irdma_qp_get_next_send_wqe(struct irdma_qp_uk *qp, u32 *wqe_idx,
  */
 __le64 *irdma_qp_get_next_recv_wqe(struct irdma_qp_uk *qp, u32 *wqe_idx)
 {
-	__le64 *wqe;
 	enum irdma_status_code ret_code;
 
 	if (IRDMA_RING_FULL_ERR(qp->rq_ring))
@@ -257,9 +256,8 @@ __le64 *irdma_qp_get_next_recv_wqe(struct irdma_qp_uk *qp, u32 *wqe_idx)
 	if (!*wqe_idx)
 		qp->rwqe_polarity = !qp->rwqe_polarity;
 	/* rq_wqe_size_multiplier is no of 32 byte quanta in one rq wqe */
-	wqe = qp->rq_base[*wqe_idx * qp->rq_wqe_size_multiplier].elem;
 
-	return wqe;
+	return qp->rq_base[*wqe_idx * qp->rq_wqe_size_multiplier].elem;
 }
 
 /**
-- 
2.25.1




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux