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]
Message-ID: <20240930090817.0a86e538@collabora.com>
Date: Mon, 30 Sep 2024 09:08:17 +0200
From: Boris Brezillon <boris.brezillon@...labora.com>
To: "Dr. David Alan Gilbert" <linux@...blig.org>
Cc: nicolas.ferre@...rochip.com, miquel.raynal@...tlin.com, richard@....at,
 linux-mtd@...ts.infradead.org, linux-arm-kernel@...ts.infradead.org,
 linux-kernel@...r.kernel.org
Subject: Re: of atmel_pmecc_destroy_user

Hi David,

On Sun, 29 Sep 2024 17:05:01 +0000
"Dr. David Alan Gilbert" <linux@...blig.org> wrote:

> Hi Boris and co,
>   One of my scripts noticed that 'atmel_pmecc_destroy_user'
> isn't called anywhere; I was going to delete it, but hmm, I wonder
> if it's actually a missing call and leaking (in the unlikely case
> the device was ever removed).
> 
> It was added by your:
>   commit f88fc122cc34c2545dec9562eaab121494e401ef
>   Author: Boris Brezillon <bbrezillon@...nel.org>
>   Date:   Thu Mar 16 09:02:40 2017 +0100
> 
>     mtd: nand: Cleanup/rework the atmel_nand driver
> 
> and I see the allocation in:
>      user = kzalloc(size, GFP_KERNEL);
>        in
>      nand->pmecc = atmel_pmecc_create_user(nc->pmecc, &req);
>        called in atmel_nand_pmecc_init
>          from atmel_nand_ecc_init
>            from atmel_hsmc_nand_ecc_init
>  
> But I don't see any freeing.
> 
> (I don't knowingly have hardware to test a fix, although I guess
> there's probably one somewhere....)
> 
> Suggestions?

There's definitely a leak. I haven't looked at NAND stuff for a while
though, so I'll let Miquel advise you on where
atmel_pmecc_destroy_user() should be called.

Regards,

Boris

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ