From: Meng Dongyang Date: Fri, 14 Oct 2016 07:57:42 +0000 (+0800) Subject: Revert "usb: dwc3: rockchip: fix otg plug out error before resume" X-Git-Tag: firefly_0821_release~1399 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=84343348feb44761a0f81d86984c0530e5fef04e;p=firefly-linux-kernel-4.4.55.git Revert "usb: dwc3: rockchip: fix otg plug out error before resume" This reverts commit ccc954ee9f8859569fe16cc17b598fbfece07ae8. In current code, the dwc3 controller will not process notify when it is in suspend state and this forbid extcon remove hcd before xhci resume, so we do not need to forbid remove hcd by the hcd runtime flag and it is difficult to deal with different process when connected with some special usb storage. Change-Id: I987862cceb4ffbe8deefb503f6bc4009770e87bd Signed-off-by: Meng Dongyang --- diff --git a/drivers/usb/dwc3/dwc3-rockchip.c b/drivers/usb/dwc3/dwc3-rockchip.c index 74ba61e00795..d4a4335d2274 100644 --- a/drivers/usb/dwc3/dwc3-rockchip.c +++ b/drivers/usb/dwc3/dwc3-rockchip.c @@ -212,11 +212,6 @@ static void dwc3_rockchip_otg_extcon_evt_work(struct work_struct *work) DWC3_GCTL_PRTCAP(reg) == DWC3_GCTL_PRTCAP_OTG) { hcd = dev_get_drvdata(&dwc->xhci->dev); - if (hcd->state == HC_STATE_SUSPENDED) { - dev_dbg(rockchip->dev, "USB suspended\n"); - goto out; - } - if (hcd->state != HC_STATE_HALT) { usb_remove_hcd(hcd->shared_hcd); usb_remove_hcd(hcd);