diff options
author | Adam Lussier <adam.lussier@timesys.com> | 2013-02-25 17:19:04 -0500 |
---|---|---|
committer | Adam Lussier <adam.lussier@timesys.com> | 2013-02-25 17:19:04 -0500 |
commit | f962cbcefdfad22ffff41e19ad4c5ff58815c05c (patch) | |
tree | e9424582f1fdc92d360ff58c831ddf801a268e3f /drivers/usb/gadget/arcotg_udc.c | |
parent | 15f55e0b22f8953b56fb5d6bdf8b770228f2f449 (diff) | |
parent | 16af5ee7d9556c47b332788e4107cbed5ee7ec10 (diff) |
Merge remote-tracking branch 'github/3.0-pcm052' into 3.0-pcm0523.0-pcm052-ts2
Release 3.0-ts2: enable USB support for the phyCORE Vybrid
Diffstat (limited to 'drivers/usb/gadget/arcotg_udc.c')
-rwxr-xr-x | drivers/usb/gadget/arcotg_udc.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/drivers/usb/gadget/arcotg_udc.c b/drivers/usb/gadget/arcotg_udc.c index 5a1aab94b405..c7c99cd9f3cb 100755 --- a/drivers/usb/gadget/arcotg_udc.c +++ b/drivers/usb/gadget/arcotg_udc.c @@ -3356,9 +3356,15 @@ static int fsl_udc_suspend(struct platform_device *pdev, pm_message_t state) (udc_controller->usb_state > USB_STATE_POWERED) && (udc_controller->usb_state < USB_STATE_SUSPENDED)) { return -EBUSY;/* keep the clk on */ - } else + } else { + if (udc_controller->pdata->wake_up_enable) + udc_controller->pdata->wake_up_enable( + udc_controller->pdata, true); ret = udc_suspend(udc_controller); - dr_clk_gate(false); + } + + if (udc_controller->stopped) + dr_clk_gate(false); printk(KERN_DEBUG "USB Gadget suspend ends\n"); return ret; @@ -3408,6 +3414,8 @@ static int fsl_udc_resume(struct platform_device *pdev) /* prevent the quirk interrupts from resuming */ disable_irq_nosync(udc_controller->irq); + if (pdata->wake_up_enable) + pdata->wake_up_enable(pdata, false); /* * If the controller was stopped at suspend time, then * don't resume it now. |