From: Zhu Yanjun <yanjun.zhu@linux.dev>
To: Leon Romanovsky <leon@kernel.org>, Zhu Yanjun <yanjun.zhu@intel.com>
Cc: haris.iqbal@ionos.com, jinpu.wang@ionos.com, jgg@ziepe.ca,
linux-rdma@vger.kernel.org
Subject: Re: [PATCH 1/1] RDMA/rtrs: Fix the problem of variable not initialized fully
Date: Tue, 19 Sep 2023 16:26:54 +0800 [thread overview]
Message-ID: <01d9dd18-3d63-fabb-33d4-0de528f15a9a@linux.dev> (raw)
In-Reply-To: <20230919081712.GD4494@unreal>
在 2023/9/19 16:17, Leon Romanovsky 写道:
> On Tue, Sep 19, 2023 at 10:08:06AM +0800, Zhu Yanjun wrote:
>> From: Zhu Yanjun <yanjun.zhu@linux.dev>
>>
>> No functionality change. The variable which is not initialized fully
>> will introduce potential risks.
> Are you sure about not being initialized?
About this problem, I think we discussed it previously in RDMA maillist.
And at that time, IIRC, you shared a link with me. The link is as below.
https://www.ex-parrot.com/~chris/random/initialise.html
From what we discussed and the above link, I think it is not
initialized fully.
Zhu Yanjun
>
> Thanks
>
>> 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
>>
next prev parent reply other threads:[~2023-09-19 8:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
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 [this message]
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
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=01d9dd18-3d63-fabb-33d4-0de528f15a9a@linux.dev \
--to=yanjun.zhu@linux.dev \
--cc=haris.iqbal@ionos.com \
--cc=jgg@ziepe.ca \
--cc=jinpu.wang@ionos.com \
--cc=leon@kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=yanjun.zhu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox