Date: Wed, 19 Sep 2012 15:51:38 -0600 From: Ian Lepore <freebsd@damnhippie.dyndns.org> To: Adrian Chadd <adrian@freebsd.org> Cc: lev@freebsd.org, freebsd-current@freebsd.org Subject: Re: Latest -CURRENT/i386 could not start under VirutalBox 4.1.18 and 4.2 (Windows host): hangs up after atrtc0 detection Message-ID: <1348091498.95562.66.camel@revolution.hippie.lan> In-Reply-To: <CAJ-VmonKHCeA=cDJd-n9KO400RLFWNFGYLvUs0XEoCgrG4b5_A@mail.gmail.com> References: <80840563.20120920002200@serebryakov.spb.ru> <1252171344.20120920003724@serebryakov.spb.ru> <1348087584.95562.55.camel@revolution.hippie.lan> <1859311530.20120920005449@serebryakov.spb.ru> <CAJ-VmokF=JK=TS34CdHqO5BTh6WN950tdK0C%2BUOWpFoQhTHhYA@mail.gmail.com> <1348088706.95562.61.camel@revolution.hippie.lan> <CAJ-Vmon-Mv21PB06ZdC2N1FguD4kHnsNt1kny9T=eHQXRygojA@mail.gmail.com> <1348089126.95562.62.camel@revolution.hippie.lan> <CAJ-VmonKHCeA=cDJd-n9KO400RLFWNFGYLvUs0XEoCgrG4b5_A@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 2012-09-19 at 14:30 -0700, Adrian Chadd wrote: > On 19 September 2012 14:12, Ian Lepore <freebsd@damnhippie.dyndns.org> wrote: > > >> Right. Being totally clueless, is atrc_start() called just at > >> probe/attach, or during normal operation? > >> > > > > It's called just once, from the attach() routine for the rtc device. > > Right. Just have it loop over say 100 times, with a 10us sleep between > each. Shouldn't that be enough? > If by "sleep" you mean any form of pausing or sleeping that waits for a given amount of time... remember when this code is running we're still in the process of trying to figure out which clocks can be used for such purposes. That leaves DELAY(), which does pretty much the equivelent of what the loop in question is doing. Hmmm, but DELAY() does have the advantage of busy-looping for a known amount of time, making it easier to constrain the time spent in the loop regardless of the speed of the cpu. I'll have to look into how DELAY() is implemented for x86 and see if it's usable in this context. -- Ian
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1348091498.95562.66.camel>