From: Dimitri Daskalakis <dimitri.daskalakis1@gmail.com>
To: "David S . Miller" <davem@davemloft.net>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Shuah Khan <shuah@kernel.org>, Simon Horman <horms@kernel.org>,
Willem de Bruijn <willemb@google.com>,
Stanislav Fomichev <sdf@fomichev.me>,
Daniel Zahka <daniel.zahka@gmail.com>,
Carolina Jubran <cjubran@nvidia.com>,
Gal Pressman <gal@nvidia.com>, David Wei <dw@davidwei.uk>,
Mohsin Bashir <mohsin.bashr@gmail.com>,
Nimrod Oren <noren@nvidia.com>, Breno Leitao <leitao@debian.org>,
Petr Machata <petrm@nvidia.com>,
netdev@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: [PATCH net-next 0/2] Add selftests helper to get N unique ports
Date: Tue, 24 Feb 2026 14:46:57 -0800 [thread overview]
Message-ID: <20260224224659.1507082-1-dimitri.daskalakis1@gmail.com> (raw)
The rss_ctx.py tests would occasionally flake. I found that the successive
calls to rand_port would occasionally return duplicate ports, breaking the
tests invariants.
Add a new helper that guarantees generated ports are unique.
Dimitri Daskalakis (2):
selftests: net: py: Add rand_ports helper method
selftests: drv-net: rss: Generate unique ports for RSS context tests
.../drivers/net/hw/lib/py/__init__.py | 5 ++--
.../selftests/drivers/net/hw/rss_ctx.py | 13 +++++-----
.../selftests/drivers/net/lib/py/__init__.py | 4 ++--
.../testing/selftests/net/lib/py/__init__.py | 5 ++--
tools/testing/selftests/net/lib/py/utils.py | 24 ++++++++++++++++---
5 files changed, 35 insertions(+), 16 deletions(-)
--
2.47.3
next reply other threads:[~2026-02-24 22:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-24 22:46 Dimitri Daskalakis [this message]
2026-02-24 22:46 ` [PATCH net-next 1/2] selftests: net: py: Add rand_ports helper method Dimitri Daskalakis
2026-02-24 22:46 ` [PATCH net-next 2/2] selftests: drv-net: rss: Generate unique ports for RSS context tests Dimitri Daskalakis
2026-02-26 7:23 ` [PATCH net-next 2/2] selftests: drv-net: rss: Generate unique ports for RSS context tests: manual merge Matthieu Baerts
2026-02-26 4:00 ` [PATCH net-next 0/2] Add selftests helper to get N unique ports patchwork-bot+netdevbpf
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=20260224224659.1507082-1-dimitri.daskalakis1@gmail.com \
--to=dimitri.daskalakis1@gmail.com \
--cc=andrew+netdev@lunn.ch \
--cc=cjubran@nvidia.com \
--cc=daniel.zahka@gmail.com \
--cc=davem@davemloft.net \
--cc=dw@davidwei.uk \
--cc=edumazet@google.com \
--cc=gal@nvidia.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=leitao@debian.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=mohsin.bashr@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=noren@nvidia.com \
--cc=pabeni@redhat.com \
--cc=petrm@nvidia.com \
--cc=sdf@fomichev.me \
--cc=shuah@kernel.org \
--cc=willemb@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox