From: Jason Gunthorpe <jgg@nvidia.com>
To: Miaoqian Lin <linmq006@gmail.com>
Cc: Leon Romanovsky <leon@kernel.org>,
Mark Zhang <markzhang@nvidia.com>,
Maor Gottlieb <maorg@nvidia.com>,
Weihang Li <liweihang@huawei.com>,
Wenpeng Liang <liangwenpeng@huawei.com>,
linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] RDMA/cm: Fix memory leak in ib_cm_insert_listen
Date: Fri, 24 Jun 2022 16:44:32 -0300 [thread overview]
Message-ID: <20220624194432.GA281681@nvidia.com> (raw)
In-Reply-To: <20220621052546.4821-1-linmq006@gmail.com>
On Tue, Jun 21, 2022 at 09:25:44AM +0400, Miaoqian Lin wrote:
> cm_alloc_id_priv() allocates resource for cm_id_priv.
> when cm_init_listen() fails, it doesn't free it,
> leading to memory leak. call ib_destroy_cm_id() to fix this.
>
> Fixes: 98f67156a80f ("RDMA/cm: Simplify establishing a listen cm_id")
> Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
> ---
> drivers/infiniband/core/cm.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
Applied to for-rc, thanks
Jason
prev parent reply other threads:[~2022-06-24 19:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-21 5:25 [PATCH] RDMA/cm: Fix memory leak in ib_cm_insert_listen Miaoqian Lin
2022-06-24 19:44 ` 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=20220624194432.GA281681@nvidia.com \
--to=jgg@nvidia.com \
--cc=leon@kernel.org \
--cc=liangwenpeng@huawei.com \
--cc=linmq006@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=liweihang@huawei.com \
--cc=maorg@nvidia.com \
--cc=markzhang@nvidia.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