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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200921180634.icsurl6qoz4nmz3n@skbuf>
Date:   Mon, 21 Sep 2020 18:06:34 +0000
From:   Ioana Ciornei <ioana.ciornei@....com>
To:     Andrew Lunn <andrew@...n.ch>
CC:     "davem@...emloft.net" <davem@...emloft.net>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux@...linux.org.uk" <linux@...linux.org.uk>
Subject: Re: [PATCH net-next 3/3] dpaa2-mac: add PCS support through the Lynx
 module

On Mon, Sep 21, 2020 at 07:07:21PM +0200, Andrew Lunn wrote:
> On Mon, Sep 21, 2020 at 07:20:31PM +0300, Ioana Ciornei wrote:
> > +static void dpaa2_pcs_destroy(struct dpaa2_mac *mac)
> > +{
> > +	struct lynx_pcs *pcs = mac->pcs;
> > +
> > +	if (pcs) {
> > +		put_device(&pcs->mdio->dev);
> > +		lynx_pcs_destroy(pcs);
> > +		mac->pcs = NULL;
> 
> Hi Ioana
> 
> Maybe the put_device() should come after the destroy? It is then the
> reverse of the creation.
> 
> 	Andrew

Hi Andrew,

The lynx_pcs_destroy() function doesn't do much with the pcs, just a
kfree on it. I did it this way to avoid keeping the device in a
temporary variable but if you think we should do this in a symetrical
way, I can make the change.

Ioana

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ