Patchwork option rom problems with DBM690T+VT6202L

login
register
about
Submitter Leandro Dorileo
Date 2009-07-28 13:39:28
Message ID <d68f80d90907280639n2dded4e4m4c316351dfbde276@mail.gmail.com>
Download mbox | patch
Permalink /patch/80/
State Superseded
Headers show

Comments

Leandro Dorileo - 2009-07-28 13:39:28
Hi Jason

On Tue, Jul 28, 2009 at 9:17 AM, Jason Wang<wangqingpei@gmail.com> wrote:
> hi Kevin,
>   the attach file is the whole log
>
> On Tue, Jul 28, 2009 at 7:32 AM, Kevin O'Connor <kevin@koconnor.net> wrote:
>>
>> On Mon, Jul 27, 2009 at 11:42:18PM +0800, Jason Wang wrote:
>> > Hi all,
>> >    Since DBM690T does not have UHCI controller, i bought an PCI-USB card
>> > which contained two UHCI controller.



It seems your card(surely) has a single UHCI controller, but (maybe) 2
USB ports(I say based on you log output).



>> > But It always caused rebooting when
>> > the
>> > option rom try to initialize the controller. I attached all of the
>> > messages,
>> > and looking for some help.



I feel it`s stranger to not see any message during the UHCI
initialization, but reboot is normal, if the option ROM don`t do
anything it will fallback to BIOS. I mean by "don`t do anything" if it
doesn`t load the boot sector and/or start executing something when it
finishes the Host Controller initialization.

Your log makes me think you don`t have a MSC device attached to any of
the ports. So I have attached a patch to see if the Root Hub
initialization has successfully finished, could you apply the attached
patch to libpayload and show the output?


>> > Until now my doubt is the real bus/dev/func is 06/05/01, but while
>> > seabios
>> > search it as 00/05/01.
>>
>> Please post a log with the seabios debug level set to 6.
>>
>> -Kevin
>
>
>
> --
> Jason Wang
> Peking University
>

Thanks....
Jason Wang - 2009-07-28 14:00:01
hi dorileo,
   The card has two UHCI controller and one EHCI controller.And i have
already attached a MSC device to the disk. it sill could not run to the
function uhci_rh_enable_port

On Tue, Jul 28, 2009 at 9:39 PM, Leandro Dorileo <ldorileo@gmail.com> wrote:

> Hi Jason
>
> On Tue, Jul 28, 2009 at 9:17 AM, Jason Wang<wangqingpei@gmail.com> wrote:
> > hi Kevin,
> >   the attach file is the whole log
> >
> > On Tue, Jul 28, 2009 at 7:32 AM, Kevin O'Connor <kevin@koconnor.net>
> wrote:
> >>
> >> On Mon, Jul 27, 2009 at 11:42:18PM +0800, Jason Wang wrote:
> >> > Hi all,
> >> >    Since DBM690T does not have UHCI controller, i bought an PCI-USB
> card
> >> > which contained two UHCI controller.
>
>
>
> It seems your card(surely) has a single UHCI controller, but (maybe) 2
> USB ports(I say based on you log output).
>
>
>
> >> > But It always caused rebooting when
> >> > the
> >> > option rom try to initialize the controller. I attached all of the
> >> > messages,
> >> > and looking for some help.
>
>
>
> I feel it`s stranger to not see any message during the UHCI
> initialization, but reboot is normal, if the option ROM don`t do
> anything it will fallback to BIOS. I mean by "don`t do anything" if it
> doesn`t load the boot sector and/or start executing something when it
> finishes the Host Controller initialization.
>
> Your log makes me think you don`t have a MSC device attached to any of
> the ports. So I have attached a patch to see if the Root Hub
> initialization has successfully finished, could you apply the attached
> patch to libpayload and show the output?
>
>
> >> > Until now my doubt is the real bus/dev/func is 06/05/01, but while
> >> > seabios
> >> > search it as 00/05/01.
> >>
> >> Please post a log with the seabios debug level set to 6.
> >>
> >> -Kevin
> >
> >
> >
> > --
> > Jason Wang
> > Peking University
> >
>
> Thanks....
>
> --
> (°=   Leandro Dorileo
> //\    ldorileo@gmail.com   -   http://www.dorilex.net
> V_/  Software is a matter of freedom.
>
Peter Stuge - 2009-07-29 01:58:53
Jason Wang wrote:
> The card has two UHCI controller and one EHCI controller.

Note that it is not in fact a UHCI controller if it supports USB 2.0.
It is difficult (maybe impossible) to find a UHCI PCI card.

An EHCI controller will only and always communicate with high-speed
devices using EHCI.

The EHCI controller and it's so-called companion controllers do not
mirror each port. Any connected device will only appear attached to
one controller, and it will always be the same controller for a given
device and a given physical port.

In other words, for you to be able to use UHCI with this PCI card,
you must attach a USB 1.1-only MSC device to one of the ports.

Please have a look at the EHCI standard[1] for more details, and feel
free to ask questions. Especially Figure 1-1 and the descriptions on
the same page (3) are very good for getting a better understanding of
these parts of USB.


//Peter


[1] http://www.intel.com/technology/usb/download/ehci-r10.pdf
Stefan Reinauer - 2009-07-30 17:15:05
On 7/29/09 3:58 AM, Peter Stuge wrote:
> Note that it is not in fact a UHCI controller if it supports USB 2.0.
> It is difficult (maybe impossible) to find a UHCI PCI card.
>
> An EHCI controller will only and always communicate with high-speed
> devices using EHCI.
>
> The EHCI controller and it's so-called companion controllers do not
> mirror each port. Any connected device will only appear attached to
> one controller, and it will always be the same controller for a given
> device and a given physical port.
>
> In other words, for you to be able to use UHCI with this PCI card,
> you must attach a USB 1.1-only MSC device to one of the ports.
>   
This is interesting, since we have not seen this problem on any Intel
chipset, which have EHCI controllers but do UHCI, too.
It's never been a problem to use the UHCI stack with USB 2.0 capable
devices. Are they doing something special?
I never saw an EHCI only controller, all of them came with either UHCI
or OHCI

Stefan

Patch

diff --git a/drivers/usb/uhci_rh.c b/drivers/usb/uhci_rh.c
index cc3c600..4c73ca6 100644
--- a/drivers/usb/uhci_rh.c
+++ b/drivers/usb/uhci_rh.c
@@ -41,6 +41,7 @@  uhci_rh_enable_port (usbdev_t *dev, int port)
 {
 	u16 value;
 	hci_t *controller = dev->controller;
+    printf("UHCI Root Hub enabling port %d.", port);
 	if (port == 1)
 		port = PORTSC1;
 	else
@@ -57,6 +58,7 @@  uhci_rh_enable_port (usbdev_t *dev, int port)
 		value = uhci_reg_read16 (controller, port);
 		mdelay (1);
 	} while (((value & (1 << 2)) == 0) && (value & 0x01));
+    printf("UHCI Root Hub port %d enabled.", port);
 }
 
 /* disable root hub */
@@ -165,4 +167,5 @@  uhci_rh_init (usbdev_t *dev)
 	dev->address = 0;
 	dev->hub = -1;
 	dev->port = -1;
+    printf("UHCI Root Hub enabled.", port);
 }