From: Christian Franke <Christian.Franke@t-online.de>
To: The development of GRUB 2 <grub-devel@gnu.org>
Subject: Re: [PATCH] Fix infinite loop in grub_pit_wait()
Date: Thu, 07 Aug 2008 21:44:43 +0200 [thread overview]
Message-ID: <489B50AB.1040403@t-online.de> (raw)
In-Reply-To: <20080807161059.GB14153@thorin>
Robert Millan wrote:
> On Thu, Aug 07, 2008 at 05:32:42PM +0200, Christian Franke wrote:
>
>> grub2 from current SVN hangs if run in VirtualPC, the problem was
>> introduced with 'svn diff -r 1779:1780'.
>>
>
> I'm not familiar with this part of the PIT interface; why does it hang
> only on VirtualPC?
>
>
Possibly different BIOS init of 0x61? Or different implementation of the
legacy hardware, which IIRC looks like this:
. +-------+ /--------->0x61[5]
. ...--Clock-->| Timer | |
.0x61[0]---Gate-->| 2 |-Out-+->+---+
. +-------+ | & |-->Speaker
.0x61[1]-------------------------->+---+
Resulting values of "tsc_ticks_per_ms" (AMD 3.2@2Ghz):
. orig with patch
VMware: ~1500 ~2000000
VirtualBox: ~2000000 ~2000000
VirtualPC: hang ~2000000
>> ...
>> + /* Disable timer2 gate and speaker. */
>> + grub_outb (grub_inb (TIMER2_REG_LATCH) & ~ (TIMER2_SPEAKER | TIMER2_GATE), TIMER2_REG_LATCH);
>> }
>>
>
> This doesn't AFAICT preserve the existing value of the timer2 gate and speaker.
> I assume that is ok?
>
>
IMO yes. The timer state itself cannot be preserved, so it should be
safe to leave it disabled. To test, try If BIOS speaker output (echo -e
"\a") still works.
> Thanks!
>
>
You're welcome.
Patch committed.
Christian
next prev parent reply other threads:[~2008-08-07 19:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-07 15:32 [PATCH] Fix infinite loop in grub_pit_wait() Christian Franke
2008-08-07 16:10 ` Robert Millan
2008-08-07 19:44 ` Christian Franke [this message]
2008-08-07 16:26 ` Marco Gerards
2008-08-07 19:46 ` Christian Franke
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=489B50AB.1040403@t-online.de \
--to=christian.franke@t-online.de \
--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.