Lines Matching refs:hcd
710 struct usb_hcd *hcd; in dwc2_hc_setup_align_buf() local
733 hcd = dwc2_hsotg_to_hcd(hsotg); in dwc2_hc_setup_align_buf()
734 usb_hcd_unmap_urb_for_dma(hcd, usb_urb); in dwc2_hc_setup_align_buf()
1441 struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg); in dwc2_host_is_b_hnp_enabled() local
1443 return hcd->self.b_hnp_enable; in dwc2_host_is_b_hnp_enabled()
2129 static struct dwc2_hsotg *dwc2_hcd_to_hsotg(struct usb_hcd *hcd) in dwc2_hcd_to_hsotg() argument
2133 p = (struct wrapper_priv_data *) &hcd->hcd_priv; in dwc2_hcd_to_hsotg()
2137 static int _dwc2_hcd_start(struct usb_hcd *hcd);
2141 struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg); in dwc2_host_start() local
2143 hcd->self.is_b_host = dwc2_hcd_is_b_host(hsotg); in dwc2_host_start()
2144 _dwc2_hcd_start(hcd); in dwc2_host_start()
2149 struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg); in dwc2_host_disconnect() local
2151 hcd->self.is_b_host = 0; in dwc2_host_disconnect()
2173 static void dwc2_allocate_bus_bandwidth(struct usb_hcd *hcd, u16 bw, in dwc2_allocate_bus_bandwidth() argument
2176 struct usb_bus *bus = hcd_to_bus(hcd); in dwc2_allocate_bus_bandwidth()
2186 static void dwc2_free_bus_bandwidth(struct usb_hcd *hcd, u16 bw, in dwc2_free_bus_bandwidth() argument
2189 struct usb_bus *bus = hcd_to_bus(hcd); in dwc2_free_bus_bandwidth()
2321 static int _dwc2_hcd_start(struct usb_hcd *hcd) in _dwc2_hcd_start() argument
2323 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_start()
2324 struct usb_bus *bus = hcd_to_bus(hcd); in _dwc2_hcd_start()
2331 hcd->state = HC_STATE_RUNNING; in _dwc2_hcd_start()
2332 set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); in _dwc2_hcd_start()
2345 usb_hcd_resume_root_hub(hcd); in _dwc2_hcd_start()
2356 static void _dwc2_hcd_stop(struct usb_hcd *hcd) in _dwc2_hcd_stop() argument
2358 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_stop()
2365 synchronize_irq(hcd->irq); in _dwc2_hcd_stop()
2372 hcd->state = HC_STATE_HALT; in _dwc2_hcd_stop()
2373 clear_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); in _dwc2_hcd_stop()
2379 static int _dwc2_hcd_suspend(struct usb_hcd *hcd) in _dwc2_hcd_suspend() argument
2381 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_suspend()
2391 if (!HCD_HW_ACCESSIBLE(hcd)) in _dwc2_hcd_suspend()
2425 clear_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); in _dwc2_hcd_suspend()
2435 static int _dwc2_hcd_resume(struct usb_hcd *hcd) in _dwc2_hcd_resume() argument
2437 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_resume()
2455 set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); in _dwc2_hcd_resume()
2504 static int _dwc2_hcd_get_frame_number(struct usb_hcd *hcd) in _dwc2_hcd_get_frame_number() argument
2506 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_get_frame_number()
2511 static void dwc2_dump_urb_info(struct usb_hcd *hcd, struct urb *urb, in dwc2_dump_urb_info() argument
2515 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in dwc2_dump_urb_info()
2592 static int _dwc2_hcd_urb_enqueue(struct usb_hcd *hcd, struct urb *urb, in _dwc2_hcd_urb_enqueue() argument
2595 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_urb_enqueue()
2611 dwc2_dump_urb_info(hcd, urb, "urb_enqueue"); in _dwc2_hcd_urb_enqueue()
2655 if (hcd->self.uses_dma) { in _dwc2_hcd_urb_enqueue()
2705 retval = usb_hcd_link_urb_to_ep(hcd, urb); in _dwc2_hcd_urb_enqueue()
2714 dwc2_allocate_bus_bandwidth(hcd, in _dwc2_hcd_urb_enqueue()
2725 usb_hcd_unlink_urb_from_ep(hcd, urb); in _dwc2_hcd_urb_enqueue()
2751 static int _dwc2_hcd_urb_dequeue(struct usb_hcd *hcd, struct urb *urb, in _dwc2_hcd_urb_dequeue() argument
2754 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_urb_dequeue()
2759 dwc2_dump_urb_info(hcd, urb, "urb_dequeue"); in _dwc2_hcd_urb_dequeue()
2763 rc = usb_hcd_check_unlink_urb(hcd, urb, status); in _dwc2_hcd_urb_dequeue()
2774 usb_hcd_unlink_urb_from_ep(hcd, urb); in _dwc2_hcd_urb_dequeue()
2781 usb_hcd_giveback_urb(hcd, urb, status); in _dwc2_hcd_urb_dequeue()
2797 static void _dwc2_hcd_endpoint_disable(struct usb_hcd *hcd, in _dwc2_hcd_endpoint_disable() argument
2800 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_endpoint_disable()
2813 static void _dwc2_hcd_endpoint_reset(struct usb_hcd *hcd, in _dwc2_hcd_endpoint_reset() argument
2816 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_endpoint_reset()
2835 static irqreturn_t _dwc2_hcd_irq(struct usb_hcd *hcd) in _dwc2_hcd_irq() argument
2837 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_irq()
2848 static int _dwc2_hcd_hub_status_data(struct usb_hcd *hcd, char *buf) in _dwc2_hcd_hub_status_data() argument
2850 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_hub_status_data()
2857 static int _dwc2_hcd_hub_control(struct usb_hcd *hcd, u16 typereq, u16 wvalue, in _dwc2_hcd_hub_control() argument
2860 int retval = dwc2_hcd_hub_control(dwc2_hcd_to_hsotg(hcd), typereq, in _dwc2_hcd_hub_control()
2866 static void _dwc2_hcd_clear_tt_buffer_complete(struct usb_hcd *hcd, in _dwc2_hcd_clear_tt_buffer_complete() argument
2869 struct dwc2_hsotg *hsotg = dwc2_hcd_to_hsotg(hcd); in _dwc2_hcd_clear_tt_buffer_complete()
2992 struct usb_hcd *hcd; in dwc2_hcd_init() local
3038 hcd = usb_create_hcd(&dwc2_hc_driver, hsotg->dev, dev_name(hsotg->dev)); in dwc2_hcd_init()
3039 if (!hcd) in dwc2_hcd_init()
3043 hcd->self.uses_dma = 0; in dwc2_hcd_init()
3045 hcd->has_tt = 1; in dwc2_hcd_init()
3047 ((struct wrapper_priv_data *) &hcd->hcd_priv)->hsotg = hsotg; in dwc2_hcd_init()
3048 hsotg->priv = hcd; in dwc2_hcd_init()
3133 hcd->self.otg_port = hsotg->otg_port; in dwc2_hcd_init()
3136 hcd->self.sg_tablesize = 0; in dwc2_hcd_init()
3139 otg_set_host(hsotg->uphy->otg, &hcd->self); in dwc2_hcd_init()
3146 retval = usb_add_hcd(hcd, irq, IRQF_SHARED); in dwc2_hcd_init()
3150 device_wakeup_enable(hcd->self.controller); in dwc2_hcd_init()
3161 usb_put_hcd(hcd); in dwc2_hcd_init()
3180 struct usb_hcd *hcd; in dwc2_hcd_remove() local
3184 hcd = dwc2_hsotg_to_hcd(hsotg); in dwc2_hcd_remove()
3185 dev_dbg(hsotg->dev, "hsotg->hcd = %p\n", hcd); in dwc2_hcd_remove()
3187 if (!hcd) { in dwc2_hcd_remove()
3196 usb_remove_hcd(hcd); in dwc2_hcd_remove()
3199 usb_put_hcd(hcd); in dwc2_hcd_remove()