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]
Date:   Thu, 14 Jul 2022 13:39:00 +0100
From:   "Russell King (Oracle)" <linux@...linux.org.uk>
To:     Oleksandr Mazur <oleksandr.mazur@...ision.eu>
Cc:     Andrew Lunn <andrew@...n.ch>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "davem@...emloft.net" <davem@...emloft.net>,
        "edumazet@...gle.com" <edumazet@...gle.com>,
        "kuba@...nel.org" <kuba@...nel.org>,
        "pabeni@...hat.com" <pabeni@...hat.com>,
        Yevhen Orlov <yevhen.orlov@...ision.eu>,
        Taras Chornyi <taras.chornyi@...ision.eu>
Subject: Re: [PATCH V2 net-next] net: marvell: prestera: add phylink support

On Thu, Jul 14, 2022 at 08:56:26AM +0000, Oleksandr Mazur wrote:
> Hello Andrew, Russel,
> Thanks for the input and sorry for the inconviniences.
> 
> >First question which applies to everything in this patch is - why make
> >phylink conditional for this driver?
> 
> 1. As for the phylink ifdefs:
> The original idea was to support mac config on devices (DB boards) that don't have full sfp support on board, however we scrapped out
> this idea as we could simply use fixed-link DTS configs; also due to this solution being non-upstream-friendly.
> Please note that V2 holds no phylink ifdefs;

I didn't specifically ask about the ifdefs - I asked the general
question about "why make phylink conditional for this driver".
Yes, v1 had ifdefs. v2 does not, but phylink is _still_ conditional.
You are introduing lots of this pattern of code:

	if (blah->phy_link)
		do something phylink related
	else
		do something else

And I want to know why.

> >In SGMII mode, it is normal for the advertising
> >mask to indicate the media modes on the PHY to advertise
> 2. As for the SGMII mode, yes, Russel, you're right; V3 will hold a fix for this, and keep the inband enabled for SGMII.
> 
> >No way to restart 1000base-X autoneg?
> 3. As for AN restart, no, it's not yet supported by our FW as of now.

Maybe put a comment in the code to that effect?

> >I think you should be calling phylink_mac_change() here, rather than
> >below.
> 
> 4. V3 is gonna fix this, thanks for the input.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ