]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
lib: enable building KUnit in lib/
authorBrendan Higgins <brendanhiggins@google.com>
Mon, 23 Sep 2019 09:02:36 +0000 (02:02 -0700)
committerShuah Khan <skhan@linuxfoundation.org>
Mon, 30 Sep 2019 23:35:00 +0000 (17:35 -0600)
KUnit is a new unit testing framework for the kernel and when used is
built into the kernel as a part of it. Add KUnit to the lib Kconfig and
Makefile to allow it to be actually built.

Signed-off-by: Brendan Higgins <brendanhiggins@google.com>
Cc: Randy Dunlap <rdunlap@infradead.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Kees Cook <keescook@chromium.org>
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
lib/Kconfig.debug
lib/Makefile

index 93d97f9b015714493715297fd49a5be1b457df69..683863264655198aab66d8ef347a4d618a947963 100644 (file)
@@ -1664,6 +1664,8 @@ config PROVIDE_OHCI1394_DMA_INIT
 
          See Documentation/debugging-via-ohci1394.txt for more information.
 
+source "lib/kunit/Kconfig"
+
 menuconfig RUNTIME_TESTING_MENU
        bool "Runtime Testing"
        def_bool y
index c5892807e06fa2c940103947d9272c66bcb4982d..bba1fd5485f77465b42803717ca2638e000b949d 100644 (file)
@@ -92,6 +92,8 @@ obj-$(CONFIG_TEST_MEMINIT) += test_meminit.o
 
 obj-$(CONFIG_TEST_LIVEPATCH) += livepatch/
 
+obj-$(CONFIG_KUNIT) += kunit/
+
 ifeq ($(CONFIG_DEBUG_KOBJECT),y)
 CFLAGS_kobject.o += -DDEBUG
 CFLAGS_kobject_uevent.o += -DDEBUG