Fix a register issue.
This commit is contained in:
parent
bdfdc65bf6
commit
2f03186b0b
|
@ -401,7 +401,8 @@ static void xhci_legacy_claim ( struct xhci_host *xhci ) {
|
|||
*/
|
||||
USB_LOG_DBG("XHCI %s could not claim ownership from BIOS: forcibly "
|
||||
"disabling SMIs\n", xhci->name );
|
||||
writel ( 0, xhci->cap + xhci->legacy + XHCI_USBLEGSUP_CTLSTS );
|
||||
// writel ( 0, xhci->cap + xhci->legacy + XHCI_USBLEGSUP_CTLSTS );
|
||||
writel ( 0, xhci->cap_addr + xhci->legacy + XHCI_USBLEGSUP_CTLSTS );
|
||||
}
|
||||
|
||||
/** Prevent the release of ownership back to BIOS */
|
||||
|
@ -601,10 +602,13 @@ static unsigned int xhci_port_protocol ( struct xhci_host *xhci,
|
|||
/* Describe port protocol */
|
||||
#if XHCI_DUMP
|
||||
{
|
||||
name.raw = CPU_TO_LE32 ( readl ( xhci->cap + supported +
|
||||
// name.raw = CPU_TO_LE32 ( readl ( xhci->cap + supported +
|
||||
// XHCI_SUPPORTED_NAME ) );
|
||||
name.raw = CPU_TO_LE32 ( readl ( xhci->cap_addr + supported +
|
||||
XHCI_SUPPORTED_NAME ) );
|
||||
name.text[4] = '\0';
|
||||
slot = readl ( xhci->cap + supported + XHCI_SUPPORTED_SLOT );
|
||||
// slot = readl ( xhci->cap + supported + XHCI_SUPPORTED_SLOT );
|
||||
slot = readl ( xhci->cap_addr + supported + XHCI_SUPPORTED_SLOT );
|
||||
type = XHCI_SUPPORTED_SLOT_TYPE ( slot );
|
||||
USB_LOG_DBG("XHCI %s-%d %sv%04x type %d \r\n",
|
||||
xhci->name, port, name.text, protocol, type );
|
||||
|
@ -1118,7 +1122,8 @@ static void xhci_event_free ( struct xhci_host *xhci ) {
|
|||
static void xhci_command_free ( struct xhci_host *xhci ) {
|
||||
|
||||
/* Sanity check */
|
||||
USB_ASSERT ( ( readl ( xhci->op + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
// USB_ASSERT ( ( readl ( xhci->op + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
USB_ASSERT ( ( readl ( xhci->op_addr + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
|
||||
/* Clear command ring control register */
|
||||
// xhci_writeq ( xhci, 0, xhci->op + XHCI_OP_CRCR );
|
||||
|
@ -1647,7 +1652,8 @@ static void xhci_abort ( struct xhci_host *xhci ) {
|
|||
usb_osal_msleep ( XHCI_COMMAND_ABORT_DELAY_MS );
|
||||
|
||||
/* Sanity check */
|
||||
USB_ASSERT ( ( readl ( xhci->op + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
// USB_ASSERT ( ( readl ( xhci->op + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
USB_ASSERT ( ( readl ( xhci->op_addr + XHCI_OP_CRCR ) & XHCI_CRCR_CRR ) == 0 );
|
||||
|
||||
/* Consume (and ignore) any final command status */
|
||||
int cc = xhci_event_wait(xhci, xhci->cur_cmd_pipe, xhci->cmds);
|
||||
|
|
|
@ -99,7 +99,7 @@ int main(int argc, char* argv[])
|
|||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
printf("main usb3 id(%d) init.\r\n", id);
|
||||
printf("main usb3 id=%d init.\r\n", id);
|
||||
usb_init(id);
|
||||
|
||||
ipc_rndis_init();
|
||||
|
|
Loading…
Reference in New Issue