lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 18 Jul 2022 14:03:45 +0300
From:   Leon Romanovsky <leon@...nel.org>
To:     Jianglei Nie <niejianglei2021@....com>
Cc:     mkalderon@...vell.com, aelior@...vell.com, jgg@...pe.ca,
        linux-rdma@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] RDMA/qedr: Fix potential memory leak in __qedr_alloc_mr()

On Thu, Jul 14, 2022 at 02:15:05PM +0800, Jianglei Nie wrote:
> __qedr_alloc_mr() allocates a memory chunk for "mr->info.pbl_table" with
> init_mr_info(). When rdma_alloc_tid() and rdma_register_tid() fail, "mr"
> is released while "mr->info.pbl_table" is not released, which will lead
> to a memory leak.
> 
> We should release the "mr->info.pbl_table" with qedr_free_pbl() when error
> occurs to fix the memory leak.
> 
> Signed-off-by: Jianglei Nie <niejianglei2021@....com>
> ---
>  drivers/infiniband/hw/qedr/verbs.c | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 

Added fixes line.
Fixes: e0290cce6ac0 ("qedr: Add support for memory registeration verbs")

Thanks, applied.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ