From: Ido Schimmel <idosch@idosch.org>
To: Andrew Lunn <andrew@lunn.ch>
Cc: netdev@vger.kernel.org, davem@davemloft.net, kuba@kernel.org,
jiri@mellanox.com, danieller@mellanox.com, mlxsw@mellanox.com,
michael.chan@broadcom.com, jeffrey.t.kirsher@intel.com,
saeedm@mellanox.com, leon@kernel.org, snelson@pensando.io,
drivers@pensando.io, vivien.didelot@gmail.com,
f.fainelli@gmail.com, Ido Schimmel <idosch@mellanox.com>
Subject: Re: [PATCH net-next 3/3] selftests: net: Add port split test
Date: Tue, 19 May 2020 21:56:42 +0300 [thread overview]
Message-ID: <20200519185642.GA1016583@splinter> (raw)
In-Reply-To: <20200519141541.GJ624248@lunn.ch>
On Tue, May 19, 2020 at 04:15:41PM +0200, Andrew Lunn wrote:
> > +# Test port split configuration using devlink-port width attribute.
> > +# The test is skipped in case the attribute is not available.
> > +#
> > +# First, check that all the ports with a width of 1 fail to split.
> > +# Second, check that all the ports with a width larger than 1 can be split
> > +# to all valid configurations (e.g., split to 2, split to 4 etc.)
>
> Hi Ido
Hi Andrew,
>
> I know very little about splitting ports. So these might be dumb
> questions.
>
> Is there a well defined meaning of width? Is it something which can be
> found in an 802.3 standard?
It's basically the number of lanes: If a port is a 100Gbps port and has
a width of 4, then every lane is running at 25Gbps. Splitting this port
to 4 (via 'devlink port split') allows you to get 4 ports each capable
of supporting speeds up to 25Gbps (the original netdev disappears).
Example splitter cable:
https://www.mellanox.com/related-docs/prod_cables/PB_MCP7F00-A0xxRyyz_100GbE_QSFP28_to_4x25GbE_4xSFP28_DAC_Splitter.pdf
Some documentation from mlxsw Wiki:
https://github.com/Mellanox/mlxsw/wiki/Switch-Port-Configuration#port-splitting
> Is it well defined that all splits of the for 2, 4, 8 have to be
> supported?
That I don't actually know. It is true for Mellanox and I can only
assume it holds for other vendors. So far beside mlxsw only nfp
implemented port_split() callback. I see it has this check:
```
if (eth_port.is_split || eth_port.port_lanes % count) {
ret = -EINVAL;
goto out;
}
```
So it seems to be consistent with mlxsw. Jakub will hopefully chime in
and keep me honest.
> Must all 40Gbps ports with a width of 4, be splitable to 2x
> 20Mps? It seems like some hardware might only allow 4x 10G?
Possible. There are many vendor-specific quirks in this area, as I'm
sure you know :)
>
> If 20Gbps is supported, can you then go recursive and split one of the
> 20G ports into 2x 10G, leaving the other as a 20G port?
Quite certain this is not supported by any vendor.
I assume you're asking because you are trying to see if the test is not
making some vendor-specific assumptions? Personally, I think it's not.
We decided to put it under net/ rather than drivers/net/mlxsw because we
always prefer to write tests that can be shared with others. This is
what actually motivated this work. We had a very Mellanox-specific test
in our regression and we wanted to remove it, but it was not possible to
write such a test without this attribute.
next prev parent reply other threads:[~2020-05-19 18:56 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-19 13:40 [PATCH net-next 0/3] devlink: Add port width attribute Ido Schimmel
2020-05-19 13:40 ` [PATCH net-next 1/3] mlxsw: Set port width attribute in driver Ido Schimmel
2020-05-19 13:40 ` [PATCH net-next 2/3] devlink: Add a new devlink port width attribute and pass to netlink Ido Schimmel
2020-05-19 19:24 ` Shannon Nelson
2020-05-19 13:40 ` [PATCH net-next 3/3] selftests: net: Add port split test Ido Schimmel
2020-05-19 14:15 ` Andrew Lunn
2020-05-19 18:56 ` Ido Schimmel [this message]
2020-05-19 19:33 ` Andrew Lunn
2020-05-20 13:43 ` Ido Schimmel
2020-05-20 13:53 ` Jiri Pirko
2020-05-20 15:23 ` Danielle Ratson
2020-05-22 0:03 ` [PATCH net-next 0/3] devlink: Add port width attribute David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200519185642.GA1016583@splinter \
--to=idosch@idosch.org \
--cc=andrew@lunn.ch \
--cc=danieller@mellanox.com \
--cc=davem@davemloft.net \
--cc=drivers@pensando.io \
--cc=f.fainelli@gmail.com \
--cc=idosch@mellanox.com \
--cc=jeffrey.t.kirsher@intel.com \
--cc=jiri@mellanox.com \
--cc=kuba@kernel.org \
--cc=leon@kernel.org \
--cc=michael.chan@broadcom.com \
--cc=mlxsw@mellanox.com \
--cc=netdev@vger.kernel.org \
--cc=saeedm@mellanox.com \
--cc=snelson@pensando.io \
--cc=vivien.didelot@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.