diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-20 14:26:30 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-20 14:26:30 -0400 |
commit | ed378a52dabf77b406b447fd3238f83ea24b71fa (patch) | |
tree | 07e1a7ec2d1c08767ee81b9910f5912b80502632 /drivers/usb/musb/da8xx.c | |
parent | 843ec558f91b8e8fdb6efc908f2c0506407cc750 (diff) | |
parent | 11207b6fe05438b2e87a26435cd98db3d55e6fa7 (diff) |
Merge tag 'usb-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Pull USB merge for 3.4-rc1 from Greg KH:
"Here's the big USB merge for the 3.4-rc1 merge window.
Lots of gadget driver reworks here, driver updates, xhci changes, some
new drivers added, usb-serial core reworking to fix some bugs, and
other various minor things.
There are some patches touching arch code, but they have all been
acked by the various arch maintainers."
* tag 'usb-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (302 commits)
net: qmi_wwan: add support for ZTE MF820D
USB: option: add ZTE MF820D
usb: gadget: f_fs: Remove lock is held before freeing checks
USB: option: make interface blacklist work again
usb/ub: deprecate & schedule for removal the "Low Performance USB Block" driver
USB: ohci-pxa27x: add clk_prepare/clk_unprepare calls
USB: use generic platform driver on ath79
USB: EHCI: Add a generic platform device driver
USB: OHCI: Add a generic platform device driver
USB: ftdi_sio: new PID: LUMEL PD12
USB: ftdi_sio: add support for FT-X series devices
USB: serial: mos7840: Fixed MCS7820 device attach problem
usb: Don't make USB_ARCH_HAS_{XHCI,OHCI,EHCI} depend on USB_SUPPORT.
usb gadget: fix a section mismatch when compiling g_ffs with CONFIG_USB_FUNCTIONFS_ETH
USB: ohci-nxp: Remove i2c_write(), use smbus
USB: ohci-nxp: Support for LPC32xx
USB: ohci-nxp: Rename symbols from pnx4008 to nxp
USB: OHCI-HCD: Rename ohci-pnx4008 to ohci-nxp
usb: gadget: Kconfig: fix typo for 'different'
usb: dwc3: pci: fix another failure path in dwc3_pci_probe()
...
Diffstat (limited to 'drivers/usb/musb/da8xx.c')
-rw-r--r-- | drivers/usb/musb/da8xx.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/drivers/usb/musb/da8xx.c b/drivers/usb/musb/da8xx.c index 2613bfdb09b6..8bd9566f3fbb 100644 --- a/drivers/usb/musb/da8xx.c +++ b/drivers/usb/musb/da8xx.c | |||
@@ -294,6 +294,7 @@ static irqreturn_t da8xx_musb_interrupt(int irq, void *hci) | |||
294 | { | 294 | { |
295 | struct musb *musb = hci; | 295 | struct musb *musb = hci; |
296 | void __iomem *reg_base = musb->ctrl_base; | 296 | void __iomem *reg_base = musb->ctrl_base; |
297 | struct usb_otg *otg = musb->xceiv->otg; | ||
297 | unsigned long flags; | 298 | unsigned long flags; |
298 | irqreturn_t ret = IRQ_NONE; | 299 | irqreturn_t ret = IRQ_NONE; |
299 | u32 status; | 300 | u32 status; |
@@ -351,14 +352,14 @@ static irqreturn_t da8xx_musb_interrupt(int irq, void *hci) | |||
351 | WARNING("VBUS error workaround (delay coming)\n"); | 352 | WARNING("VBUS error workaround (delay coming)\n"); |
352 | } else if (is_host_enabled(musb) && drvvbus) { | 353 | } else if (is_host_enabled(musb) && drvvbus) { |
353 | MUSB_HST_MODE(musb); | 354 | MUSB_HST_MODE(musb); |
354 | musb->xceiv->default_a = 1; | 355 | otg->default_a = 1; |
355 | musb->xceiv->state = OTG_STATE_A_WAIT_VRISE; | 356 | musb->xceiv->state = OTG_STATE_A_WAIT_VRISE; |
356 | portstate(musb->port1_status |= USB_PORT_STAT_POWER); | 357 | portstate(musb->port1_status |= USB_PORT_STAT_POWER); |
357 | del_timer(&otg_workaround); | 358 | del_timer(&otg_workaround); |
358 | } else { | 359 | } else { |
359 | musb->is_active = 0; | 360 | musb->is_active = 0; |
360 | MUSB_DEV_MODE(musb); | 361 | MUSB_DEV_MODE(musb); |
361 | musb->xceiv->default_a = 0; | 362 | otg->default_a = 0; |
362 | musb->xceiv->state = OTG_STATE_B_IDLE; | 363 | musb->xceiv->state = OTG_STATE_B_IDLE; |
363 | portstate(musb->port1_status &= ~USB_PORT_STAT_POWER); | 364 | portstate(musb->port1_status &= ~USB_PORT_STAT_POWER); |
364 | } | 365 | } |
@@ -424,7 +425,7 @@ static int da8xx_musb_init(struct musb *musb) | |||
424 | goto fail; | 425 | goto fail; |
425 | 426 | ||
426 | usb_nop_xceiv_register(); | 427 | usb_nop_xceiv_register(); |
427 | musb->xceiv = otg_get_transceiver(); | 428 | musb->xceiv = usb_get_transceiver(); |
428 | if (!musb->xceiv) | 429 | if (!musb->xceiv) |
429 | goto fail; | 430 | goto fail; |
430 | 431 | ||
@@ -457,7 +458,7 @@ static int da8xx_musb_exit(struct musb *musb) | |||
457 | 458 | ||
458 | phy_off(); | 459 | phy_off(); |
459 | 460 | ||
460 | otg_put_transceiver(musb->xceiv); | 461 | usb_put_transceiver(musb->xceiv); |
461 | usb_nop_xceiv_unregister(); | 462 | usb_nop_xceiv_unregister(); |
462 | 463 | ||
463 | return 0; | 464 | return 0; |
@@ -478,7 +479,7 @@ static const struct musb_platform_ops da8xx_ops = { | |||
478 | 479 | ||
479 | static u64 da8xx_dmamask = DMA_BIT_MASK(32); | 480 | static u64 da8xx_dmamask = DMA_BIT_MASK(32); |
480 | 481 | ||
481 | static int __init da8xx_probe(struct platform_device *pdev) | 482 | static int __devinit da8xx_probe(struct platform_device *pdev) |
482 | { | 483 | { |
483 | struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data; | 484 | struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data; |
484 | struct platform_device *musb; | 485 | struct platform_device *musb; |
@@ -562,7 +563,7 @@ err0: | |||
562 | return ret; | 563 | return ret; |
563 | } | 564 | } |
564 | 565 | ||
565 | static int __exit da8xx_remove(struct platform_device *pdev) | 566 | static int __devexit da8xx_remove(struct platform_device *pdev) |
566 | { | 567 | { |
567 | struct da8xx_glue *glue = platform_get_drvdata(pdev); | 568 | struct da8xx_glue *glue = platform_get_drvdata(pdev); |
568 | 569 | ||
@@ -576,7 +577,8 @@ static int __exit da8xx_remove(struct platform_device *pdev) | |||
576 | } | 577 | } |
577 | 578 | ||
578 | static struct platform_driver da8xx_driver = { | 579 | static struct platform_driver da8xx_driver = { |
579 | .remove = __exit_p(da8xx_remove), | 580 | .probe = da8xx_probe, |
581 | .remove = __devexit_p(da8xx_remove), | ||
580 | .driver = { | 582 | .driver = { |
581 | .name = "musb-da8xx", | 583 | .name = "musb-da8xx", |
582 | }, | 584 | }, |
@@ -588,9 +590,9 @@ MODULE_LICENSE("GPL v2"); | |||
588 | 590 | ||
589 | static int __init da8xx_init(void) | 591 | static int __init da8xx_init(void) |
590 | { | 592 | { |
591 | return platform_driver_probe(&da8xx_driver, da8xx_probe); | 593 | return platform_driver_register(&da8xx_driver); |
592 | } | 594 | } |
593 | subsys_initcall(da8xx_init); | 595 | module_init(da8xx_init); |
594 | 596 | ||
595 | static void __exit da8xx_exit(void) | 597 | static void __exit da8xx_exit(void) |
596 | { | 598 | { |