diff options
author | Dinh Nguyen <dinguyen@opensource.altera.com> | 2014-11-11 11:13:37 -0600 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2014-11-14 14:59:48 -0600 |
commit | db8178c33dbe9aba5e2c5d323625f9e6da55d7e6 (patch) | |
tree | b946656ed7c79139b44289ddc876f62d6f47d254 /drivers/usb/dwc2/platform.c | |
parent | 510ffaa48eac2587a4df9ec7668e3274e5f96ee3 (diff) | |
download | blackbird-op-linux-db8178c33dbe9aba5e2c5d323625f9e6da55d7e6.tar.gz blackbird-op-linux-db8178c33dbe9aba5e2c5d323625f9e6da55d7e6.zip |
usb: dwc2: Update common interrupt handler to call gadget interrupt handler
Make dwc2_handle_common_intr call the gadget interrupt function when operating
in peripheral mode. Remove the spinlock functions in s3c_hsotg_irq as
dwc2_handle_common_intr() already has the spinlocks.
Move the registeration of the IRQ to common code for platform and PCI.
Remove duplicate interrupt conditions that was in gadget, as those are handled
by dwc2 common interrupt handler.
Acked-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/dwc2/platform.c')
-rw-r--r-- | drivers/usb/dwc2/platform.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/usb/dwc2/platform.c b/drivers/usb/dwc2/platform.c index b94867ba9ccf..3552602ddbf6 100644 --- a/drivers/usb/dwc2/platform.c +++ b/drivers/usb/dwc2/platform.c @@ -196,6 +196,14 @@ static int dwc2_driver_probe(struct platform_device *dev) return irq; } + dev_dbg(hsotg->dev, "registering common handler for irq%d\n", + irq); + retval = devm_request_irq(hsotg->dev, irq, + dwc2_handle_common_intr, IRQF_SHARED, + dev_name(hsotg->dev), hsotg); + if (retval) + return retval; + res = platform_get_resource(dev, IORESOURCE_MEM, 0); hsotg->regs = devm_ioremap_resource(&dev->dev, res); if (IS_ERR(hsotg->regs)) |