diff options
author | Joe Lawrence <[email protected]> | 2023-12-20 10:11:51 -0500 |
---|---|---|
committer | Shuah Khan <[email protected]> | 2024-01-30 08:55:42 -0700 |
commit | f1fea725cc93fcc3c5af9a2af63ffdc40dd2259e (patch) | |
tree | 4f3d13ea3849f0c616af9b4a86d1ecd77aa24a8e /tools/perf/scripts/python/sched-migration.py | |
parent | d53271c05965b4469c57a18c66585075df81c504 (diff) |
selftests/livepatch: fix and refactor new dmesg message code
The livepatching kselftests rely on comparing expected vs. observed
dmesg output. After each test, new dmesg entries are determined by the
'comm' utility comparing a saved, pre-test copy of dmesg to post-test
dmesg output.
Alexander reports that the 'comm --nocheck-order -13' invocation used by
the tests can be confused when dmesg entry timestamps vary in magnitude
(ie, "[ 98.820331]" vs. "[ 100.031067]"), in which case, additional
messages are reported as new. The unexpected entries then spoil the
test results.
Instead of relying on 'comm' or 'diff' to determine new testing dmesg
entries, refactor the code:
- pre-test : log a unique canary dmesg entry
- test : run tests, log messages
- post-test : filter dmesg starting from pre-test message
Reported-by: Alexander Gordeev <[email protected]>
Closes: https://lore.kernel.org/live-patching/[email protected]/
Signed-off-by: Joe Lawrence <[email protected]>
Acked-by: Alexander Gordeev <[email protected]>
Tested-by: Marcos Paulo de Souza <[email protected]>
Reviewed-by: Marcos Paulo de Souza <[email protected]>
Acked-by: Miroslav Benes <[email protected]>
Signed-off-by: Shuah Khan <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/sched-migration.py')
0 files changed, 0 insertions, 0 deletions