public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] RDMA/rtrs: Fix the problem of variable not initialized fully
@ 2023-09-19  2:08 Zhu Yanjun
  2023-09-19  8:17 ` Leon Romanovsky
  2023-09-19  9:30 ` Leon Romanovsky
  0 siblings, 2 replies; 9+ messages in thread
From: Zhu Yanjun @ 2023-09-19  2:08 UTC (permalink / raw)
  To: haris.iqbal, jinpu.wang, jgg, leon, linux-rdma; +Cc: Zhu Yanjun

From: Zhu Yanjun <yanjun.zhu@linux.dev>

No functionality change. The variable which is not initialized fully
will introduce potential risks.

Signed-off-by: Zhu Yanjun <yanjun.zhu@linux.dev>
---
 drivers/infiniband/ulp/rtrs/rtrs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/infiniband/ulp/rtrs/rtrs.c b/drivers/infiniband/ulp/rtrs/rtrs.c
index 3696f367ff51..d80edfffd2e4 100644
--- a/drivers/infiniband/ulp/rtrs/rtrs.c
+++ b/drivers/infiniband/ulp/rtrs/rtrs.c
@@ -255,7 +255,7 @@ static int create_cq(struct rtrs_con *con, int cq_vector, int nr_cqe,
 static int create_qp(struct rtrs_con *con, struct ib_pd *pd,
 		     u32 max_send_wr, u32 max_recv_wr, u32 max_sge)
 {
-	struct ib_qp_init_attr init_attr = {NULL};
+	struct ib_qp_init_attr init_attr = {};
 	struct rdma_cm_id *cm_id = con->cm_id;
 	int ret;
 
-- 
2.40.1


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

end of thread, other threads:[~2023-09-20 15:34 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-19  2:08 [PATCH 1/1] RDMA/rtrs: Fix the problem of variable not initialized fully Zhu Yanjun
2023-09-19  8:17 ` Leon Romanovsky
2023-09-19  8:26   ` Zhu Yanjun
2023-09-19  9:30     ` Leon Romanovsky
2023-09-20  2:16       ` Zhijian Li (Fujitsu)
2023-09-20  5:46         ` Jinpu Wang
2023-09-20  7:47         ` Leon Romanovsky
2023-09-20 15:34           ` Jason Gunthorpe
2023-09-19  9:30 ` Leon Romanovsky

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