tools/testing/selftests/net/mptcp/mptcp_lib.sh | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-)
In case of errors, mptcp_lib_pr_nstat is called to dump the nstat
counters, but for some tests, it was dumping the counters for all
subtests, not just the current one.
That's an issue for tests that don't recreate the netns for each
subtest, e.g. mptcp_connect.sh. In this case, 'nstat -a' will look at
the absolute counters since the creation of the netns, making
debugging harder.
Instead, it should dump the counters for the current test, by using the
history recorded in /tmp/<ns>.nstat, if available, and not using '-a'
which was dumping the absolute values instead of calculating increments.
While at it, rename the previous 'hist' variable to 'cache' as it was
used to look at the cache, not the nstat history.
Do the same in mptcp_lib_get_counter, even if it wasn't an issue for
the moment. Still, good to fix it for future usage, and to align it
with the rest.
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
---
Matthieu Baerts (NGI0) (2):
selftests: mptcp: lib: dump nstat for the right test
selftests: mptcp: lib: get counters for the right test
tools/testing/selftests/net/mptcp/mptcp_lib.sh | 26 +++++++++++++++-----------
1 file changed, 15 insertions(+), 11 deletions(-)
---
base-commit: ab76ed72e0bed8352d3b8e2b4d1be7c823e5fba3
change-id: 20260813-sft-mptcp-nstat-hist-33411708430f
Best regards,
--
Matthieu Baerts (NGI0) <matttbe@kernel.org>
Hi Matthieu,
Thank you for your modifications, that's great!
Our CI did some validations and here is its report:
- KVM Validation: normal (except selftest_mptcp_join): Success! ✅
- KVM Validation: normal (only selftest_mptcp_join): Success! ✅
- KVM Validation: debug (except selftest_mptcp_join): Success! ✅
- KVM Validation: debug (only selftest_mptcp_join): Success! ✅
- KVM Validation: btf-normal (only bpftest_all): Success! ✅
- KVM Validation: btf-debug (only bpftest_all): Success! ✅
- Task: https://github.com/multipath-tcp/mptcp_net-next/actions/runs/31693194883
Initiator: Patchew Applier
Commits: https://github.com/multipath-tcp/mptcp_net-next/commits/1737d20f1a46
Patchwork: https://patchwork.kernel.org/project/mptcp/list/?series=1145356
If there are some issues, you can reproduce them using the same environment as
the one used by the CI thanks to a docker image, e.g.:
$ cd [kernel source code]
$ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm -it \
--pull always mptcp/mptcp-upstream-virtme-docker:latest \
auto-normal
For more details:
https://github.com/multipath-tcp/mptcp-upstream-virtme-docker
Please note that despite all the efforts that have been already done to have a
stable tests suite when executed on a public CI like here, it is possible some
reported issues are not due to your modifications. Still, do not hesitate to
help us improve that ;-)
Cheers,
MPTCP GH Action bot
Bot operated by Matthieu Baerts (NGI0 Core)
Hi Matt,
On Thu, 2026-08-13 at 11:41 +0000, MPTCP CI wrote:
> Hi Matthieu,
>
> Thank you for your modifications, that's great!
>
> Our CI did some validations and here is its report:
>
> - KVM Validation: normal (except selftest_mptcp_join): Success! ✅
> - KVM Validation: normal (only selftest_mptcp_join): Success! ✅
> - KVM Validation: debug (except selftest_mptcp_join): Success! ✅
> - KVM Validation: debug (only selftest_mptcp_join): Success! ✅
> - KVM Validation: btf-normal (only bpftest_all): Success! ✅
> - KVM Validation: btf-debug (only bpftest_all): Success! ✅
This series looks good to me!
Reviewed-by: Geliang Tang <geliang@kernel.org>
Thanks,
-Geliang
> - Task:
> https://github.com/multipath-tcp/mptcp_net-next/actions/runs/31693194883
>
> Initiator: Patchew Applier
> Commits:
> https://github.com/multipath-tcp/mptcp_net-next/commits/1737d20f1a46
> Patchwork:
> https://patchwork.kernel.org/project/mptcp/list/?series=1145356
>
>
> If there are some issues, you can reproduce them using the same
> environment as
> the one used by the CI thanks to a docker image, e.g.:
>
> $ cd [kernel source code]
> $ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm
> -it \
> --pull always mptcp/mptcp-upstream-virtme-docker:latest \
> auto-normal
>
> For more details:
>
> https://github.com/multipath-tcp/mptcp-upstream-virtme-docker
>
>
> Please note that despite all the efforts that have been already done
> to have a
> stable tests suite when executed on a public CI like here, it is
> possible some
> reported issues are not due to your modifications. Still, do not
> hesitate to
> help us improve that ;-)
>
> Cheers,
> MPTCP GH Action bot
> Bot operated by Matthieu Baerts (NGI0 Core)
Hi Geliang, On 19/08/2026 11:22, Geliang Tang wrote: > Hi Matt, > > On Thu, 2026-08-13 at 11:41 +0000, MPTCP CI wrote: >> Hi Matthieu, >> >> Thank you for your modifications, that's great! >> >> Our CI did some validations and here is its report: >> >> - KVM Validation: normal (except selftest_mptcp_join): Success! ✅ >> - KVM Validation: normal (only selftest_mptcp_join): Success! ✅ >> - KVM Validation: debug (except selftest_mptcp_join): Success! ✅ >> - KVM Validation: debug (only selftest_mptcp_join): Success! ✅ >> - KVM Validation: btf-normal (only bpftest_all): Success! ✅ >> - KVM Validation: btf-debug (only bpftest_all): Success! ✅ > > This series looks good to me! Thank you for the review! New patches for t/upstream-net and t/upstream: - 2f2caaafc5d7: selftests: mptcp: lib: dump nstat for the right test - 012008e8fee2: selftests: mptcp: lib: get counters for the right test - Results: d251bdc7d65e..5d79f315b7d9 (export-net) - Results: 77661003be12..62720ef2600c (export) Tests are now in progress: - export-net: https://github.com/multipath-tcp/mptcp_net-next/commit/68d3c4c19015394240f5eecbe2329ae4cdd933ad/checks - export: https://github.com/multipath-tcp/mptcp_net-next/commit/7900a5c017041f34876f1fd033b88cf994aed099/checks Cheers, Matt -- Sponsored by the NGI0 Core fund.
© 2016 - 2026 Red Hat, Inc.