Subject: Re: [PATCH net-next 3/3] selftests: mlxsw: Add speed and auto-negotiation test

From: Ido Schimmel <[email-masked]>
Date: Tue, 11 Jun 2019 16:06:05 +0300

On Tue, Jun 11, 2019 at 02:22:55PM +0200, Andrew Lunn wrote:
> On Tue, Jun 11, 2019 at 09:35:26AM +0300, Ido Schimmel wrote:
> > On Mon, Jun 10, 2019 at 04:06:33PM +0200, Andrew Lunn wrote:
> > > On Mon, Jun 10, 2019 at 04:58:48PM +0300, Ido Schimmel wrote:
> > > > On Mon, Jun 10, 2019 at 03:48:20PM +0200, Andrew Lunn wrote:
> > > > > > +		# Skip 56G because this speed isn't supported with autoneg off.
> > > > > > +		if [[ $speed == 56000 ]]; then
> > > > > > +			continue
> > > > > > +		fi
> > > > > 
> > > > > Interesting. How is 56000 represented in ethtool? Listed in both
> > > > > "Supported link modes" and "Advertised link modes"?
> > > > 
> > > > Hi Andrew,
> > > > 
> > > > Yes. We recently sent a patch to error out if autoneg is off: Commit
> > > > 275e928f1911 ("mlxsw: spectrum: Prevent force of 56G").
> > > 
> > > I never get access to high speed links like this. Do you have a
> > > reference to why 56G needs auto-neg? What makes it different to every
> > > other link mode?
> > 
> > Hi Andrew,
> > 
> > I verified with PHY engineers and this limitation is specific to our
> > hardware, so no external reference I can provide.
> 
> Hi Ido
> 
> Could you detect your own hardware and only enable this exception when
> needed?

The test currently resides under
tools/testing/selftests/drivers/net/mlxsw/, so it's specific to mlxsw.

I believe the 56G quirk is the only thing in the test that is specific
to mlxsw. Should be possible to move it to
tools/testing/selftests/net/forwarding/ and skip 56G for mlxsw.