]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: livepatch: Fix it to do root uid check and skip
authorShuah Khan <skhan@linuxfoundation.org>
Mon, 16 Dec 2019 19:18:40 +0000 (12:18 -0700)
committerShuah Khan <skhan@linuxfoundation.org>
Mon, 23 Dec 2019 17:52:40 +0000 (10:52 -0700)
commit969c1729544f80b3abd90d04ef202ddcbe4d14a0
treec63d40118701bf2d7b124b12697e9395c6104ee9
parent3344fd1dbde5059ae818c4011bad7d63fc1d1397
selftests: livepatch: Fix it to do root uid check and skip

livepatch test configures the system and debug environment to run
tests. Some of these actions fail without root access and test
dumps several permission denied messages before it exits.

Fix test-state.sh to call setup_config instead of set_dynamic_debug
as suggested by Petr Mladek <pmladek@suse.com>

Fix it to check root uid and exit with skip code instead.

Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Acked-by: Joe Lawrence <joe.lawrence@redhat.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/livepatch/functions.sh
tools/testing/selftests/livepatch/test-state.sh