<div dir="ltr"><div>Hi<br></div><div>Is there a mechanism to save log messages at boot time?<br></div><div>I tested again and found that ehci_wait_td function timeouts in all execution of for loop including first.<br></div><div>which registers you want to know?<br></div><div>i got these information from log messages:<br></div><div><br>pipe->qh.current = 0x1eff8d80<br></div><div>pipe->qh.token = 0x00400141<br></div><div>pipe->qh.qtd_next = 0x1efff140<br></div><div>td->token = 0x00400c80<br></div><div>pipe->qh.info1 = 0x00400202<br></div><div>pipe->qh.info2 = 0x00400202<br><br><br></div><div>for uhci i used vmware workstation and it works perfectly and i can send and receive data from hid device, but my real hardware does not have uhci controller , instead it has 2 EHCI controller with rate matching hub, so i should use ehci driver for this kind of controller.  </div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Mar 15, 2015 at 7:03 PM, Kevin O'Connor <span dir="ltr"><<a href="mailto:kevin@koconnor.net" target="_blank">kevin@koconnor.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Sun, Mar 15, 2015 at 12:32:04PM +0330, Navid Movahedi wrote:<br>
> Hi<br>
> I have a usb 1 HID device with 2 endpoints, 1 in, 1 out, and i want to<br>
> enumerate this usb device with seabios at boot time, so i hacked<br>
> seabios hid source code and add needed codes for this device. now<br>
> device is full functional with uhci driver in vmware and i have no<br>
> problem with read and write to device . the problem is for machines<br>
> with ehci controllers that don't have companion uhci controller and<br>
> uses rate matching hub to connect to this usb 1 device. The currewnt<br>
> status for this kind of controller is that the device is detected and<br>
> configured and 2 endpoints and corresponding 2 interrupt pipes are<br>
> allocated and initialized but when i use usb_send_pipe function to<br>
> write to device , error occurs . error is Timeout in ehci_wait_td<br>
> function in this section of code:<br>
><br>
> for (i=0, td=tds; i<STACKQTDS; i++, td++) {<br>
>           ret = ehci_wait_td(pipe, td, end);<br>
>               if (ret)<br>
>                       return -1;<br>
> }<br>
><br>
> timeout occurs for second td. i called usb_send_pipe function in this way:<br>
><br>
> usb_send_pipe(out_pipe, USB_DIR_OUT , NULL , data, 64);<br>
><br>
> is it correct?<br>
><br>
> How can i solve this problem?<br>
<br>
</div></div>We'd need to see the full seabios log in order to help.  When the EHCI<br>
controller complains, it should also print out some ehci registers<br>
which give further information on what the controller was doing at the<br>
time of the error.<br>
<br>
Was this second ehci setup also on vmware or on some other<br>
emulator/real hardware?<br>
<span class="HOEnZb"><font color="#888888"><br>
-Kevin<br>
</font></span></blockquote></div><br></div>