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: <YZ6syUqWKoXJiQGv@shell.armlinux.org.uk>
Date:   Wed, 24 Nov 2021 21:21:13 +0000
From:   "Russell King (Oracle)" <linux@...linux.org.uk>
To:     Vladimir Oltean <vladimir.oltean@....com>
Cc:     Andrew Lunn <andrew@...n.ch>,
        Florian Fainelli <f.fainelli@...il.com>,
        Vivien Didelot <vivien.didelot@...il.com>,
        Vladimir Oltean <olteanv@...il.com>,
        Alexandre Belloni <alexandre.belloni@...tlin.com>,
        Claudiu Manoil <claudiu.manoil@....com>,
        George McCollister <george.mccollister@...il.com>,
        Hauke Mehrtens <hauke@...ke-m.de>,
        Kurt Kanzenbach <kurt@...utronix.de>,
        Woojung Huh <woojung.huh@...rochip.com>,
        "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "UNGLinuxDriver@...rochip.com" <UNGLinuxDriver@...rochip.com>
Subject: Re: [PATCH RFC net-next 09/12] net: dsa: ocelot: convert to
 phylink_generic_validate()

On Wed, Nov 24, 2021 at 08:07:49PM +0000, Vladimir Oltean wrote:
> On Wed, Nov 24, 2021 at 05:53:09PM +0000, Russell King (Oracle) wrote:
> > Populate the supported interfaces and MAC capabilities for the Ocelot
> > DSA switches and remove the old validate implementation to allow DSA to
> > use phylink_generic_validate() for this switch driver.
> > 
> > The felix_vsc9959 and seville_vsc9953 sub-drivers only supports a
> > single interface mode, defined by ocelot_port->phy_mode, so we indicate
> > only this interface mode to phylink. Since phylink restricts the
> > ethtool link modes based on interface, we do not need to make the MAC
> > capabilities dependent on the interface mode.
> 
> Yes, and this driver cannot make use of phylink_generic_validate()
> unless something changes in phylink_get_linkmodes(). You've said a
> number of times that PHY rate adaptation via PAUSE frames is not
> something that is supported, yet it works with 2500base-x and the felix
> driver, and we use this functionality on LS1028A-QDS boards and the
> AQR412 PHY, and customer boards using LS1028A probably use it too. See
> this comment in ocelot_phylink_mac_link_up():

I'll drop this for now, since the issues around rate adaption should
not be handled by phylink_generic_validate(). The point of this
generic helper is to deal with the common case.

We don't get have a way of knowing that the PHY is using rate adaption,
and when rate adaption is in use, it changes the requirements for the
validation path quite substantially. So, we need:

1) phylib to be able to tell us that rate adaption is happening on the
   PHY.
2) change the way we restrict the PHY support/advertisements when
   rate adaption is in use.

I view this as an entirely separate change to this series; it needs to
change in phylink_bringup_phy(), where the restriction is applied to
the PHY, and not in phylink_validate() or below that function.

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