]> git.karo-electronics.de Git - linux-beck.git/commitdiff
usb: dwc2: host: add disconnect interrupt to host only interrupts
authorMian Yousaf Kaukab <yousaf.kaukab@intel.com>
Tue, 22 Sep 2015 13:16:47 +0000 (15:16 +0200)
committerFelipe Balbi <balbi@ti.com>
Thu, 1 Oct 2015 17:40:17 +0000 (12:40 -0500)
GINTSTS.DisconnInt is host only interrupt and should be disable after
dwc2_disable_host_interrupts is called.

Signed-off-by: Mian Yousaf Kaukab <yousaf.kaukab@intel.com>
Tested-by: Robert Baldyga <r.baldyga@samsung.com>
Tested-by: Dinh Nguyen <dinguyen@opensource.altera.com>
Tested-by: John Youn <johnyoun@synopsys.com>
Acked-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc2/core.c

index f5c3120f487997bca4c905429d9fed7ee3969027..c5e0a45c565d660cb57c362c6471ac095877c9bf 100644 (file)
@@ -857,7 +857,8 @@ void dwc2_enable_host_interrupts(struct dwc2_hsotg *hsotg)
 
        /* Enable host mode interrupts without disturbing common interrupts */
        intmsk = dwc2_readl(hsotg->regs + GINTMSK);
-       intmsk |= GINTSTS_DISCONNINT | GINTSTS_PRTINT | GINTSTS_HCHINT;
+       intmsk |= GINTSTS_DISCONNINT | GINTSTS_PRTINT | GINTSTS_HCHINT |
+                       GINTSTS_DISCONNINT;
        dwc2_writel(intmsk, hsotg->regs + GINTMSK);
 }
 
@@ -872,7 +873,7 @@ void dwc2_disable_host_interrupts(struct dwc2_hsotg *hsotg)
 
        /* Disable host mode interrupts without disturbing common interrupts */
        intmsk &= ~(GINTSTS_SOF | GINTSTS_PRTINT | GINTSTS_HCHINT |
-                   GINTSTS_PTXFEMP | GINTSTS_NPTXFEMP);
+                   GINTSTS_PTXFEMP | GINTSTS_NPTXFEMP | GINTSTS_DISCONNINT);
        dwc2_writel(intmsk, hsotg->regs + GINTMSK);
 }