grub-devel.gnu.org archive mirror
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: Vitaly Kuznetsov <vkuznets@redhat.com>
Cc: The development of GNU GRUB <grub-devel@gnu.org>,
	mchang@suse.com, decui@microsoft.com, lersek@redhat.com
Subject: Re: [PATCH] calibrate_tsc(): use the Stall() EFI boot service on GRUB_MACHINE_EFI
Date: Mon, 30 Nov 2015 20:34:18 +0300	[thread overview]
Message-ID: <565C889A.6030409@gmail.com> (raw)
In-Reply-To: <565C7E3A.3090004@gmail.com>

30.11.2015 19:50, Andrei Borzenkov пишет:
> 30.11.2015 19:31, Vitaly Kuznetsov пишет:
>> Andrei Borzenkov <arvidjaar@gmail.com> writes:
>>
>>> 26.11.2014 11:59, Laszlo Ersek пишет:
>>>> HyperV Gen2 virtual machines have no PIT; guest code should rely on UEFI
>>>> services instead.
>>>>
>>>
>>> Could you retest with current master? It now supports multiple methods
>>> to calibrate TSC and should avoid PIT on UEFI systems.
>>
>> Unfortunately, current master (grub-2.02-beta2-561-g346a494) still
>> doesn't work for me, timer keeps running like crazy on Gen2 Hyper-V VMs.
>>
> 
> @Michael: I remember you tested version of Vladimir patch on Hyper-V?
> Could you test current master?
> 


  if ((grub_inb (GRUB_PIT_SPEAKER_PORT) & GRUB_PIT_SPK_TMR2_LATCH)) {
    ret = 1;
    /* Wait.  */
    while ((grub_inb (GRUB_PIT_SPEAKER_PORT) & GRUB_PIT_SPK_TMR2_LATCH)
== 0x00);
  }


If PIT is not present all reads should return 0xff so this will always
succeed, right? Linux kernel is using some sanity checks, if loop
terminated too early it assumes calibration failure.



  reply	other threads:[~2015-11-30 17:34 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-26  8:59 [PATCH] calibrate_tsc(): use the Stall() EFI boot service on GRUB_MACHINE_EFI Laszlo Ersek
2014-11-26 13:42 ` Andrei Borzenkov
2014-11-26 13:49   ` Laszlo Ersek
2014-11-28 19:25 ` Vladimir 'φ-coder/phcoder' Serbinenko
2014-12-03 18:59   ` Andrei Borzenkov
2015-11-27 17:55 ` Andrei Borzenkov
2015-11-28  5:25   ` Elliott, Robert (Persistent Memory)
2015-11-28  6:02     ` Andrei Borzenkov
2015-11-30 16:31   ` Vitaly Kuznetsov
2015-11-30 16:50     ` Andrei Borzenkov
2015-11-30 17:34       ` Andrei Borzenkov [this message]
2015-11-30 18:19         ` Vitaly Kuznetsov
2015-12-01  3:11         ` Michael Chang
2015-12-01  8:34           ` Vitaly Kuznetsov
2015-12-01 15:54             ` Andrei Borzenkov
2015-12-02 11:02               ` Vitaly Kuznetsov

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=565C889A.6030409@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=decui@microsoft.com \
    --cc=grub-devel@gnu.org \
    --cc=lersek@redhat.com \
    --cc=mchang@suse.com \
    --cc=vkuznets@redhat.com \
    /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;
as well as URLs for NNTP newsgroup(s).