Revert "usb: dwc3: rockchip: fix otg plug out error before resume"
authorMeng Dongyang <daniel.meng@rock-chips.com>
Fri, 14 Oct 2016 07:57:42 +0000 (15:57 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Fri, 14 Oct 2016 09:09:05 +0000 (17:09 +0800)
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 <daniel.meng@rock-chips.com>
drivers/usb/dwc3/dwc3-rockchip.c

index 74ba61e00795c75dbd8294c82ec3387278872431..d4a4335d22742c00bb8e498f4a682704f39e95e5 100644 (file)
@@ -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);