From a8195125043d2d753d558ee886c67045542dbbc0 Mon Sep 17 00:00:00 2001 From: yangkai Date: Thu, 9 Jun 2011 17:10:24 +0800 Subject: [PATCH] fix bug for usb pcd wakelocks --- drivers/usb/dwc_otg/dwc_otg_pcd.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/usb/dwc_otg/dwc_otg_pcd.c b/drivers/usb/dwc_otg/dwc_otg_pcd.c index ba6aba4d2f15..fe4d55ce0909 100755 --- a/drivers/usb/dwc_otg/dwc_otg_pcd.c +++ b/drivers/usb/dwc_otg/dwc_otg_pcd.c @@ -1123,6 +1123,7 @@ static int32_t dwc_otg_pcd_suspend_cb( void *_p ,int suspend) { dwc_otg_pcd_t *pcd = (dwc_otg_pcd_t *)_p; //#ifdef CONFIG_ANDROID_POWER +#if 0 /* yk@rk 20100520 * PC disconnect the USB, unlock the msc_lock and * system can enter level 2 sleep mode. @@ -1134,6 +1135,7 @@ static int32_t dwc_otg_pcd_suspend_cb( void *_p ,int suspend) if(cdev->config) pcd->conn_status = 3; } +#endif //#endif if (pcd->driver && pcd->driver->resume) { @@ -1892,7 +1894,8 @@ int dwc_otg_pcd_init(struct device *dev) pcd->vbus_status = 0; pcd->phy_suspend = 0; if(dwc_otg_is_device_mode(core_if)) - dwc_otg_pcd_start_vbus_timer( pcd ); + mod_timer(&pcd->check_vbus_timer, jiffies+(HZ<<4)); // delay 16 S +// dwc_otg_pcd_start_vbus_timer( pcd ); return 0; } /** -- 2.34.1