From: Cheng Xu <chengyou@linux.alibaba.com>
To: Markus Elfring <Markus.Elfring@web.de>,
linux-rdma@vger.kernel.org, Jason Gunthorpe <jgg@ziepe.ca>,
Kai Shen <kaishen@linux.alibaba.com>,
Leon Romanovsky <leon@kernel.org>,
Yang Li <yang.lee@linux.alibaba.com>
Cc: LKML <linux-kernel@vger.kernel.org>, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH v2] RDMA/erdma: Fix exception handling in erdma_accept_newconn()
Date: Mon, 17 Mar 2025 10:27:32 +0800 [thread overview]
Message-ID: <67a12e7e-51ff-36bf-a575-b77c09b56110@linux.alibaba.com> (raw)
In-Reply-To: <2e9ae1d6-4bbb-470f-957f-bb6ea2e0829e@web.de>
On 3/13/25 8:10 PM, Markus Elfring wrote:
> From: Markus Elfring <elfring@users.sourceforge.net>
> Date: Thu, 13 Mar 2025 11:44:50 +0100
>
> The label “error” was used to jump to another pointer check despite of
> the detail in the implementation of the function “erdma_accept_newconn”
> that it was determined already that corresponding variables contained
> still null pointers.
>
> 1. Thus return directly if
> * the cep state is not the value “ERDMA_EPSTATE_LISTENING”
> or
> * a call of the function “erdma_cep_alloc” failed.
>
> 2. Use more appropriate labels instead.
>
> 3. Delete two questionable checks.
>
> 4. Omit extra initialisations (for the variables “new_cep”, “new_s” and “ret”)
> which became unnecessary with this refactoring.
>
>
> This issue was detected by using the Coccinelle software.
>
> Fixes: 920d93eac8b9 ("RDMA/erdma: Add connection management (CM) support")
I think this patch does not fix issues, so fix line is not needed.
Thanks,
Cheng Xu
> Cc: stable@vger.kernel.org
> Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
> ---
<...>
prev parent reply other threads:[~2025-03-17 2:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-13 12:10 [PATCH v2] RDMA/erdma: Fix exception handling in erdma_accept_newconn() Markus Elfring
2025-03-17 2:27 ` Cheng Xu [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=67a12e7e-51ff-36bf-a575-b77c09b56110@linux.alibaba.com \
--to=chengyou@linux.alibaba.com \
--cc=Markus.Elfring@web.de \
--cc=jgg@ziepe.ca \
--cc=kaishen@linux.alibaba.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=yang.lee@linux.alibaba.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