diff options
author | Simon Glass <sjg@chromium.org> | 2015-03-25 12:22:27 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2015-04-18 11:11:24 -0600 |
commit | deb8508c518b8e49f2cd3199861e639d9eeebd9f (patch) | |
tree | 910919cd533a774a43bb0263eef5b9f3f6880710 /drivers/usb/host/ehci-mx5.c | |
parent | 7372b5bd318515c0e756a96e1f730a3ff119bd31 (diff) | |
download | u-boot-imx-deb8508c518b8e49f2cd3199861e639d9eeebd9f.zip u-boot-imx-deb8508c518b8e49f2cd3199861e639d9eeebd9f.tar.gz u-boot-imx-deb8508c518b8e49f2cd3199861e639d9eeebd9f.tar.bz2 |
dm: usb: Drop the EHCI weak functions
These are a pain with driver model because we might have different EHCI
drivers which want to implement them differently. Now that they use
consistent function signatures, we can in good conscience move them to
a struct.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Marek Vasut <marex@denx.de>
Fix non-driver-model EHCI to set up the EHCI operations correctly:
Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers/usb/host/ehci-mx5.c')
-rw-r--r-- | drivers/usb/host/ehci-mx5.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/usb/host/ehci-mx5.c b/drivers/usb/host/ehci-mx5.c index 7566c61..d319962 100644 --- a/drivers/usb/host/ehci-mx5.c +++ b/drivers/usb/host/ehci-mx5.c @@ -218,11 +218,23 @@ void __weak board_ehci_hcd_postinit(struct usb_ehci *ehci, int port) { } +__weak void mx5_ehci_powerup_fixup(struct ehci_ctrl *ctrl, uint32_t *status_reg, + uint32_t *reg) +{ + mdelay(50); +} + +static const struct ehci_ops mx5_ehci_ops = { + .powerup_fixup = mx5_ehci_powerup_fixup, +}; + int ehci_hcd_init(int index, enum usb_init_type init, struct ehci_hccr **hccr, struct ehci_hcor **hcor) { struct usb_ehci *ehci; + /* The only user for this is efikamx-usb */ + ehci_set_controller_priv(index, NULL, &mx5_ehci_ops); set_usboh3_clk(); enable_usboh3_clk(true); set_usb_phy_clk(); |