diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-01 20:06:09 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-01 20:06:09 -0400 |
commit | 3e75c6de1ac33fe3500f44573d9212dc82c99f59 (patch) | |
tree | ef10932e204ba8a9885051b06d4524d284207d61 /drivers/usb/dwc2/core_intr.c | |
parent | cb1595563880a81dab6eab9a5ecb4520d2e76077 (diff) | |
parent | 940ab8f1ef9369da5b58a1bec6820bfd4a7b9042 (diff) |
Merge tag 'usb-3.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Pull USB patches from Greg KH:
"Here's the big USB pull request for 3.15-rc1.
The normal set of patches, lots of controller driver updates, and a
smattering of individual USB driver updates as well.
All have been in linux-next for a while"
* tag 'usb-3.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (249 commits)
xhci: Transition maintainership to Mathias Nyman.
USB: disable reset-resume when USB_QUIRK_RESET is set
USB: unbind all interfaces before rebinding any
usb: phy: Add ulpi IDs for SMSC USB3320 and TI TUSB1210
usb: gadget: tcm_usb_gadget: stop format strings
usb: gadget: f_fs: add missing spinlock and mutex unlock
usb: gadget: composite: switch over to ERR_CAST()
usb: gadget: inode: switch over to memdup_user()
usb: gadget: f_subset: switch over to PTR_RET
usb: gadget: lpc32xx_udc: fix wrong clk_put() sequence
USB: keyspan: remove dead debugging code
USB: serial: add missing newlines to dev_<level> messages.
USB: serial: add missing braces
USB: serial: continue to write on errors
USB: serial: continue to read on errors
USB: serial: make bulk_out_size a lower limit
USB: cypress_m8: fix potential scheduling while atomic
devicetree: bindings: document lsi,zevio-usb
usb: chipidea: add support for USB OTG controller on LSI Zevio SoCs
usb: chipidea: imx: Use dev_name() for ci_hdrc name to distinguish USBs
...
Diffstat (limited to 'drivers/usb/dwc2/core_intr.c')
-rw-r--r-- | drivers/usb/dwc2/core_intr.c | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/drivers/usb/dwc2/core_intr.c b/drivers/usb/dwc2/core_intr.c index 8205799e6db3..c93918b70d03 100644 --- a/drivers/usb/dwc2/core_intr.c +++ b/drivers/usb/dwc2/core_intr.c | |||
@@ -72,6 +72,26 @@ static const char *dwc2_op_state_str(struct dwc2_hsotg *hsotg) | |||
72 | } | 72 | } |
73 | 73 | ||
74 | /** | 74 | /** |
75 | * dwc2_handle_usb_port_intr - handles OTG PRTINT interrupts. | ||
76 | * When the PRTINT interrupt fires, there are certain status bits in the Host | ||
77 | * Port that needs to get cleared. | ||
78 | * | ||
79 | * @hsotg: Programming view of DWC_otg controller | ||
80 | */ | ||
81 | static void dwc2_handle_usb_port_intr(struct dwc2_hsotg *hsotg) | ||
82 | { | ||
83 | u32 hprt0 = readl(hsotg->regs + HPRT0); | ||
84 | |||
85 | if (hprt0 & HPRT0_ENACHG) { | ||
86 | hprt0 &= ~HPRT0_ENA; | ||
87 | writel(hprt0, hsotg->regs + HPRT0); | ||
88 | } | ||
89 | |||
90 | /* Clear interrupt */ | ||
91 | writel(GINTSTS_PRTINT, hsotg->regs + GINTSTS); | ||
92 | } | ||
93 | |||
94 | /** | ||
75 | * dwc2_handle_mode_mismatch_intr() - Logs a mode mismatch warning message | 95 | * dwc2_handle_mode_mismatch_intr() - Logs a mode mismatch warning message |
76 | * | 96 | * |
77 | * @hsotg: Programming view of DWC_otg controller | 97 | * @hsotg: Programming view of DWC_otg controller |
@@ -479,9 +499,8 @@ irqreturn_t dwc2_handle_common_intr(int irq, void *dev) | |||
479 | if (dwc2_is_device_mode(hsotg)) { | 499 | if (dwc2_is_device_mode(hsotg)) { |
480 | dev_dbg(hsotg->dev, | 500 | dev_dbg(hsotg->dev, |
481 | " --Port interrupt received in Device mode--\n"); | 501 | " --Port interrupt received in Device mode--\n"); |
482 | gintsts = GINTSTS_PRTINT; | 502 | dwc2_handle_usb_port_intr(hsotg); |
483 | writel(gintsts, hsotg->regs + GINTSTS); | 503 | retval = IRQ_HANDLED; |
484 | retval = 1; | ||
485 | } | 504 | } |
486 | } | 505 | } |
487 | 506 | ||