2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00
linux/Documentation/dev-tools
Rae Moar d208025db6 Documentation: kunit: improve example on testing static functions
The documentation on testing static functions using the KUnit macros
VISIBLE_IF_KUNIT and EXPORT_SYMBOL_IF_KUNIT is lacking clarity and
missing key steps in the example. This has caused bugs and confusion
among developers.

Improve wording of description and add missing steps to the example.
This entails adding the "#include <kunit/visibility.h>" line and the
"MODULE_IMPORT_NS(EXPORTED_FOR_KUNIT_TESTING);" line. Both of which were
missing from the original example and key to exposing static functions.

Link: https://lore.kernel.org/r/20250516190631.1214081-1-rmoar@google.com
Signed-off-by: Rae Moar <rmoar@google.com>
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
2025-05-19 13:22:21 -06:00
..
kunit Documentation: kunit: improve example on testing static functions 2025-05-19 13:22:21 -06:00
autofdo.rst
checkpatch.rst kbuild: remove EXTRA_*FLAGS support 2025-03-15 21:16:21 +09:00
checkuapi.rst
clang-format.rst
coccinelle.rst kbuild: change working directory to external module directory with M= 2024-11-28 08:10:23 +09:00
gcov.rst
gpio-sloppy-logic-analyzer.rst
index.rst Documentation: move dev-tools debugging files to process/debugging/ 2024-12-17 13:46:53 -07:00
kasan.rst
kcov.rst
kcsan.rst Documentation: kcsan: fix "Plain Accesses and Data Races" URL in kcsan.rst 2025-03-12 16:34:55 -06:00
kfence.rst
kmemleak.rst kmemleak: iommu/iova: fix transient kmemleak false positive 2024-11-11 17:22:26 -08:00
kmsan.rst
kselftest.rst printf: convert self-test to KUnit 2025-03-13 10:26:33 -07:00
ktap.rst
propeller.rst kbuild: Add Propeller configuration for kernel build 2024-11-27 09:38:27 +09:00
sparse.rst
testing-devices.rst
testing-overview.rst
ubsan.rst