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:   Wed, 14 Jun 2023 09:35:02 +0200
From:   Christian Marangi <ansuelsmth@...il.com>
To:     Jose Abreu <Jose.Abreu@...opsys.com>
Cc:     Giuseppe Cavallaro <peppe.cavallaro@...com>,
        Alexandre Torgue <alexandre.torgue@...s.st.com>,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>,
        Maxime Coquelin <mcoquelin.stm32@...il.com>,
        Russell King <linux@...linux.org.uk>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-stm32@...md-mailman.stormreply.com" 
        <linux-stm32@...md-mailman.stormreply.com>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [net-next PATCH v5 4/5] net: ethernet: stmicro: stmmac: generate
 stmmac dma conf before open

On Wed, Jun 14, 2023 at 01:48:40PM +0000, Jose Abreu wrote:
> From: Christian Marangi <ansuelsmth@...il.com>
> Date: Wed, Jun 14, 2023 at 03:16:08
> 
> > I'm not following the meaning of leak here. If it's intended as a memory
> > leak then dma_conf is correctly freed in the 2 user of __stmmac_open.
> > 
> > stmmac_init_phy also doesn't seems to use dma_conf. Am I missing
> > something here?
> > 
> 
> Sorry, I should have been clearer: It's not leaking the dma_conf per-se but
> the contents of it: The DMA descriptors. Since the memcpy() is only done after
> init_phy(); if init_phy() fails, then stmmac will never free up the DMA descriptors.
> 
> Does it make sense?
> 

Thanks for the clarification! Sent a follow-up patch that should fix the
possible leak. Would be good if you can also test it for a Tested-by
tag.

-- 
	Ansuel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ