]> git.ipfire.org Git - thirdparty/qemu.git/commit
s390x/pv: Fix spurious warning with asynchronous teardown
authorClaudio Imbrenda <imbrenda@linux.ibm.com>
Wed, 10 May 2023 10:55:31 +0000 (12:55 +0200)
committerMichael Tokarev <mjt@tls.msk.ru>
Wed, 17 May 2023 09:27:58 +0000 (12:27 +0300)
commit21b54a683d14c0c6f9af35536d9059c60b7449ca
tree60bb3c0ee3a1ca7f63e5147ab3e30a2063157b69
parent36cd9bc8e2817dd5ae9cc7c427ec3a822eb1169d
s390x/pv: Fix spurious warning with asynchronous teardown

Kernel commit 292a7d6fca33 ("KVM: s390: pv: fix asynchronous teardown
for small VMs") causes the KVM_PV_ASYNC_CLEANUP_PREPARE ioctl to fail
if the VM is not larger than 2GiB. QEMU would attempt it and fail,
print an error message, and then proceed with a normal teardown.

Avoid attempting to use asynchronous teardown altogether when the VM is
not larger than 2 GiB. This will avoid triggering the error message and
also avoid pointless overhead; normal teardown is fast enough for small
VMs.

Reported-by: Marc Hartmayer <mhartmay@linux.ibm.com>
Fixes: c3a073c610 ("s390x/pv: Add support for asynchronous teardown for reboot")
Link: https://lore.kernel.org/all/20230421085036.52511-2-imbrenda@linux.ibm.com/
Signed-off-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
Message-Id: <20230510105531.30623-2-imbrenda@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
[thuth: Fix inline function parameter in pv.h]
Signed-off-by: Thomas Huth <thuth@redhat.com>
(cherry picked from commit 88693ab2a53f2f3d25cb39a7b5034ab391bc5a81)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/s390x/pv.c
hw/s390x/s390-virtio-ccw.c
include/hw/s390x/pv.h