Hello,
Not sure if this is the proper forum, or not, but...
We are working on bringing up a new set-top device, based heavily on
legacy-free pc hardware.
So far, we have had much success, basing our BSP heavily on CEPC. The
kernel is coming up, a very simple display driver is in place, and we are
able to launch userland processes. However, we have hit a major roadblock
that is beginning to cause us much grief.
Our device has a bit of a nonstandard PCI bus, so instead of using the PCI
enumerator we decided to 'hardcode' the device settings in the registry, as
there is really only one device we are concerned with, an OHCI usb
controller. This usb controller is on IRQ 1 and at a membase of 0xFED00000
So, we've set the relevant registry settings as:
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\OHCI]
"Prefix"="HCD"
"Dll"="ohci2.dll"
"Order"=dword:2
"Class"=dword:0c
"SubClass"=dword:03
"ProgIF"=dword:10
"IsrDll"="giisr.dll"
"IsrHandler"="ISRHandler"
"MemBase"=dword:fed00000
"MemLen"=dword:1000
"Irq"=dword:1
"SysIntr"=dword:11
"BusNumber"=dword:0
"DeviceNumber"=dword:2
"FunctionNumber"=dword:0
(Perhaps overkill, but...)
Now, when we boot, the driver loads alright, but the following appears:
0x839f58a8: CHub(Root tier 0)::HubStatusChangeThread - device attached on
port 1
0x839f58a8: +CHub(Root tier 0)::AttachDevice - port = 1, fIsLowSpeed = 0
0x839f58a8: CHub(Root tier 0)::AttachDevice - status =
DEVICE_CONFIG_STATUS_OPENING_ENDPOINT0_PIPE, failures = 0
0x839f58a8: CHub(Root tier 0)::AttachDevice - status =
DEVICE_CONFIG_STATUS_USING_ADDRESS0, failures = 0
0x839f58a8: CHub(Root tier 0)::AttachDevice - status =
DEVICE_CONFIG_STATUS_RESET_AND_ENABLE_PORT, failures = 0
0x839f58a8: USB HCD: DEBUGCHK failed in file
d:\mckendric\public\common\oak\drivers\usb\hcd\ohcd2\.\chw.cpp at line 994
0x839f58a8: DEBUG_BREAK @0258e866 Ignored.
0x839f58a8: CHub(Root tier 0)::AttachDevice - status =
DEVICE_CONFIG_STATUS_SCHEDULING_SET_ADDRESS, failures = 0
We've investigated, some, and it appears that what is happening is that the
driver is attempting to send a "reset" to the first port. When the port
receives this reset, it is supposed to reset (obviously) and generate some
interrupt (in some OHCI references we've seen this interrupt referred to as
"DEVICE_ATTACHED") which should, I'm assuming, call back into the driver,
clearing some PRSC flag. The code relevant to where the DEBUGCHK is failing
is:
DEBUGCHK ( m_portBase->HcRhPortStatus[port-1].PRSC == 1 );
RootHubFeature(port, USB_REQUEST_CLEAR_FEATURE,
USB_HUB_FEATURE_C_PORT_RESET);
DEBUGCHK ( m_portBase->HcRhPortStatus[port-1].PRSC == 0 );
It is the second DEBUGCHK that is failing.
From here, we're stuck. We're not sure where to go next, with this problem.
Any help, or a nudge in the right direction, would be GREATLY appreciated.
Thank you in advance,
--Nathan Cain