Skip to content

Commit d3c0ca4

Browse files
svanheuleYuryNorov
authored andcommitted
lib/test_cpumask: follow KUnit style guidelines
The cpumask test suite doesn't follow the KUnit style guidelines, as laid out in Documentation/dev-tools/kunit/style.rst. The file is renamed to lib/cpumask_kunit.c to clearly distinguish it from other, non-KUnit, tests. Link: https://lore.kernel.org/lkml/[email protected]/ Suggested-by: Maíra Canal <[email protected]> Signed-off-by: Sander Vanheule <[email protected]> Reviewed-by: Maíra Canal <[email protected]> Reviewed-by: David Gow <[email protected]> Acked-by: Yury Norov <[email protected]> Signed-off-by: Yury Norov <[email protected]>
1 parent fbbc94d commit d3c0ca4

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

lib/Kconfig.debug

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2029,13 +2029,16 @@ config LKDTM
20292029
Documentation on how to use the module can be found in
20302030
Documentation/fault-injection/provoke-crashes.rst
20312031

2032-
config TEST_CPUMASK
2033-
tristate "cpumask tests" if !KUNIT_ALL_TESTS
2032+
config CPUMASK_KUNIT_TEST
2033+
tristate "KUnit test for cpumask" if !KUNIT_ALL_TESTS
20342034
depends on KUNIT
20352035
default KUNIT_ALL_TESTS
20362036
help
20372037
Enable to turn on cpumask tests, running at boot or module load time.
20382038

2039+
For more information on KUnit and unit tests in general, please refer
2040+
to the KUnit documentation in Documentation/dev-tools/kunit/.
2041+
20392042
If unsure, say N.
20402043

20412044
config TEST_LIST_SORT

lib/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ obj-$(CONFIG_TEST_BPF) += test_bpf.o
6060
obj-$(CONFIG_TEST_FIRMWARE) += test_firmware.o
6161
obj-$(CONFIG_TEST_BITOPS) += test_bitops.o
6262
CFLAGS_test_bitops.o += -Werror
63+
obj-$(CONFIG_CPUMASK_KUNIT_TEST) += cpumask_kunit.o
6364
obj-$(CONFIG_TEST_SYSCTL) += test_sysctl.o
6465
obj-$(CONFIG_TEST_SIPHASH) += test_siphash.o
6566
obj-$(CONFIG_HASH_KUNIT_TEST) += test_hash.o
@@ -100,7 +101,6 @@ obj-$(CONFIG_TEST_HMM) += test_hmm.o
100101
obj-$(CONFIG_TEST_FREE_PAGES) += test_free_pages.o
101102
obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
102103
obj-$(CONFIG_TEST_REF_TRACKER) += test_ref_tracker.o
103-
obj-$(CONFIG_TEST_CPUMASK) += test_cpumask.o
104104
CFLAGS_test_fprobe.o += $(CC_FLAGS_FTRACE)
105105
obj-$(CONFIG_FPROBE_SANITY_TEST) += test_fprobe.o
106106
#
File renamed without changes.

0 commit comments

Comments
 (0)