ehci-ppc4xx.c 769 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * (C) Copyright 2010, Chris Zhang <chris@seamicro.com>
  3. *
  4. * Author: Chris Zhang <chris@seamicro.com>
  5. * This code is based on ehci freescale driver
  6. *
  7. * SPDX-License-Identifier: GPL-2.0+
  8. */
  9. #include <common.h>
  10. #include <usb.h>
  11. #include "ehci.h"
  12. /*
  13. * Create the appropriate control structures to manage
  14. * a new EHCI host controller.
  15. */
  16. int ehci_hcd_init(int index, enum usb_init_type init,
  17. struct ehci_hccr **hccr, struct ehci_hcor **hcor)
  18. {
  19. *hccr = (struct ehci_hccr *)(CONFIG_SYS_PPC4XX_USB_ADDR);
  20. *hcor = (struct ehci_hcor *)((uint32_t) *hccr +
  21. HC_LENGTH(ehci_readl(&(*hccr)->cr_capbase)));
  22. return 0;
  23. }
  24. /*
  25. * Destroy the appropriate control structures corresponding
  26. * the the EHCI host controller.
  27. */
  28. int ehci_hcd_stop(int index)
  29. {
  30. return 0;
  31. }