From: Pratyush Yadav <pratyush@kernel.org>
To: David Matlack <dmatlack@google.com>
Cc: kexec@lists.infradead.org, linux-kernel@vger.kernel.org,
linux-kselftest@vger.kernel.org,
Jordan Richards <jordanrichards@google.com>,
Mike Rapoport <rppt@kernel.org>,
Pasha Tatashin <pasha.tatashin@soleen.com>,
Pratyush Yadav <pratyush@kernel.org>,
Shuah Khan <shuah@kernel.org>
Subject: Re: [PATCH] selftests/liveupdate: Prefer KVM and HVF over TCG in vmtest.sh
Date: Mon, 12 Oct 2026 12:29:42 +0200 [thread overview]
Message-ID: <2vxzv777jjop.fsf@kernel.org> (raw)
In-Reply-To: <20261008132813.1966023-1-dmatlack@google.com> (David Matlack's message of "Thu, 8 Oct 2026 13:28:13 +0000")
On Thu, Oct 08 2026, David Matlack wrote:
> Pass the -accel options to QEMU in the order KVM, HVF, TCG, so that
> vmtest.sh prefers to use KVM and HVF over TCG when they are available.
>
> QEMU uses the first accelerator in the list that initializes, and TCG
> always initializes, so the tests currently always run under TCG, even
> though the commit that added vmtest.sh describes "automatic accelerator
> detection (KVM, HVF, or TCG)".
>
> Fixes: 89dd1421c554 ("selftests/liveupdate: add end to end test infrastructure and scripts")
> Signed-off-by: David Matlack <dmatlack@google.com>
IIUC HVF is only for MacOS. I don't think we care to run this script on
MacOS.
Anyway, thanks for the fix
Reviewed-by: Pratyush Yadav <pratyush@kernel.org>
> ---
> Tested by running run-vmtests.sh and then observed that arm64 correctly
> fell back to using TCG after trying to use KVM and HVF, and that x86
> reported no warnings.
>
> arm64:
> qemu-system-aarch64: -accel kvm: invalid accelerator kvm
> qemu-system-aarch64: -accel hvf: invalid accelerator hvf
> qemu-system-aarch64: falling back to tcg
>
> x86:
> (not warnings)
>
> tools/testing/selftests/liveupdate/vmtest.sh | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/testing/selftests/liveupdate/vmtest.sh b/tools/testing/selftests/liveupdate/vmtest.sh
> index 64fd2ab55b76..69beda6c961d 100755
> --- a/tools/testing/selftests/liveupdate/vmtest.sh
> +++ b/tools/testing/selftests/liveupdate/vmtest.sh
> @@ -180,7 +180,7 @@ function run_qemu() {
> echo "# Serial Log: $serial"
> timeout 30s \
> $qemu_cmd -m 1G -smp 2 -no-reboot -nographic -nodefaults \
> - -accel tcg -accel hvf -accel kvm \
> + -accel kvm -accel hvf -accel tcg \
> -serial file:"$serial" \
> -append "$cmdline" \
> -kernel "$kernel_path" \
>
> base-commit: 80cf37169daef112b6bea9ae7d9808355a045475
--
Regards,
Pratyush Yadav
next prev parent reply other threads:[~2026-10-12 10:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-08 13:28 [PATCH] selftests/liveupdate: Prefer KVM and HVF over TCG in vmtest.sh David Matlack
2026-10-08 13:33 ` sashiko-bot
2026-10-12 10:29 ` Pratyush Yadav [this message]
2026-10-13 9:57 ` Mike Rapoport
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2vxzv777jjop.fsf@kernel.org \
--to=pratyush@kernel.org \
--cc=dmatlack@google.com \
--cc=jordanrichards@google.com \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=pasha.tatashin@soleen.com \
--cc=rppt@kernel.org \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox