From: Gregory Herrero Date: Tue, 22 Sep 2015 13:16:43 +0000 (+0200) Subject: usb: dwc2: host: ignore wakeup interrupt if hibernation supported X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=6e74162f69c7fb6f60941ea7e94f1264bd6225fb;p=deliverable%2Flinux.git usb: dwc2: host: ignore wakeup interrupt if hibernation supported If hibernation is supported, resume of devices will be handled in bus_resume callback. Signed-off-by: Gregory Herrero Signed-off-by: Mian Yousaf Kaukab Tested-by: Robert Baldyga Tested-by: Dinh Nguyen Tested-by: John Youn Acked-by: John Youn Signed-off-by: Felipe Balbi --- diff --git a/drivers/usb/dwc2/core_intr.c b/drivers/usb/dwc2/core_intr.c index 3275310a8fb3..d8a5400a2d2d 100644 --- a/drivers/usb/dwc2/core_intr.c +++ b/drivers/usb/dwc2/core_intr.c @@ -356,6 +356,10 @@ static void dwc2_handle_wakeup_detected_intr(struct dwc2_hsotg *hsotg) /* Change to L0 state */ hsotg->lx_state = DWC2_L0; } else { + if (hsotg->core_params->hibernation) { + dwc2_writel(GINTSTS_WKUPINT, hsotg->regs + GINTSTS); + return; + } if (hsotg->lx_state != DWC2_L1) { u32 pcgcctl = dwc2_readl(hsotg->regs + PCGCTL);