static int __exit ehci_msm_remove(struct platform_device *pdev) { struct usb_hcd *hcd = platform_get_drvdata(pdev); struct msmusb_hcd *mhcd = hcd_to_mhcd(hcd); struct msm_usb_host_platform_data *pdata; int retval = 0; pdata = pdev->dev.platform_data; device_init_wakeup(&pdev->dev, 0); #ifdef CONFIG_USB_HOST_NOTIFY host_notify_dev_unregister(&hcd->ndev); #endif msm_hsusb_request_host((void *)mhcd, REQUEST_STOP); msm_xusb_uninit_host(mhcd); retval = msm_xusb_rpc_close(mhcd); wake_lock_destroy(&mhcd->wlock); usb_put_hcd(hcd); clk_put(pdata->ebi1_clk); pm_runtime_disable(&pdev->dev); pm_runtime_set_suspended(&pdev->dev); return retval; }
static int __exit ehci_msm_remove(struct platform_device *pdev) { struct usb_hcd *hcd = platform_get_drvdata(pdev); struct msmusb_hcd *mhcd = hcd_to_mhcd(hcd); int retval = 0; device_init_wakeup(&pdev->dev, 0); msm_hsusb_request_host((void *)mhcd, REQUEST_STOP); msm_xusb_uninit_host(mhcd); usb_put_hcd(hcd); retval = msm_xusb_rpc_close(mhcd); wake_lock_destroy(&mhcd->wlock); pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ, (char *) dev_name(&pdev->dev)); return retval; }
static int __exit ehci_msm_remove(struct platform_device *pdev) { struct usb_hcd *hcd = platform_get_drvdata(pdev); struct msmusb_hcd *mhcd = hcd_to_mhcd(hcd); int retval = 0; device_init_wakeup(&pdev->dev, 0); msm_hsusb_request_host(mhcd, REQUEST_STOP); if (mhcd->xceiv && mhcd->xceiv->set_host) mhcd->xceiv->set_host(mhcd->xceiv, NULL); msm_otg_put_transceiver(mhcd->xceiv); iounmap(hcd->regs); usb_put_hcd(hcd); retval = msm_xusb_rpc_close(mhcd); clk_put(mhcd->clk); clk_put(mhcd->pclk); wake_lock_destroy(&mhcd->wlock); pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ, pdev->dev.bus_id); return retval; }