aboutsummaryrefslogtreecommitdiff
path: root/tools/testing/selftests/livepatch/functions.sh
AgeCommit message (Collapse)AuthorFilesLines
2019-02-12livepatch/selftests: use "$@" to preserve argument listJoe Lawrence1-12/+7
The livepatch selftest functions.sh library uses "$*" and an intermediate variable to extract and then pass arguments from function to function call. The effect of this combination is that the argument list is flattened into a single argument. Sometimes this is benign, but in cases like __load_mod(), the modprobe invocation will interpret all the module parameters as a single parameter. Drop the intermediate variable and use the "$@" special parameter as described in the bash manual. Link: https://www.gnu.org/software/bash/manual/bash.html#Special-Parameters Signed-off-by: Joe Lawrence <[email protected]> Reviewed-by: Kamalesh Babulal <[email protected]> Acked-by: Miroslav Benes <[email protected]> Signed-off-by: Petr Mladek <[email protected]>
2019-01-11selftests/livepatch: introduce testsJoe Lawrence1-0/+203
Add a few livepatch modules and simple target modules that the included regression suite can run tests against: - basic livepatching (multiple patches, atomic replace) - pre/post (un)patch callbacks - shadow variable API Signed-off-by: Joe Lawrence <[email protected]> Signed-off-by: Petr Mladek <[email protected]> Tested-by: Miroslav Benes <[email protected]> Tested-by: Alice Ferrazzi <[email protected]> Acked-by: Joe Lawrence <[email protected]> Acked-by: Josh Poimboeuf <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>