[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] pl031 time across vm save/reload
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] pl031 time across vm save/reload |
Date: |
Mon, 8 Jul 2019 15:03:15 +0100 |
On Fri, 5 Jul 2019 at 10:48, Paolo Bonzini <address@hidden> wrote:
> You're right, the compatibility causes wrong behavior for the default
> -rtc settings (the RC pauses across migration). The right thing to do
> would be to store the base rather than the offset: that is, you store
> the time at which LR was written. Then the offset is s->lr - s->base
> and it's independent of the machine on which the rtc_clock is being read.
So I thought I'd try writing a patch for this today, but I'm kind
of confused. If I understand you correctly, you're suggesting
that we should migrate a new field:
base_time = s->lr - s->tick_offset
and then on the destination we can reconstitute tick_offset with
s->tick_offset = base_time - s->lr
right?
But isn't this just a confusing way of migrating s->tick_offset
directly ? We'll never end up with a value at the destination
that's different from the offset value we started with on the source.
thanks
-- PMM
Re: [Qemu-devel] pl031 time across vm save/reload, Peter Maydell, 2019/07/05
Re: [Qemu-devel] pl031 time across vm save/reload,
Peter Maydell <=