* [PATCH 0/3] kselftest framework to introduce TEST_CONFIG_DEPS
@ 2024-12-05 11:47 Siddharth Menon
2024-12-05 11:47 ` [PATCH 3/3] selftests/livepatch: Check if required config options are enabled Siddharth Menon
0 siblings, 1 reply; 2+ messages in thread
From: Siddharth Menon @ 2024-12-05 11:47 UTC (permalink / raw)
To: simeddon, corbet, jikos, jpoimboe, mbenes, pmladek, shuah
Cc: linux-doc, linux-kselftest, live-patching, workflows
Currently, kselftests does not have a generalised mechanism to skip compilation
and run tests when required kernel configuration options are disabled.
This patch series addresses this limitation by introducing a new flag,
'TEST_CONFIG_DEPS' in lib.mk, along with corresponding updates to the
documentation.
The selftests/livepatch/Makefile has been updated to utilize TEST_CONFIG_DEPS.
Siddharth Menon (3):
docs/kselftests: Explain the usage of TEST_CONFIG_DEPS
selftests/lib.mk: Introduce check to validate required configs
selftests/livepatch: Check if required config options are enabled
Documentation/dev-tools/kselftest.rst | 3 +++
tools/testing/selftests/lib.mk | 18 ++++++++++++++++--
tools/testing/selftests/livepatch/Makefile | 1 +
3 files changed, 20 insertions(+), 2 deletions(-)
--
2.39.5
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH 3/3] selftests/livepatch: Check if required config options are enabled
2024-12-05 11:47 [PATCH 0/3] kselftest framework to introduce TEST_CONFIG_DEPS Siddharth Menon
@ 2024-12-05 11:47 ` Siddharth Menon
0 siblings, 0 replies; 2+ messages in thread
From: Siddharth Menon @ 2024-12-05 11:47 UTC (permalink / raw)
To: simeddon, jpoimboe, jikos, mbenes, pmladek, shuah
Cc: live-patching, linux-kselftest
When CONFIG_LIVEPATCH is disabled, compilation fails due to the
required structs from the livepatch header file being undefined.
This checks for whether CONFIG_LIVEPATCH and CONFIG_DYNAMIC_DEBUG
are enabled before compiling livepatch self-tests.
Signed-off-by: Siddharth Menon <simeddon@gmail.com>
---
tools/testing/selftests/livepatch/Makefile | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/livepatch/Makefile b/tools/testing/selftests/livepatch/Makefile
index a080eb54a215..14b5c60663cd 100644
--- a/tools/testing/selftests/livepatch/Makefile
+++ b/tools/testing/selftests/livepatch/Makefile
@@ -14,5 +14,6 @@ TEST_PROGS := \
test-kprobe.sh
TEST_FILES := settings
+TEST_CONFIG_DEPS := CONFIG_LIVEPATCH CONFIG_DYNAMIC_DEBUG
include ../lib.mk
--
2.39.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-12-05 11:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-05 11:47 [PATCH 0/3] kselftest framework to introduce TEST_CONFIG_DEPS Siddharth Menon
2024-12-05 11:47 ` [PATCH 3/3] selftests/livepatch: Check if required config options are enabled Siddharth Menon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).