Skip to content

selftests: Add ethtool and scale tests

Ido Schimmel netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5selftests: mlxsw: Add router scale test for Spectrum-2tools/testing/selftests/drivers/net/mlxsw/spectrum-2/resource_scale.sh tools/testing/selftests/drivers/net/mlxsw/spectrum-2/router_scale.sh+22 -10 replies
2/5selftests: mlxsw: Check devlink device before running testtools/testing/selftests/drivers/net/mlxsw/spectrum-2/resource_scale.sh+5 -00 replies
3/5selftests: forwarding: Add ethtool_lib.shtools/testing/selftests/net/forwarding/ethtool_lib.sh+69 -00 replies
4/5selftests: forwarding: lib.sh: Add wait for dev with timeouttools/testing/selftests/net/forwarding/lib.sh+26 -30 replies
5/5selftests: forwarding: Add speed and auto-negotiation testtools/testing/selftests/net/forwarding/ethtool.sh+318 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH net-next 0/5] selftests: Add ethtool and scale tests

From: Ido Schimmel <[email protected]>

This patch set adds generic ethtool tests and a mlxsw-specific router scale test for Spectrum-2.

Patches #1-#2 from Danielle add the router scale test for Spectrum-2. It re-uses the same test as Spectrum-1, but it is invoked with a different scale, according to what it is queried from devlink-resource.

Patches #3-#5 from Amit are a re-work of the ethtool tests that were posted in the past [1]. Patches #3-#4 add the necessary library routines, whereas patch #5 adds the test itself. The test checks both good and bad flows with autoneg on and off. The test plan it detailed in the commit message.

Last time Andrew and Florian (copied) provided very useful feedback that is incorporated in this set. Namely:

* Parse the value of the different link modes from /usr/include/linux/ethtool.h
* Differentiate between supported and advertised speeds and use the latter in autoneg tests
* Make the test generic and move it to net/forwarding/ instead of being mlxsw-specific

[1] https://patchwork.ozlabs.org/cover/1112903/

Amit Cohen (3):
selftests: forwarding: Add ethtool_lib.sh
selftests: forwarding: lib.sh: Add wait for dev with timeout
selftests: forwarding: Add speed and auto-negotiation test

Danielle Ratson (2):
selftests: mlxsw: Add router scale test for Spectrum-2
selftests: mlxsw: Check devlink device before running test

 .../net/mlxsw/spectrum-2/resource_scale.sh    |  10 +-
 .../net/mlxsw/spectrum-2/router_scale.sh      |  18 +
 .../selftests/net/forwarding/ethtool.sh       | 318 ++++++++++++++++++
 .../selftests/net/forwarding/ethtool_lib.sh   |  69 ++++
 tools/testing/selftests/net/forwarding/lib.sh |  29 +-
 5 files changed, 440 insertions(+), 4 deletions(-)
 create mode 100644 tools/testing/selftests/drivers/net/mlxsw/spectrum-2/router_scale.sh
 create mode 100755 tools/testing/selftests/net/forwarding/ethtool.sh
 create mode 100755 tools/testing/selftests/net/forwarding/ethtool_lib.sh
Signature · 1 line
2.21.0