From: Thomas Huth <thuth@redhat.com>
To: Christian Borntraeger <borntraeger@de.ibm.com>,
Cornelia Huck <cohuck@redhat.com>
Cc: qemu-devel <qemu-devel@nongnu.org>,
Alexander Graf <agraf@suse.de>,
"Collin L. Walling" <walling@linux.vnet.ibm.com>,
Richard Henderson <rth@twiddle.net>
Subject: Re: [Qemu-devel] [PATCH v2 2/2] s390/kvm: make TOD setting failures fatal for migration
Date: Wed, 4 Oct 2017 13:48:54 +0200 [thread overview]
Message-ID: <284e46bd-52ac-34d9-81ab-c3b8c364a2ea@redhat.com> (raw)
In-Reply-To: <20171004105751.24655-3-borntraeger@de.ibm.com>
On 04.10.2017 12:57, Christian Borntraeger wrote:
> From: "Collin L. Walling" <walling@linux.vnet.ibm.com>
>
> If we fail to set a proper TOD clock on the target system, this can
> already result in some problematic cases. We print several warn messages
> on source and target in that case.
>
> If kvm fails to set a nonzero epoch index, then we must ultimately fail
> the migration as this will result in a giant time leap backwards. This
> patch lets the migration fail if we can not set the guest time on the
> target.
>
> On failure the guest will resume normally on the original host machine.
>
> Signed-off-by: Collin L. Walling <walling@linux.vnet.ibm.com>
> Reviewed-by: Eric Farman <farman@linux.vnet.ibm.com>
> Reviewed-by: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
> [split failure change from epoch index change, minor fixups]
> ---
> hw/s390x/s390-virtio-ccw.c | 7 ++-----
> 1 file changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
> index fafbc6d..b7adb93 100644
> --- a/hw/s390x/s390-virtio-ccw.c
> +++ b/hw/s390x/s390-virtio-ccw.c
> @@ -213,13 +213,10 @@ static int gtod_load(QEMUFile *f, void *opaque, int version_id)
>
> r = s390_set_clock(&tod_high, &tod_low);
> if (r) {
> - warn_report("Unable to set guest clock for migration: %s",
> - strerror(-r));
> - error_printf("Guest clock will not be restored "
> - "which could cause the guest to hang.");
> + error_report("Unable to set KVM guest TOD clock: %s", strerror(-r));
> }
>
> - return 0;
> + return r;
> }
Reviewed-by: Thomas Huth <thuth@redhat.com>
(and I wonder whether we should fail the S390_TOD_CLOCK_VALUE_MISSING
case with returning an error instead of 0, too?)
next prev parent reply other threads:[~2017-10-04 11:49 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-04 10:57 [Qemu-devel] [PATCH v2 0/2] s390/z14: extended TOD-clock support Christian Borntraeger
2017-10-04 10:57 ` [Qemu-devel] [PATCH v2 1/2] s390/kvm: Support for get/set of extended TOD-Clock for guest Christian Borntraeger
2017-10-04 11:42 ` Thomas Huth
2017-10-04 11:44 ` Christian Borntraeger
2017-10-04 13:29 ` Cornelia Huck
2017-10-04 10:57 ` [Qemu-devel] [PATCH v2 2/2] s390/kvm: make TOD setting failures fatal for migration Christian Borntraeger
2017-10-04 11:48 ` Thomas Huth [this message]
2017-10-04 11:51 ` Christian Borntraeger
2017-10-04 13:57 ` [Qemu-devel] [PATCH v2 0/2] s390/z14: extended TOD-clock support Cornelia Huck
2017-10-04 14:17 ` Christian Borntraeger
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=284e46bd-52ac-34d9-81ab-c3b8c364a2ea@redhat.com \
--to=thuth@redhat.com \
--cc=agraf@suse.de \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
--cc=walling@linux.vnet.ibm.com \
/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;
as well as URLs for NNTP newsgroup(s).