public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drivers: fix the exception was not returned
@ 2025-09-16  9:11 YanLong Dai
  2025-09-16 13:49 ` Leon Romanovsky
  0 siblings, 1 reply; 8+ messages in thread
From: YanLong Dai @ 2025-09-16  9:11 UTC (permalink / raw)
  To: selvin.xavier, kalesh-anakkur.purayil, jgg, leon
  Cc: linux-rdma, linux-kernel, daiyanlong

From: daiyanlong <daiyanlong@kylinos.cn>

The return value rc of bnxt_qplib_destroy_qp is abnormal and no return

Signed-off-by: daiyanlong <daiyanlong@kylinos.cn>
---
 drivers/infiniband/hw/bnxt_re/ib_verbs.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/infiniband/hw/bnxt_re/ib_verbs.c b/drivers/infiniband/hw/bnxt_re/ib_verbs.c
index 260dc67b8b87..d52cfb50b1b8 100644
--- a/drivers/infiniband/hw/bnxt_re/ib_verbs.c
+++ b/drivers/infiniband/hw/bnxt_re/ib_verbs.c
@@ -971,8 +971,10 @@ int bnxt_re_destroy_qp(struct ib_qp *ib_qp, struct ib_udata *udata)
 	bnxt_qplib_flush_cqn_wq(&qp->qplib_qp);
 
 	rc = bnxt_qplib_destroy_qp(&rdev->qplib_res, &qp->qplib_qp);
-	if (rc)
+	if (rc) {
 		ibdev_err(&rdev->ibdev, "Failed to destroy HW QP");
+		return rc;
+	}
 
 	if (rdma_is_kernel_res(&qp->ib_qp.res)) {
 		flags = bnxt_re_lock_cqs(qp);
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2025-09-18 10:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-16  9:11 [PATCH] drivers: fix the exception was not returned YanLong Dai
2025-09-16 13:49 ` Leon Romanovsky
2025-09-17  2:15   ` YanLong Dai
2025-09-17 11:35   ` [PATCH] drivers: fix the potential memory leak in bnxt_re_destroy_gsi_sqp() YanLong Dai
2025-09-18 10:02     ` Leon Romanovsky
2025-09-17 12:13   ` [PATCH v2] " YanLong Dai
2025-09-17 12:39   ` [PATCH v3] " YanLong Dai
2025-09-17 12:40   ` YanLong Dai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox