Of the four controller types, EHCI is not my favorite. Let me pull out my notes....
While I am thinking about it, how about the Port Owner bit? What value does it hold?
To see if the attached device is a low-speed device, read the Line Status bits. If the value is 01b, you have a low speed device. If not 01b, you have a full- or high-speed device and must do a reset to find out which.
The reset can be complicated.
1) The USBSTS:HcHalted bit must be zero, hence, the schedule must be running
2) Set the Port Reset bit and clear the Port Enabled bit at the same time
3) Since this is a root hub, make sure you assert the reset for 50ms.
4) Wait for the bit to clear
5) Pause for TRSTRCY (recovery time)
Now, if the Enable bit is set, you have a high-speed device. This is what you have stated already, so let's assume so.
Make sure that all QH's and TD's do not cross a 4k boundary, which I think you have already done so.
In your TDs, make sure that the first transfer, the first access of CPAGE and OFFSET doesn't cross to the next 4k page. For example, if your first few bytes to transfer is at 0x123400F8, you can only transfer 8 bytes until the controller moves to the next CPAGE entry. Again, I think you've got this covered.
With all of this in mind, I don't know why you are getting a Transaction Error. I admit though, I don't use Virtual Box. I prefer Bochs when debugging my code. Volker has created the EHCI part of bochs, but has included a lot of my techniques pulled from the UHCI, OHCI, and xHCI code, which I did write. Bochs will allow you to set a DEBUG flag for the EHCI and it will log all errors including current processed TD's, etc.
(Side note: I also have an advantage. The good people at
Totalphase sent me a Beagle12 and it has helped with my research more than anything else.)
Have you tried your code on real hardware?
At the moment, and with out actually working with your code, I don't think I have much more for you. I hope that you can get it, and I am interested in your outcome.
Ben