From: Paolo Bonzini <pbonzini@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 4/4] pl031: switch clock base to rtc_clock
Date: Mon, 30 Jan 2012 18:02:13 +0100 [thread overview]
Message-ID: <4F26CD15.3020206@redhat.com> (raw)
In-Reply-To: <CAFEAcA901PHrV81qPjUkudx1kHm=gvfoeNuCYsswFj0ZQUc1iA@mail.gmail.com>
On 01/30/2012 05:54 PM, Peter Maydell wrote:
>> > This lets the user specify the desired semantics. By default, the RTC
>> > will follow adjustments from the host's NTP client, and will remain in
>> > sync when the virtual machine is stopped. The previous behavior, which
>> > provides determinism with both icount and qtest, remains available with
>> > "-rtc clock=vm".
>> >
>> > pl031 supports migration, so we need to convert the time
>> > base from rtc_clock to vm_clock and back for backwards compatibility.
> If it would be cleaner I'm entirely happy for us to do a version
> bump and break binary compatibility. (We bump the version on
> the CPUState pretty regularly anyhow; save/load for ARM devices
> currently is mostly for the benefit of snapshot save/restore rather
> than between-qemu-versions migration.)
Actually it's not really just backwards compatibility.
rtc_clock may be counting up from a different time base on the source
and destination machine. vm_clock is the only time base that is
migrated, so it is the only one that is safe to use in the data stream.
Perhaps I could transfer the timer deadline relative to the current
rtc_clock value and convert it again on the destination. However, it
would be basically the same code that transfers the value relative to
the vm_clock; it's just a different offset to apply.
Paolo
next prev parent reply other threads:[~2012-01-30 17:02 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-20 12:06 [Qemu-devel] [PATCH 0/4] Use rtc_clock uniformly for ARM Paolo Bonzini
2012-01-20 12:06 ` [Qemu-devel] [PATCH 1/4] rtc: add -rtc clock=rt Paolo Bonzini
2012-01-20 12:06 ` [Qemu-devel] [PATCH 2/4] arm: switch real-time clocks to rtc_clock Paolo Bonzini
2012-02-17 7:09 ` andrzej zaborowski
2012-02-17 8:05 ` Paolo Bonzini
2012-02-17 8:24 ` andrzej zaborowski
2012-02-17 8:31 ` Paolo Bonzini
2012-01-20 12:06 ` [Qemu-devel] [PATCH 3/4] pl031: rearm alarm timer upon load Paolo Bonzini
2012-01-20 12:06 ` [Qemu-devel] [PATCH 4/4] pl031: switch clock base to rtc_clock Paolo Bonzini
2012-01-30 16:54 ` Peter Maydell
2012-01-30 17:02 ` Paolo Bonzini [this message]
2012-01-30 16:42 ` [Qemu-devel] [PATCH 0/4] Use rtc_clock uniformly for ARM Paolo Bonzini
2012-01-30 17:21 ` Peter Maydell
2012-01-31 7:28 ` Paolo Bonzini
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=4F26CD15.3020206@redhat.com \
--to=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).