summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRamon Fried <ramon.fried@gmail.com>2018-09-21 13:35:51 +0300
committerTom Rini <trini@konsulko.com>2018-09-30 13:00:36 -0400
commit0683b27ae30fb00a6c613aec40a78935545c600b (patch)
treeb448dfa6f97a36523027b7f00267e396e13923f5
parent0ac0b6eb6a9d80945454c810cd7eef26958b217b (diff)
ehci: msm: use init_type in probe
Change ehci_usb_probe() function to initialize the USB according to the init_type provided. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
-rw-r--r--drivers/usb/host/ehci-msm.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/usb/host/ehci-msm.c b/drivers/usb/host/ehci-msm.c
index a27a5833dd..00d6bb8231 100644
--- a/drivers/usb/host/ehci-msm.c
+++ b/drivers/usb/host/ehci-msm.c
@@ -49,6 +49,7 @@ static int ehci_usb_probe(struct udevice *dev)
{
struct msm_ehci_priv *p = dev_get_priv(dev);
struct usb_ehci *ehci = p->ehci;
+ struct usb_platdata *plat = dev_get_platdata(dev);
struct ehci_hccr *hccr;
struct ehci_hcor *hcor;
int ret;
@@ -61,11 +62,12 @@ static int ehci_usb_probe(struct udevice *dev)
if (ret)
return ret;
- ret = board_usb_init(0, USB_INIT_HOST);
+ ret = board_usb_init(0, plat->init_type);
if (ret < 0)
return ret;
- return ehci_register(dev, hccr, hcor, &msm_ehci_ops, 0, USB_INIT_HOST);
+ return ehci_register(dev, hccr, hcor, &msm_ehci_ops, 0,
+ plat->init_type);
}
static int ehci_usb_remove(struct udevice *dev)