Date: Mon, 23 Jan 2012 18:29:19 +0100 From: Hans Petter Selasky <hselasky@c2i.net> To: freebsd-current@freebsd.org Cc: Kohji Okuno <okuno.kohji@jp.panasonic.com> Subject: Re: Is UPS_PORT_POWER wrong? Message-ID: <201201231829.19576.hselasky@c2i.net> In-Reply-To: <20120123.171246.321689433999174416.okuno.kohji@jp.panasonic.com> References: <20120123.171246.321689433999174416.okuno.kohji@jp.panasonic.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Monday 23 January 2012 09:12:46 Kohji Okuno wrote:
> Hi HPS,
>
> I think that UPS_PORT_POWER and UPS_PORT_LINK_STATE overlap.
> And, in xhci.c you set UPS_PORT_POWER as folows.
>
> When UPS_PORT_POWER is set, UPS_PORT_LINK_STATE_GET() macro will
> return incorrect value.
>
> if (v & XHCI_PS_PP) {
> /*
> * The USB 3.0 RH is using the
> * USB 2.0's power bit
> */
> i |= UPS_PORT_POWER;
> }
>
Hi,
The USB 3.0 root HUB is special because it defines FULL/HIGH and LOW speed, so
I had to merge that into the port status register of the XHCI root HUB like
this:
0: CONNECT_STATUS
1: PORT_ENABLED
2: SUSPEND
3: OVERCURRENT_INDICATOR
4: LINK STATE (USB 3.0)
5: -
6: -
7: -
8: PORT_POWER (USB 2.0)
# Bit 9+10 have 4 combinations which are defined: FS, LW, HS, SS
9: LOW_SPEED (USB 2.0)
10: HIGH_SPEED (USB 2.0)
11: not implemented
12: PORT_INDICATOR
13:
14:
15: MODE_DEVICE (FreeBSD specific)
If you have a better idea, it is possible to change this.
--HPS
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201201231829.19576.hselasky>
