]> git.ipfire.org Git - thirdparty/linux.git/commit
selftests: net: add netconsole test for cmdline configuration
authorBreno Leitao <leitao@debian.org>
Fri, 13 Jun 2025 11:31:37 +0000 (04:31 -0700)
committerJakub Kicinski <kuba@kernel.org>
Mon, 16 Jun 2025 22:18:34 +0000 (15:18 -0700)
commit69d094ef69b9548c89b8e32d24e3d9fc19731a26
tree7047b25a1021eef3280be6c3c60601cc6f38c4aa
parentbed365ca56cadeabb4f0484dc9e12b3c78ac0ab7
selftests: net: add netconsole test for cmdline configuration

Add a new selftest to verify netconsole module loading with command
line arguments. This test exercises the init_netconsole() path and
validates proper parsing of the netconsole= parameter format.

The test:
- Loads netconsole module with cmdline configuration instead of
  dynamic reconfiguration
- Validates message transmission through the configured target
- Adds helper functions for cmdline string generation and module
  validation

This complements existing netconsole selftests by covering the
module initialization code path that processes boot-time parameters.
This test is useful to test issues like the one described in [1].

Link: https://lore.kernel.org/netdev/Z36TlACdNMwFD7wv@dev-ushankar.dev.purestorage.com/
Signed-off-by: Breno Leitao <leitao@debian.org>
Link: https://patch.msgid.link/20250613-rework-v3-8-0752bf2e6912@debian.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/drivers/net/Makefile
tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh
tools/testing/selftests/drivers/net/netcons_cmdline.sh [new file with mode: 0755]