diff options
author | Kishon Vijay Abraham I <kishon@ti.com> | 2012-06-22 07:32:46 -0400 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-06-25 07:05:35 -0400 |
commit | 662dca54ca67c92b7aa14b9a2ec54acacf33ce45 (patch) | |
tree | 80c77434b1c4d33ce4e7db56f284c9ae65e16a8d /drivers/power | |
parent | 721002ec1dd55a52425455826af49cf8853b2d4f (diff) |
usb: otg: support for multiple transceivers by a single controller
Add a linked list for keeping multiple PHY instances with different
types so that we can have separate USB2 and USB3 PHYs on one single
board. _get_phy_ has been changed so that the controller gets
the transceiver by type. _remove_phy_ has been added to let the phy
be removed from the phy list.
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/power')
-rw-r--r-- | drivers/power/ab8500_charger.c | 2 | ||||
-rw-r--r-- | drivers/power/isp1704_charger.c | 2 | ||||
-rw-r--r-- | drivers/power/pda_power.c | 2 | ||||
-rw-r--r-- | drivers/power/twl4030_charger.c | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/drivers/power/ab8500_charger.c b/drivers/power/ab8500_charger.c index cf5ffc4d1048..6bd6f1c41967 100644 --- a/drivers/power/ab8500_charger.c +++ b/drivers/power/ab8500_charger.c | |||
@@ -2688,7 +2688,7 @@ static int __devinit ab8500_charger_probe(struct platform_device *pdev) | |||
2688 | goto free_ac; | 2688 | goto free_ac; |
2689 | } | 2689 | } |
2690 | 2690 | ||
2691 | di->usb_phy = usb_get_phy(); | 2691 | di->usb_phy = usb_get_phy(USB_PHY_TYPE_USB2); |
2692 | if (!di->usb_phy) { | 2692 | if (!di->usb_phy) { |
2693 | dev_err(di->dev, "failed to get usb transceiver\n"); | 2693 | dev_err(di->dev, "failed to get usb transceiver\n"); |
2694 | ret = -EINVAL; | 2694 | ret = -EINVAL; |
diff --git a/drivers/power/isp1704_charger.c b/drivers/power/isp1704_charger.c index 50773ae6f72e..090e5f9e72c9 100644 --- a/drivers/power/isp1704_charger.c +++ b/drivers/power/isp1704_charger.c | |||
@@ -415,7 +415,7 @@ static int __devinit isp1704_charger_probe(struct platform_device *pdev) | |||
415 | if (!isp) | 415 | if (!isp) |
416 | return -ENOMEM; | 416 | return -ENOMEM; |
417 | 417 | ||
418 | isp->phy = usb_get_phy(); | 418 | isp->phy = usb_get_phy(USB_PHY_TYPE_USB2); |
419 | if (!isp->phy) | 419 | if (!isp->phy) |
420 | goto fail0; | 420 | goto fail0; |
421 | 421 | ||
diff --git a/drivers/power/pda_power.c b/drivers/power/pda_power.c index e0f206b0775b..7602d49e4d81 100644 --- a/drivers/power/pda_power.c +++ b/drivers/power/pda_power.c | |||
@@ -321,7 +321,7 @@ static int pda_power_probe(struct platform_device *pdev) | |||
321 | } | 321 | } |
322 | 322 | ||
323 | #ifdef CONFIG_USB_OTG_UTILS | 323 | #ifdef CONFIG_USB_OTG_UTILS |
324 | transceiver = usb_get_phy(); | 324 | transceiver = usb_get_phy(USB_PHY_TYPE_USB2); |
325 | if (transceiver && !pdata->is_usb_online) { | 325 | if (transceiver && !pdata->is_usb_online) { |
326 | pdata->is_usb_online = otg_is_usb_online; | 326 | pdata->is_usb_online = otg_is_usb_online; |
327 | } | 327 | } |
diff --git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c index fcddd115cc08..13f9db2e8538 100644 --- a/drivers/power/twl4030_charger.c +++ b/drivers/power/twl4030_charger.c | |||
@@ -479,7 +479,7 @@ static int __init twl4030_bci_probe(struct platform_device *pdev) | |||
479 | 479 | ||
480 | INIT_WORK(&bci->work, twl4030_bci_usb_work); | 480 | INIT_WORK(&bci->work, twl4030_bci_usb_work); |
481 | 481 | ||
482 | bci->transceiver = usb_get_phy(); | 482 | bci->transceiver = usb_get_phy(USB_PHY_TYPE_USB2); |
483 | if (bci->transceiver != NULL) { | 483 | if (bci->transceiver != NULL) { |
484 | bci->usb_nb.notifier_call = twl4030_bci_usb_ncb; | 484 | bci->usb_nb.notifier_call = twl4030_bci_usb_ncb; |
485 | usb_register_notifier(bci->transceiver, &bci->usb_nb); | 485 | usb_register_notifier(bci->transceiver, &bci->usb_nb); |