[SRU][Q][PATCH 0/1] selftests: net: use BASH for bareudp testing
Po-Hsu Lin
po-hsu.lin at canonical.com
Wed Dec 24 09:00:05 UTC 2025
BugLink: https://bugs.launchpad.net/bugs/2129812
[ Impact ]
In bareudp.sh, this script uses /bin/sh and it will load another lib.sh
BASH script at the very beginning.
But on some operating systems like Ubuntu, /bin/sh is actually pointed to
DASH, thus it will try to run BASH commands with DASH and consequently
leads to syntax issues:
# ./bareudp.sh: 4: ./lib.sh: Bad substitution
# ./bareudp.sh: 5: ./lib.sh: source: not found
# ./bareudp.sh: 24: ./lib.sh: Syntax error: "(" unexpected
Fix this by explicitly using BASH for bareudp.sh. This fixes test
execution failures on systems where /bin/sh is not BASH.
[ Test Plan ]
Run the bareudp.sh with this patch applied, the syntax issues above will
be fixed and the test can proceed.
[ Where problems could occur ]
The change has been applied upstream and 6.17.10, it can be cherry-picked
the scope is limited to the test script itself, with no functional changes
to the kernel.
We may discover new failures through this test. Even if this change is
incorrect, it should not make anything worse, as the test has already
been blocked by this syntax issue.
Po-Hsu Lin (1):
selftests: net: use BASH for bareudp testing
tools/testing/selftests/net/bareudp.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
2.34.1
More information about the kernel-team
mailing list