Re: [PATCH v2 4/4] selftests/livepatch: Update tests for replace_set

From
sashiko-bot@kernel.org
Date
2026-05-29 05:17:00
Reply to
Yafang Shao, 2026-05-29
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] The 'atomic replace livepatch' test case in test-livepatch.sh was completely removed instead of being updated, resulting in lost test coverage and leaving behind dead variables.
--

commit 99bb60c2ba8319ec21289c482f1ea304e282396c
Author: Yafang Shao [off-list ref]

selftests/livepatch: Update tests for replace_set

This commit updates the livepatch selftests to use "replace_set" instead
of "replace". It configures different livepatches to share or have different
replace_sets to test atomic and non-atomic replace behaviors.
quoted hunk ↗ jump to hunk
diff --git a/tools/testing/selftests/livepatch/test-livepatch.sh b/tools/testing/selftests/livepatch/test-livepatch.sh
index c44c5341a2f1e..042999856267f 100755
--- a/tools/testing/selftests/livepatch/test-livepatch.sh
+++ b/tools/testing/selftests/livepatch/test-livepatch.sh
[ ... ]
quoted hunk ↗ jump to hunk
@@ -108,96 +108,6 @@ livepatch: '$MOD_LIVEPATCH1': completing unpatching transition
 livepatch: '$MOD_LIVEPATCH1': unpatching complete
 % rmmod $MOD_LIVEPATCH1"
 
-
-# - load a livepatch that modifies the output from /proc/cmdline and
-#   verify correct behavior
-# - load two additional livepatches and check the number of livepatch modules
-#   applied
-# - load an atomic replace livepatch and check that the other three modules were
-#   disabled
-# - remove all livepatches besides the atomic replace one and verify that the
-#   atomic replace livepatch is still active
-# - remove the atomic replace livepatch and verify that none are active
-
-start_test "atomic replace livepatch"
-
-load_lp $MOD_LIVEPATCH1
[Severity: Medium]
Was this test case intentionally removed completely instead of being updated for
the new replace_set semantics?

The commit message does not mention removing this test. This removal causes a
loss of test coverage that previously verified an atomic replace successfully
disables multiple existing livepatches.

Additionally, removing this test leaves the script variables MOD_LIVEPATCH2
and MOD_LIVEPATCH3 unused in test-livepatch.sh. Could this test be adapted
to use replace_set instead?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260529034542.68766-1-laoar.shao@gmail.com?part=4
Thread (13 messages) 13 messages, 2 authors, last reply 2026-05-29
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help