From: "David E. Box" <david.e.box@linux.intel.com>
To: grub-devel@gnu.org
Subject: Re: [PATCH] tsc: Change default tsc calibration method to EFI on EFI systems
Date: Fri, 15 Sep 2017 15:06:22 -0700 [thread overview]
Message-ID: <1505513182.6240.29.camel@linux.intel.com> (raw)
In-Reply-To: <CAEaD8JMpyRsZQ6JA+ZYe94_cWyFJkhSghtnfej67D7+7CVoXaw@mail.gmail.com>
On Tue, 2017-09-12 at 23:46 +0000, Vladimir 'phcoder' Serbinenko wrote:
>
>
> On Wed, Sep 6, 2017, 22:21 David E. Box <david.e.box@linux.intel.com>
> wrote:
> > On efi systems, make efi based tsc calibration the default,
> > followed by
> > the pmtimer before using the pit. This prevents Grub boot failure
> > on
> > newer x86 systems that power gate the pit.
>
> Why does put code fail? I think it was changed to detect gated pit.
On these systems, even though the pit is gated the timer2 latch logic
still works. So when the tics are set the latch still goes from high to
active low as expected for a functional timer. But since the device is
clock gated it never counts down and the bit never gets reset, leading
to an infinite loop.
> Also I'd prefer to use pmtimer first as we had problems with event
> and time routines on some Macs. Any reason not to use pmtimer first?
No reason not to use pmtimer first. I had not considered boot speed as
well which must be prioritized. I'll submit a new patch.
> > Signed-off-by: David E. Box <david.e.box@linux.intel.com>
> > ---
> > grub-core/kern/i386/tsc.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/grub-core/kern/i386/tsc.c b/grub-core/kern/i386/tsc.c
> > index 2e85289d8..de4057ddb 100644
> > --- a/grub-core/kern/i386/tsc.c
> > +++ b/grub-core/kern/i386/tsc.c
> > @@ -68,7 +68,7 @@ grub_tsc_init (void)
> > #ifdef GRUB_MACHINE_XEN
> > (void) (grub_tsc_calibrate_from_xen () ||
> > calibrate_tsc_hardcode());
> > #elif defined (GRUB_MACHINE_EFI)
> > - (void) (grub_tsc_calibrate_from_pit () ||
> > grub_tsc_calibrate_from_pmtimer () || grub_tsc_calibrate_from_efi()
> > || calibrate_tsc_hardcode());
> > + (void) (grub_tsc_calibrate_from_efi () ||
> > grub_tsc_calibrate_from_pmtimer () || grub_tsc_calibrate_from_pit
> > () || calibrate_tsc_hardcode());
> > #elif defined (GRUB_MACHINE_COREBOOT)
> > (void) (grub_tsc_calibrate_from_pmtimer () ||
> > grub_tsc_calibrate_from_pit () || calibrate_tsc_hardcode());
> > #else
> > --
> > 2.13.5
> >
> >
> > _______________________________________________
> > Grub-devel mailing list
> > Grub-devel@gnu.org
> > https://lists.gnu.org/mailman/listinfo/grub-devel
>
> _______________________________________________
> Grub-devel mailing list
> Grub-devel@gnu.org
> https://lists.gnu.org/mailman/listinfo/grub-devel
prev parent reply other threads:[~2017-09-15 22:06 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-06 20:20 [PATCH] tsc: Change default tsc calibration method to EFI on EFI systems David E. Box
2017-09-06 20:56 ` Joe Konno
2017-09-12 7:10 ` Paul Menzel
2017-09-12 23:40 ` David E. Box
2017-09-12 23:46 ` Vladimir 'phcoder' Serbinenko
2017-09-15 22:06 ` David E. Box [this message]
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=1505513182.6240.29.camel@linux.intel.com \
--to=david.e.box@linux.intel.com \
--cc=grub-devel@gnu.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.