Test livepatching

modulename: test_klp_atomic_replace.ko

configname: CONFIG_TEST_LIVEPATCH

Linux Kernel Configuration
└─>Kernel hacking
└─>Kernel Testing and Coverage
└─>Runtime Testing
└─>Test livepatching
In linux kernel since version 5.1 (release Date: 2019-05-05)  
Test kernel livepatching features for correctness. The tests will
load test modules that will be livepatched in various scenarios.

To run all the livepatching tests:

make -C tools/testing/selftests TARGETS=livepatch run_tests

Alternatively, individual tests may be invoked:

tools/testing/selftests/livepatch/test-callbacks.sh
tools/testing/selftests/livepatch/test-livepatch.sh
tools/testing/selftests/livepatch/test-shadow-vars.sh

If unsure, say N.

source code: