Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ed51efd2 authored by Selvin Xavier's avatar Selvin Xavier Committed by Jason Gunthorpe
Browse files

RDMA/bnxt_re: Avoid accessing nq->bar_reg_iomem in failure case



In the failure path, nq->bar_reg_iomem gets accessed without
initializing. Avoid this by calling the bnxt_qplib_nq_stop_irq only if the
initialization is complete.

Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Fixes: 1ac5a404 ("RDMA/bnxt_re: Add bnxt_re RoCE driver")
Fixes: 6e04b103 ("RDMA/bnxt_re: Fix broken RoCE driver due to recent L2 driver changes")
Signed-off-by: default avatarSelvin Xavier <selvin.xavier@broadcom.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@mellanox.com>
parent eae4ad1b
Loading
Loading
Loading
Loading
+2 −1
Original line number Original line Diff line number Diff line
@@ -358,6 +358,7 @@ void bnxt_qplib_disable_nq(struct bnxt_qplib_nq *nq)
	}
	}


	/* Make sure the HW is stopped! */
	/* Make sure the HW is stopped! */
	if (nq->requested)
		bnxt_qplib_nq_stop_irq(nq, true);
		bnxt_qplib_nq_stop_irq(nq, true);


	if (nq->bar_reg_iomem)
	if (nq->bar_reg_iomem)