Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Documentation: kunit: add description of kunit.enable parameter

The current KUnit documentation does not mention the kunit.enable
kernel parameter, making it unclear how to troubleshoot cases where
KUnit tests do not run as expected.
Add a note explaining kunit.enable parmaeter. Disabling this parameter
prevents all KUnit tests from running even if CONFIG_KUNIT is enabled.

Link: https://lore.kernel.org/r/20251021030605.41610-1-ishikawa.yuy-00@jp.fujitsu.com
Signed-off-by: Yuya Ishikawa <ishikawa.yuy-00@jp.fujitsu.com>
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>

authored by

Yuya Ishikawa and committed by
Shuah Khan
9de5f847 3a866087

+6
+6
Documentation/dev-tools/kunit/run_manual.rst
··· 35 35 a good way of quickly testing everything applicable to the current 36 36 config. 37 37 38 + KUnit can be enabled or disabled at boot time, and this behavior is 39 + controlled by the kunit.enable kernel parameter. 40 + By default, kunit.enable is set to 1 because KUNIT_DEFAULT_ENABLED is 41 + enabled by default. To ensure that tests are executed as expected, 42 + verify that kunit.enable=1 at boot time. 43 + 38 44 Once we have built our kernel (and/or modules), it is simple to run 39 45 the tests. If the tests are built-in, they will run automatically on the 40 46 kernel boot. The results will be written to the kernel log (``dmesg``)