33 #define MSM_USB_BASE (hcd->regs)
37 static int ehci_msm_reset(
struct usb_hcd *hcd)
39 struct ehci_hcd *ehci = hcd_to_ehci(hcd);
45 retval = ehci_setup(hcd);
56 ehci_port_power(ehci, 1);
60 static struct hc_driver msm_hc_driver = {
61 .description = hcd_name,
62 .product_desc =
"Qualcomm On-Chip EHCI Host Controller",
63 .hcd_priv_size =
sizeof(
struct ehci_hcd),
69 .flags = HCD_USB2 | HCD_MEMORY,
71 .reset = ehci_msm_reset,
75 .shutdown = ehci_shutdown,
80 .urb_enqueue = ehci_urb_enqueue,
81 .urb_dequeue = ehci_urb_dequeue,
82 .endpoint_disable = ehci_endpoint_disable,
83 .endpoint_reset = ehci_endpoint_reset,
84 .clear_tt_buffer_complete = ehci_clear_tt_buffer_complete,
89 .get_frame_number = ehci_get_frame,
94 .hub_status_data = ehci_hub_status_data,
95 .hub_control = ehci_hub_control,
96 .relinquish_port = ehci_relinquish_port,
97 .port_handed_over = ehci_port_handed_over,
116 dev_err(&pdev->
dev,
"Unable to create HCD\n");
122 dev_err(&pdev->
dev,
"Unable to get IRQ resource\n");
129 dev_err(&pdev->
dev,
"Unable to get memory resource\n");
134 hcd->rsrc_start = res->
start;
135 hcd->rsrc_len = resource_size(res);
149 if (IS_ERR_OR_NULL(phy)) {
150 dev_err(&pdev->
dev,
"unable to find transceiver\n");
155 ret = otg_set_host(phy->
otg, &hcd->self);
157 dev_err(&pdev->
dev,
"unable to register with transceiver\n");
179 struct usb_hcd *hcd = platform_get_drvdata(pdev);
182 pm_runtime_disable(&pdev->
dev);
183 pm_runtime_set_suspended(&pdev->
dev);
196 bool do_wakeup = device_may_wakeup(dev);
198 dev_dbg(dev,
"ehci-msm PM suspend\n");
200 return ehci_suspend(hcd, do_wakeup);
207 dev_dbg(dev,
"ehci-msm PM resume\n");
208 ehci_resume(hcd,
false);
213 #define ehci_msm_pm_suspend NULL
214 #define ehci_msm_pm_resume NULL
217 static const struct dev_pm_ops ehci_msm_dev_pm_ops = {
223 .probe = ehci_msm_probe,
226 .name =
"msm_hsusb_host",
227 .pm = &ehci_msm_dev_pm_ops,