]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
selftests/vsock: fix vsock_test path shadowing in nested VMs
authorBobby Eshleman <bobbyeshleman@meta.com>
Tue, 17 Mar 2026 22:09:36 +0000 (15:09 -0700)
committerJakub Kicinski <kuba@kernel.org>
Sat, 21 Mar 2026 01:34:48 +0000 (18:34 -0700)
commit0c3893d37892f332b595906710bf53bbd9c7c572
treed69fdf301133d8cb7d1433552777f463f47d6a7f
parent865926e26e05be52ff311883619b9198298698df
selftests/vsock: fix vsock_test path shadowing in nested VMs

The /root mount introduced for nested VM support shadows any host paths
under /root. This breaks systems where the outer VM runs as root and the
vsock_test binary path is something like:

/root/linux/tools/testing/selftests/vsock/vsock_test

Fix this by copying vsock_test into the temporary home directory that
gets mounted as /root in the guest, and using a relative path to invoke
it.

Signed-off-by: Bobby Eshleman <bobbyeshleman@meta.com>
Link: https://patch.msgid.link/20260317-vsock-vmtest-nested-fixes-v2-2-0b3f53b80a0f@meta.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/vsock/vmtest.sh