From: Gerd Hoffmann <kraxel@redhat.com>
To: Glauber Costa <glommer@gmail.com>
Cc: KVM list <kvm@vger.kernel.org>
Subject: Re: [patch] kvmclock fix
Date: Tue, 03 Feb 2009 18:19:56 +0100 [thread overview]
Message-ID: <49887CBC.8010509@redhat.com> (raw)
In-Reply-To: <5d6222a80902030914u77b93f28t81df26ed345717b0@mail.gmail.com>
Glauber Costa wrote:
>> +static unsigned int ref_freq;
>> +static unsigned long loops_per_jiffy_ref;
>> +static unsigned long tsc_khz_ref;
>
> Doesn't these need to be percpu too ?
>
> Otherwise we could be calculating the new frequency based on a foreign
> reference.
I doubt you can have a SMP systems with cpus having different freqs.
Also tsc.c does the same.
> I believe a possible approach is to move those that refer to tsc
> calculation to tsc.c, and make all uses
> of tsc_khz comply to a per_cpu use. A global tsc_khz does not make sense anyway.
>
> Then we'll have a specific kvm notifier that just forces the guest out
> of its execution so we can update
> the clock state.
Then we have an ordering issue with the two notifier calls. I don't
thing there is a way to force a specific call order.
cheers,
Gerd
next prev parent reply other threads:[~2009-02-03 17:20 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-03 17:02 [patch] kvmclock fix Gerd Hoffmann
2009-02-03 17:14 ` Glauber Costa
2009-02-03 17:19 ` Gerd Hoffmann [this message]
2009-02-04 16:17 ` Marcelo Tosatti
2009-02-04 16:43 ` Gerd Hoffmann
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=49887CBC.8010509@redhat.com \
--to=kraxel@redhat.com \
--cc=glommer@gmail.com \
--cc=kvm@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox