9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Lonnie Mendez <lmendez19@austin.rr.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu>
Subject: Re: [9fans] question on implementation of uhci host controller driver
Date: Sat, 18 Mar 2006 02:46:48 -0600	[thread overview]
Message-ID: <441BC8F8.50002@austin.rr.com> (raw)
In-Reply-To: <0da22f726ce8d3d875d3d6710f523acd@terzarima.net>

Charles Forsyth wrote:

>>being set.  Of course this doesn't explain why it works on physical
>>hardware.
>>
>>
>
>probably because the bit reflects the state of the frame processor,
>so that the bit is set iff it is halted, regardless how it came to be that way
>(which is what i'd expected, and indeed  i believe that bit is set after reset).
>it's a reasonable way to do the hardware, but software probably just
>memsets an emulated register to 0 and doesn't set the bit initially.
>
   Hm.  The initial (default) value for USBSTS register is 0.  Looking
at HCRESET it states that "the Host Controller module resets its
internal timers, counters, state machines, etc to their initial value."
GRESET does something similar.  If the initial value isn't the default
value then I'll be understanding this a whole lot better.  For
comparison, here is the initial take from windows xp's uhci driver:

uhci readw port=0x0000 val=0x0000
uhci writew port=0x0000 val=0x0004
uhci writew port=0x0000 val=0x0000
uhci writew port=0x0004 val=0x0000
uhci readw port=0x0000 val=0x0000
uhci writew port=0x0000 val=0x0000
uhci readw port=0x0002 val=0x0000
uhci readw port=0x0002 val=0x0000
uhci readw port=0x0002 val=0x0000
uhci readw port=0x0002 val=0x0000



  reply	other threads:[~2006-03-18  8:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-18  4:21 Lonnie Mendez
2006-03-18  7:50 ` Charles Forsyth
2006-03-18  8:08   ` Lonnie Mendez
2006-03-18  8:16     ` Charles Forsyth
2006-03-18  8:46       ` Lonnie Mendez [this message]
2006-03-18  8:53         ` Charles Forsyth
2006-03-18 19:53           ` Lonnie Mendez
2006-03-20 15:55   ` Charles Forsyth

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=441BC8F8.50002@austin.rr.com \
    --to=lmendez19@austin.rr.com \
    --cc=9fans@cse.psu.edu \
    /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).