linux/lib/livepatch
Yannick Cote 6a26a9df16 selftests/livepatch: rework test-klp-shadow-vars
The initial idea was to make a change to please cppcheck and remove void
pointer arithmetics found a few times:

	portability: 'obj' is of type 'void *'. When using void pointers
		     in calculations, the behaviour is undefined.
		     [arithOperationsOnVoidPointer]

The rest of the changes are to help make the test read as an example
while continuing to verify the shadow variable code. The logic of the
test is unchanged but restructured to use descriptive names.

Signed-off-by: Yannick Cote <ycote@redhat.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Reviewed-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Acked-by: Miroslav Benes <mbenes@suse.cz>
Acked-by: Joe Lawrence <joe.lawrence@redhat.com>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20200603182058.109470-3-ycote@redhat.com
2020-06-08 10:40:30 +02:00
..
Makefile livepatch: Selftests of the API for tracking system state changes 2019-11-01 13:08:29 +01:00
test_klp_atomic_replace.c
test_klp_callbacks_busy.c selftests/livepatch: simplify test-klp-callbacks busy target tests 2020-06-08 10:36:10 +02:00
test_klp_callbacks_demo2.c
test_klp_callbacks_demo.c
test_klp_callbacks_mod.c
test_klp_livepatch.c
test_klp_shadow_vars.c selftests/livepatch: rework test-klp-shadow-vars 2020-06-08 10:40:30 +02:00
test_klp_state2.c livepatch: Selftests of the API for tracking system state changes 2019-11-01 13:08:29 +01:00
test_klp_state3.c livepatch: Selftests of the API for tracking system state changes 2019-11-01 13:08:29 +01:00
test_klp_state.c livepatch: Selftests of the API for tracking system state changes 2019-11-01 13:08:29 +01:00