From: "Radim Krčmář" <rkrcmar@redhat.com>
To: Marcelo Tosatti <mtosatti@redhat.com>
Cc: kvm-devel <kvm@vger.kernel.org>,
stable@vger.kernel.org, Paolo Bonzini <pbonzini@redhat.com>,
Andy Lutomirski <luto@amacapital.net>
Subject: Re: x86: kvm: Revert "remove sched notifier for cross-cpu migrations"
Date: Wed, 25 Mar 2015 14:06:07 +0100 [thread overview]
Message-ID: <20150325130606.GD21710@potion.brq.redhat.com> (raw)
In-Reply-To: <20150323232151.GA12772@amt.cnet>
2015-03-23 20:21-0300, Marcelo Tosatti:
> The following point:
>
> 2. per-CPU pvclock time info is updated if the
> underlying CPU changes.
>
> Is not true anymore since "KVM: x86: update pvclock area conditionally,
> on cpu migration".
>
> Add task migration notification back.
>
> Problem noticed by Andy Lutomirski.
>
> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
> CC: stable@kernel.org # 3.11+
Please improve the commit message.
"KVM: x86: update pvclock area conditionally [...]" was merged half a
year before the patch we are reverting and is completely unrelated to
the bug we are fixing now, (reverted patch just was just wrong)
Reviewed-by: Radim Krčmář <rkrcmar@redhat.com>
> diff --git a/arch/x86/vdso/vclock_gettime.c b/arch/x86/vdso/vclock_gettime.c
> @@ -82,18 +82,15 @@ static notrace cycle_t vread_pvclock(int *mode)
> /*
> - * Note: hypervisor must guarantee that:
> - * 1. cpu ID number maps 1:1 to per-CPU pvclock time info.
> - * 2. that per-CPU pvclock time info is updated if the
> - * underlying CPU changes.
> - * 3. that version is increased whenever underlying CPU
> - * changes.
> - *
> + * When looping to get a consistent (time-info, tsc) pair, we
> + * also need to deal with the possibility we can switch vcpus,
> + * so make sure we always re-fetch time-info for the current vcpu.
(All points from the original comment need to hold -- it would be nicer
to keep both.)
next prev parent reply other threads:[~2015-03-25 13:06 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-23 23:21 x86: kvm: Revert "remove sched notifier for cross-cpu migrations" Marcelo Tosatti
2015-03-23 23:30 ` Andy Lutomirski
2015-03-24 15:34 ` Radim Krčmář
2015-03-24 22:33 ` Andy Lutomirski
2015-03-25 11:08 ` Radim Krčmář
2015-03-25 12:52 ` Radim Krčmář
2015-03-25 21:28 ` Marcelo Tosatti
2015-03-25 22:33 ` Andy Lutomirski
2015-03-25 22:41 ` Marcelo Tosatti
2015-03-25 22:48 ` Andy Lutomirski
2015-03-25 23:13 ` Marcelo Tosatti
2015-03-25 23:22 ` Andy Lutomirski
2015-03-26 11:29 ` Marcelo Tosatti
2015-03-26 18:51 ` Andy Lutomirski
2015-03-26 20:31 ` Radim Krcmar
2015-03-26 20:58 ` Andy Lutomirski
2015-03-26 22:22 ` Andy Lutomirski
2015-03-26 22:56 ` Marcelo Tosatti
2015-03-26 23:09 ` Andy Lutomirski
2015-03-26 23:22 ` Marcelo Tosatti
2015-03-26 23:28 ` Andy Lutomirski
2015-03-26 23:38 ` Marcelo Tosatti
2015-03-26 18:47 ` Andy Lutomirski
2015-03-26 20:10 ` Radim Krčmář
2015-03-26 20:52 ` Paolo Bonzini
2015-03-24 22:59 ` Marcelo Tosatti
2015-03-25 11:09 ` Radim Krčmář
2015-03-25 13:06 ` Radim Krčmář [this message]
2015-03-26 20:59 ` Radim Krčmář
2015-03-26 22:22 ` Marcelo Tosatti
2015-03-26 22:24 ` Andy Lutomirski
2015-03-26 22:40 ` Marcelo Tosatti
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=20150325130606.GD21710@potion.brq.redhat.com \
--to=rkrcmar@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=luto@amacapital.net \
--cc=mtosatti@redhat.com \
--cc=pbonzini@redhat.com \
--cc=stable@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.