usb: dwc2: Add partial power down exit flow in wakeup intr.
According to programming guide added host partial power down exit flow in wakeup detected interrupt handler. Acked-by: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com> Signed-off-by: Artur Petrosyan <Arthur.Petrosyan@synopsys.com> Link: https://lore.kernel.org/r/20210408094454.5BBCBA0094@mailhost.synopsys.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
c9c394abfa
commit
b77b0d0021
@ -423,15 +423,14 @@ static void dwc2_handle_wakeup_detected_intr(struct dwc2_hsotg *hsotg)
|
||||
hsotg->lx_state = DWC2_L0;
|
||||
}
|
||||
} else {
|
||||
if (hsotg->params.power_down)
|
||||
return;
|
||||
|
||||
if (hsotg->lx_state != DWC2_L1) {
|
||||
u32 pcgcctl = dwc2_readl(hsotg, PCGCTL);
|
||||
|
||||
/* Restart the Phy Clock */
|
||||
pcgcctl &= ~PCGCTL_STOPPCLK;
|
||||
dwc2_writel(hsotg, pcgcctl, PCGCTL);
|
||||
if (hsotg->lx_state == DWC2_L2) {
|
||||
if (hsotg->in_ppd) {
|
||||
ret = dwc2_exit_partial_power_down(hsotg, 1,
|
||||
true);
|
||||
if (ret)
|
||||
dev_err(hsotg->dev,
|
||||
"exit partial_power_down failed\n");
|
||||
}
|
||||
|
||||
/*
|
||||
* If we've got this quirk then the PHY is stuck upon
|
||||
|
Loading…
Reference in New Issue
Block a user