From: Jason Gunthorpe <jgg@ziepe.ca>
To: Colin King <colin.king@canonical.com>
Cc: Doug Ledford <dledford@redhat.com>,
Leon Romanovsky <leon@kernel.org>,
linux-rdma@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] RDMA/ucma: fix memory leak of mc on an xa_alloc failure
Date: Wed, 2 Sep 2020 20:59:09 -0300 [thread overview]
Message-ID: <20200902235909.GK24045@ziepe.ca> (raw)
In-Reply-To: <20200902162805.200436-1-colin.king@canonical.com>
On Wed, Sep 02, 2020 at 05:28:05PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Currently when an xa_alloc failure occurs the error exit path leaks
> the allocated object mc. Fix this by adding an error return path
> that frees mc and rename error exit paths err3 to err4 and err2 to err3.
>
> Fixes: 95fe51096b7a ("RDMA/ucma: Remove mc_list and rely on xarray")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> drivers/infiniband/core/ucma.c | 11 ++++++-----
> 1 file changed, 6 insertions(+), 5 deletions(-)
Alex beat you too it, so I will use his patch, thanks
Jason
prev parent reply other threads:[~2020-09-02 23:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-02 16:28 Colin King
2020-09-02 23:59 ` 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=20200902235909.GK24045@ziepe.ca \
--to=jgg@ziepe.ca \
--cc=colin.king@canonical.com \
--cc=dledford@redhat.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
/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
all inboxes | Powered by JetHome®