usb host controller support remote wakeup
authoryangkai <yangkai@ubuntu-fs>
Tue, 5 Jul 2011 02:10:50 +0000 (10:10 +0800)
committeryangkai <yangkai@ubuntu-fs>
Tue, 5 Jul 2011 02:10:50 +0000 (10:10 +0800)
drivers/usb/dwc_otg/Kconfig
drivers/usb/dwc_otg/dwc_otg_hcd.c

index a95b9a3e368da56cbeb12ee440061e481b73e104..87d2a37e401804eb0bfca627890d735a6299d142 100755 (executable)
@@ -89,6 +89,9 @@ config DWC_OTG_DEBUG
        bool "DWC_OTG debug messages"
        depends on USB11_HOST || USB20_HOST || USB20_OTG
 
+config DWC_REMOTE_WAKEUP
+       bool "remote wakeup support in DWC_OTG controller"
+       depends on USB11_HOST || USB20_HOST || USB20_OTG
 config DWC_OTG
        tristate        
        default y if USB11_HOST || USB20_HOST || USB20_OTG
index ba742e4bbedfdb8457f4e17a094ace68064e66c4..8ae2f504de2d030b680ce3222b709b5eedaf929f 100755 (executable)
@@ -105,8 +105,10 @@ static int dwc_otg_hcd_suspend(struct usb_hcd *hcd)
         }
     }
     udelay(3);
+    #ifndef CONFIG_DWC_REMOTE_WAKEUP
     clk_disable(core_if->otg_dev->phyclk);
     clk_disable(core_if->otg_dev->ahbclk);
+    #endif
     //power off
     return 0;
 }
@@ -124,9 +126,10 @@ static int dwc_otg_hcd_resume(struct usb_hcd *hcd)
        DWC_PRINT("%s, usb device mode\n", __func__);
        return 0;
     }
+    #ifndef CONFIG_DWC_REMOTE_WAKEUP
     clk_enable(core_if->otg_dev->phyclk);
     clk_enable(core_if->otg_dev->ahbclk);
-    
+    #endif
     //partial power-down
     //power on
     pcgcctl.d32 = dwc_read_reg32(core_if->pcgcctl);;