diff options
author | Heikki Krogerus <heikki.krogerus@linux.intel.com> | 2012-02-13 13:24:16 +0200 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-02-13 13:53:21 +0200 |
commit | fcc8ebc99034bae4020a3cec030553d469e265db (patch) | |
tree | 5ddad4eb1503d2005dfd1953e4b8fe8f97f6c8b8 /drivers/power/twl4030_charger.c | |
parent | d445b6da8da491e025eb60576ce959f6a3a56a4f (diff) | |
download | linux-fcc8ebc99034bae4020a3cec030553d469e265db.tar.gz linux-fcc8ebc99034bae4020a3cec030553d469e265db.tar.bz2 linux-fcc8ebc99034bae4020a3cec030553d469e265db.zip |
power_supply: Convert all users to new usb_phy
Use the new usb_phy_* functions instead of the old
otg_* ones.
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Acked-by: Anton Vorontsov <cbouatmailru@gmail.com>
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/power/twl4030_charger.c')
-rw-r--r-- | drivers/power/twl4030_charger.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c index b3ead2305b4c..fdad850c77d3 100644 --- a/drivers/power/twl4030_charger.c +++ b/drivers/power/twl4030_charger.c @@ -70,7 +70,7 @@ struct twl4030_bci { struct power_supply ac; struct power_supply usb; struct usb_phy *transceiver; - struct notifier_block otg_nb; + struct notifier_block usb_nb; struct work_struct work; int irq_chg; int irq_bci; @@ -279,7 +279,7 @@ static void twl4030_bci_usb_work(struct work_struct *data) static int twl4030_bci_usb_ncb(struct notifier_block *nb, unsigned long val, void *priv) { - struct twl4030_bci *bci = container_of(nb, struct twl4030_bci, otg_nb); + struct twl4030_bci *bci = container_of(nb, struct twl4030_bci, usb_nb); dev_dbg(bci->dev, "OTG notify %lu\n", val); @@ -479,10 +479,10 @@ static int __init twl4030_bci_probe(struct platform_device *pdev) INIT_WORK(&bci->work, twl4030_bci_usb_work); - bci->transceiver = otg_get_transceiver(); + bci->transceiver = usb_get_transceiver(); if (bci->transceiver != NULL) { - bci->otg_nb.notifier_call = twl4030_bci_usb_ncb; - otg_register_notifier(bci->transceiver, &bci->otg_nb); + bci->usb_nb.notifier_call = twl4030_bci_usb_ncb; + usb_register_notifier(bci->transceiver, &bci->usb_nb); } /* Enable interrupts now. */ @@ -508,8 +508,8 @@ static int __init twl4030_bci_probe(struct platform_device *pdev) fail_unmask_interrupts: if (bci->transceiver != NULL) { - otg_unregister_notifier(bci->transceiver, &bci->otg_nb); - otg_put_transceiver(bci->transceiver); + usb_unregister_notifier(bci->transceiver, &bci->usb_nb); + usb_put_transceiver(bci->transceiver); } free_irq(bci->irq_bci, bci); fail_bci_irq: @@ -539,8 +539,8 @@ static int __exit twl4030_bci_remove(struct platform_device *pdev) TWL4030_INTERRUPTS_BCIIMR2A); if (bci->transceiver != NULL) { - otg_unregister_notifier(bci->transceiver, &bci->otg_nb); - otg_put_transceiver(bci->transceiver); + usb_unregister_notifier(bci->transceiver, &bci->usb_nb); + usb_put_transceiver(bci->transceiver); } free_irq(bci->irq_bci, bci); free_irq(bci->irq_chg, bci); |