usb: dwc2: Update GINTSTS_GOUTNAKEFF interrupt handling
Disabled only unmasked endpoints based on DAINTMSK register. This will allow to minimize GINTSTS_GOUTNAKEFF interrupt handling. Acked-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Razmik Karapetyan <razmik@synopsys.com> Signed-off-by: Minas Harutyunyan <hminas@synopsys.com> Signed-off-by: Grigor Tovmasyan <tovmasya@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
This commit is contained in:
Родитель
689efb2619
Коммит
d84845522d
|
@ -3628,8 +3628,11 @@ irq_retry:
|
||||||
u8 idx;
|
u8 idx;
|
||||||
u32 epctrl;
|
u32 epctrl;
|
||||||
u32 gintmsk;
|
u32 gintmsk;
|
||||||
|
u32 daintmsk;
|
||||||
struct dwc2_hsotg_ep *hs_ep;
|
struct dwc2_hsotg_ep *hs_ep;
|
||||||
|
|
||||||
|
daintmsk = dwc2_readl(hsotg->regs + DAINTMSK);
|
||||||
|
daintmsk >>= DAINT_OUTEP_SHIFT;
|
||||||
/* Mask this interrupt */
|
/* Mask this interrupt */
|
||||||
gintmsk = dwc2_readl(hsotg->regs + GINTMSK);
|
gintmsk = dwc2_readl(hsotg->regs + GINTMSK);
|
||||||
gintmsk &= ~GINTSTS_GOUTNAKEFF;
|
gintmsk &= ~GINTSTS_GOUTNAKEFF;
|
||||||
|
@ -3638,9 +3641,13 @@ irq_retry:
|
||||||
dev_dbg(hsotg->dev, "GOUTNakEff triggered\n");
|
dev_dbg(hsotg->dev, "GOUTNakEff triggered\n");
|
||||||
for (idx = 1; idx <= hsotg->num_of_eps; idx++) {
|
for (idx = 1; idx <= hsotg->num_of_eps; idx++) {
|
||||||
hs_ep = hsotg->eps_out[idx];
|
hs_ep = hsotg->eps_out[idx];
|
||||||
|
/* Proceed only unmasked ISOC EPs */
|
||||||
|
if (!hs_ep->isochronous || (BIT(idx) & ~daintmsk))
|
||||||
|
continue;
|
||||||
|
|
||||||
epctrl = dwc2_readl(hsotg->regs + DOEPCTL(idx));
|
epctrl = dwc2_readl(hsotg->regs + DOEPCTL(idx));
|
||||||
|
|
||||||
if ((epctrl & DXEPCTL_EPENA) && hs_ep->isochronous) {
|
if (epctrl & DXEPCTL_EPENA) {
|
||||||
epctrl |= DXEPCTL_SNAK;
|
epctrl |= DXEPCTL_SNAK;
|
||||||
epctrl |= DXEPCTL_EPDIS;
|
epctrl |= DXEPCTL_EPDIS;
|
||||||
dwc2_writel(epctrl, hsotg->regs + DOEPCTL(idx));
|
dwc2_writel(epctrl, hsotg->regs + DOEPCTL(idx));
|
||||||
|
|
Загрузка…
Ссылка в новой задаче