X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=drivers%2Fusb%2Fhost%2Fehci-pci.c;h=020ab11355eb81c5acfc44b33521fec37704c7bf;hb=1b719e66548a50ac763eebf9513bf1e58e8fb6ff;hp=441b1a271439580d3b6e7388817e7a2ac7a9418f;hpb=f75a729b5c1434d5a5bbf453b1b699bf1c3ffbce;p=u-boot diff --git a/drivers/usb/host/ehci-pci.c b/drivers/usb/host/ehci-pci.c index 441b1a2714..020ab11355 100644 --- a/drivers/usb/host/ehci-pci.c +++ b/drivers/usb/host/ehci-pci.c @@ -28,6 +28,9 @@ #ifdef CONFIG_PCI_EHCI_DEVICE static struct pci_device_id ehci_pci_ids[] = { /* Please add supported PCI EHCI controller ids here */ + {0x1033, 0x00E0}, /* NEC */ + {0x10B9, 0x5239}, /* ULI1575 PCI EHCI module ids */ + {0x12D8, 0x400F}, /* Pericom */ {0, 0} }; #endif @@ -39,7 +42,6 @@ static struct pci_device_id ehci_pci_ids[] = { int ehci_hcd_init(void) { pci_dev_t pdev; - uint32_t addr; pdev = pci_find_devices(ehci_pci_ids, CONFIG_PCI_EHCI_DEVICE); if (pdev == -1) { @@ -47,11 +49,15 @@ int ehci_hcd_init(void) return -1; } - pci_read_config_dword(pdev, PCI_BASE_ADDRESS_0, &addr); - hccr = (struct ehci_hccr *)addr; + hccr = (struct ehci_hccr *)pci_map_bar(pdev, + PCI_BASE_ADDRESS_0, PCI_REGION_MEM); hcor = (struct ehci_hcor *)((uint32_t) hccr + HC_LENGTH(ehci_readl(&hccr->cr_capbase))); + debug("EHCI-PCI init hccr 0x%x and hcor 0x%x hc_length %d\n", + (uint32_t)hccr, (uint32_t)hcor, + (uint32_t)HC_LENGTH(ehci_readl(&hccr->cr_capbase))); + return 0; }