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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220215094549.7no3e2repjvpunyk@skbuf>
Date:   Tue, 15 Feb 2022 09:45:50 +0000
From:   Vladimir Oltean <vladimir.oltean@....com>
To:     Alexey Khoroshilov <khoroshilov@...ras.ru>
CC:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "stable@...r.kernel.org" <stable@...r.kernel.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Sasha Levin <sashal@...nel.org>
Subject: Re: [PATCH 5.10 073/116] net: dsa: lantiq_gswip: dont use devres for
 mdiobus

On Tue, Feb 15, 2022 at 12:35:44PM +0300, Alexey Khoroshilov wrote:
> >  	if (priv->ds->slave_mii_bus) {
> >  		mdiobus_unregister(priv->ds->slave_mii_bus);
> > +		mdiobus_free(priv->ds->slave_mii_bus);
> >  		of_node_put(priv->ds->slave_mii_bus->dev.of_node);
> >  	}
> 
> 
> Should
>   of_node_put(priv->ds->slave_mii_bus->dev.of_node);
> be here before
>   mdiobus_free(priv->ds->slave_mii_bus);
> ?

Thanks for noticing. Yes, this would avoid a use-after-free.
Do you mind sending a patch to correct this?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ