From: Jason Gunthorpe <jgg@ziepe.ca>
To: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
Cc: Lijun Ou <oulijun@huawei.com>,
"Wei Hu(Xavier)" <huwei87@hisilicon.com>,
Weihang Li <liweihang@huawei.com>,
Doug Ledford <dledford@redhat.com>, Xi Wang <wangxi11@huawei.com>,
linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2][next] RDMA/hns: Fix uninitialized variable bug
Date: Sun, 29 Mar 2020 11:10:48 -0300 [thread overview]
Message-ID: <20200329141048.GA27740@ziepe.ca> (raw)
In-Reply-To: <20200328023539.GA32016@embeddedor>
On Fri, Mar 27, 2020 at 09:35:39PM -0500, Gustavo A. R. Silva wrote:
> There is a potential execution path in which variable *ret* is returned
> without being properly initialized, previously.
>
> Fix this by initializing variable *ret* to 0.
>
> Addresses-Coverity-ID: 1491917 ("Uninitialized scalar variable")
> Fixes: 2f49de21f3e9 ("RDMA/hns: Optimize mhop get flow for multi-hop addressing")
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
> Acked-by: Weihang Li <liweihang@huawei.com>
> ---
> Changes in v2:
> - Set ret to 0 instead of -ENODEV. Thanks Weihang Li, for the feedback.
>
> drivers/infiniband/hw/hns/hns_roce_hem.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to for-next, thanks
Jason
prev parent reply other threads:[~2020-03-29 14:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-28 2:35 [PATCH v2][next] RDMA/hns: Fix uninitialized variable bug Gustavo A. R. Silva
2020-03-28 3:02 ` liweihang
2020-03-29 14:10 ` Jason Gunthorpe [this message]
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=20200329141048.GA27740@ziepe.ca \
--to=jgg@ziepe.ca \
--cc=dledford@redhat.com \
--cc=gustavo@embeddedor.com \
--cc=huwei87@hisilicon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=liweihang@huawei.com \
--cc=oulijun@huawei.com \
--cc=wangxi11@huawei.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;
as well as URLs for NNTP newsgroup(s).