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] [day] [month] [year] [list]
Date:   Fri, 4 Jun 2021 06:53:42 +0000
From:   "Voon, Weifeng" <weifeng.voon@...el.com>
To:     Vladimir Oltean <olteanv@...il.com>,
        "Sit, Michael Wei Hong" <michael.wei.hong.sit@...el.com>
CC:     "Jose.Abreu@...opsys.com" <Jose.Abreu@...opsys.com>,
        "andrew@...n.ch" <andrew@...n.ch>,
        "hkallweit1@...il.com" <hkallweit1@...il.com>,
        "linux@...linux.org.uk" <linux@...linux.org.uk>,
        "kuba@...nel.org" <kuba@...nel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "peppe.cavallaro@...com" <peppe.cavallaro@...com>,
        "alexandre.torgue@...s.st.com" <alexandre.torgue@...s.st.com>,
        "davem@...emloft.net" <davem@...emloft.net>,
        "mcoquelin.stm32@...il.com" <mcoquelin.stm32@...il.com>,
        "Ong, Boon Leong" <boon.leong.ong@...el.com>,
        "Tan, Tee Min" <tee.min.tan@...el.com>,
        "vee.khee.wong@...ux.intel.com" <vee.khee.wong@...ux.intel.com>,
        "Wong, Vee Khee" <vee.khee.wong@...el.com>,
        "linux-stm32@...md-mailman.stormreply.com" 
        <linux-stm32@...md-mailman.stormreply.com>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [RESEND PATCH net-next v4 1/3] net: stmmac: split xPCS setup from
 mdio register

> @@ -7002,6 +7006,9 @@ int stmmac_dvr_probe(struct device *device,
>  		}
>  	}
> 
> +	if (priv->plat->speed_mode_2500)
> +		pri*v->plat->speed_mode_2500(ndev, priv->plat->bsp_priv);
> +
>  	if (priv->plat->mdio_bus_data->has_xpcs) {
>  		ret = stmmac_xpcs_setup(priv->mii);
>  		if (ret)
> 
> With the current placement, there seems to be indeed no way for the
> platform-level code to set plat->phy_interface after the MDIO bus has
> probed but before the XPCS has probed.
> 
> I wonder whether it might be possible to probe the XPCS completely
> outside of stmmac_dvr_probe(); once that function ends you should have
> all knowledge necessary to set plat->phy_interface all within the
> Intel platform code. An additional benefit if you do this is that you
> no longer need the has_xpcs variable - Intel is the only one setting
> it right now, as far as I can see. What do you think?

Hi Vladimir, I still think that stmmac_dvr_probe() the suitable place to
probe the XPCS together with MDIO and PHY setup. In addition, XPCS also
need to be probed before stmmac_open()as there is an checking of XPCS AN
mode at the very beginning of the function. 

The has_xpcs variable is introduced in the very first commits in the XPCS design.
Although currently Intel is the only one using it, it is beneficial for any
future system that pair stmmac with xpcs.  

Weifeng

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ