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:   Wed, 22 May 2019 19:26:25 -0700
From:   Florian Fainelli <f.fainelli@...il.com>
To:     Ioana Ciornei <ioana.ciornei@....com>,
        "linux@...linux.org.uk" <linux@...linux.org.uk>,
        "andrew@...n.ch" <andrew@...n.ch>,
        "hkallweit1@...il.com" <hkallweit1@...il.com>,
        "maxime.chevallier@...tlin.com" <maxime.chevallier@...tlin.com>,
        "olteanv@...il.com" <olteanv@...il.com>
Cc:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "davem@...emloft.net" <davem@...emloft.net>
Subject: Re: [RFC PATCH net-next 9/9] net: dsa: sja1105: Fix broken fixed-link
 interfaces on user ports



On 5/22/2019 6:20 PM, Ioana Ciornei wrote:
> From: Vladimir Oltean <olteanv@...il.com>
> 
> PHYLIB and PHYLINK handle fixed-link interfaces differently. PHYLIB
> wraps them in a software PHY ("pseudo fixed link") phydev construct such
> that .adjust_link driver callbacks see an unified API. Whereas PHYLINK
> simply creates a phylink_link_state structure and passes it to
> .mac_config.
> 
> At the time the driver was introduced, DSA was using PHYLIB for the
> CPU/cascade ports (the ones with no net devices) and PHYLINK for
> everything else.
> 
> As explained below:
> 
> commit aab9c4067d2389d0adfc9c53806437df7b0fe3d5
> Author: Florian Fainelli <f.fainelli@...il.com>
> Date:   Thu May 10 13:17:36 2018 -0700
> 
>   net: dsa: Plug in PHYLINK support
> 
>   Drivers that utilize fixed links for user-facing ports (e.g: bcm_sf2)
>   will need to implement phylink_mac_ops from now on to preserve
>   functionality, since PHYLINK *does not* create a phy_device instance
>   for fixed links.
> 
> In the above patch, DSA guards the .phylink_mac_config callback against
> a NULL phydev pointer.  Therefore, .adjust_link is not called in case of
> a fixed-link user port.
> 
> This patch fixes the situation by converting the driver from using
> .adjust_link to .phylink_mac_config.  This can be done now in a unified
> fashion for both slave and CPU/cascade ports because DSA now uses
> PHYLINK for all ports.
> 
> Signed-off-by: Vladimir Oltean <olteanv@...il.com>
> Signed-off-by: Ioana Ciornei <ioana.ciornei@....com>

Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
-- 
Florian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ