From: Don Slutz <Don@CloudSwitch.Com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: Kevin O'Connor <kevin@koconnor.net>, <seabios@seabios.org>,
<kvm@vger.kernel.org>
Subject: Re: [SeaBIOS] [PATCH v2] add acpi pmtimer support
Date: Wed, 5 Sep 2012 11:39:49 -0400 [thread overview]
Message-ID: <50477245.4030003@CloudSwitch.Com> (raw)
In-Reply-To: <5046E2DC.4080104@redhat.com>
On 09/05/12 01:27, Gerd Hoffmann wrote:
> On 09/02/12 22:42, Kevin O'Connor wrote:
>> On Tue, Aug 14, 2012 at 07:29:19AM +0200, Gerd Hoffmann wrote:
>>> This patch makes seabios use the acpi pmtimer instead of tsc for
>>> timekeeping. The pmtimer has a fixed frequency and doesn't need
>>> calibration, thus it doesn't suffer from calibration errors due to a
>>> loaded host machine.
>> The patch looks okay to me, but is it still needed? (I recall seeing
>> something on the kvm list about a bug fix to the main timer.)
> It is still a good idea to make timing in a virtual machine more robust.
>
>>> + u32 pmtimer = inl(ioport);
>>> + return (u64)wraps << 24 | pmtimer;
>> BTW, why is this "<< 24", and if it should be that way, shouldn't the
>> pmtimer be "inl(ioport) & 0xffffff" ?
> The pmtimer is defined to be 24 bits wide, so the shift is correct.
This is not true in general. It can be either 24 or 32 bits. What it
is depends on ACPI data (acpi_gbl_FADT->tmr_val_ext). However it is
valid to only used 24 bits.
*/
/*
> But, yes, the ioport read should better be masked to be on the safe
> side. v3 will go out in a minute.
>
> cheers,
> Gerd
>
> _______________________________________________
> SeaBIOS mailing list
> SeaBIOS@seabios.org
> http://www.seabios.org/mailman/listinfo/seabios
-Don Slutz
next prev parent reply other threads:[~2012-09-05 15:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-14 5:29 [PATCH v2] add acpi pmtimer support Gerd Hoffmann
2012-09-02 20:42 ` Kevin O'Connor
2012-09-04 16:28 ` Avi Kivity
2012-09-05 5:27 ` Gerd Hoffmann
2012-09-05 15:39 ` Don Slutz [this message]
2012-09-06 5:56 ` [SeaBIOS] " 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=50477245.4030003@CloudSwitch.Com \
--to=don@cloudswitch.com \
--cc=kevin@koconnor.net \
--cc=kraxel@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=seabios@seabios.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.