Lines Matching refs:host
69 struct musb *host = hcd->hcd_priv; in submit_urb() local
83 host->isr(0, host); in submit_urb()
93 static int _musb_submit_control_msg(struct musb_host_data *host, in _musb_submit_control_msg() argument
97 construct_urb(&host->urb, &host->hep, dev, USB_ENDPOINT_XFER_CONTROL, in _musb_submit_control_msg()
102 dev->speed = host->host_speed; in _musb_submit_control_msg()
104 return submit_urb(&host->hcd, &host->urb); in _musb_submit_control_msg()
107 static int _musb_submit_bulk_msg(struct musb_host_data *host, in _musb_submit_bulk_msg() argument
110 construct_urb(&host->urb, &host->hep, dev, USB_ENDPOINT_XFER_BULK, in _musb_submit_bulk_msg()
112 return submit_urb(&host->hcd, &host->urb); in _musb_submit_bulk_msg()
115 static int _musb_submit_int_msg(struct musb_host_data *host, in _musb_submit_int_msg() argument
119 construct_urb(&host->urb, &host->hep, dev, USB_ENDPOINT_XFER_INT, pipe, in _musb_submit_int_msg()
121 return submit_urb(&host->hcd, &host->urb); in _musb_submit_int_msg()
124 static struct int_queue *_musb_create_int_queue(struct musb_host_data *host, in _musb_create_int_queue() argument
148 ret = musb_urb_enqueue(&host->hcd, &queue->urb, 0); in _musb_create_int_queue()
159 static int _musb_destroy_int_queue(struct musb_host_data *host, in _musb_destroy_int_queue() argument
166 musb_urb_dequeue(&host->hcd, &queue->urb, -ETIME); in _musb_destroy_int_queue()
173 static void *_musb_poll_int_queue(struct musb_host_data *host, in _musb_poll_int_queue() argument
179 host->host->isr(0, host->host); in _musb_poll_int_queue()
187 static int _musb_reset_root_port(struct musb_host_data *host, in _musb_reset_root_port() argument
190 void *mbase = host->host->mregs; in _musb_reset_root_port()
198 if (host->host->ops->pre_root_reset_end) in _musb_reset_root_port()
199 host->host->ops->pre_root_reset_end(host->host); in _musb_reset_root_port()
204 if (host->host->ops->post_root_reset_end) in _musb_reset_root_port()
205 host->host->ops->post_root_reset_end(host->host); in _musb_reset_root_port()
207 host->host->isr(0, host->host); in _musb_reset_root_port()
208 host->host_speed = (musb_readb(mbase, MUSB_POWER) & MUSB_POWER_HSMODE) ? in _musb_reset_root_port()
212 mdelay((host->host_speed == USB_SPEED_LOW) ? 200 : 50); in _musb_reset_root_port()
217 int musb_lowlevel_init(struct musb_host_data *host) in musb_lowlevel_init() argument
224 if (!host->host) { in musb_lowlevel_init()
229 ret = musb_start(host->host); in musb_lowlevel_init()
233 mbase = host->host->mregs; in musb_lowlevel_init()
239 musb_stop(host->host); in musb_lowlevel_init()
243 _musb_reset_root_port(host, NULL); in musb_lowlevel_init()
244 host->host->is_active = 1; in musb_lowlevel_init()
245 host->hcd.hcd_priv = host->host; in musb_lowlevel_init()
253 if (!musb_host.host) { in usb_lowlevel_stop()
258 musb_stop(musb_host.host); in usb_lowlevel_stop()
315 struct musb_host_data *host = dev_get_priv(dev); in musb_submit_control_msg() local
316 return _musb_submit_control_msg(host, udev, pipe, buffer, length, setup); in musb_submit_control_msg()
322 struct musb_host_data *host = dev_get_priv(dev); in musb_submit_bulk_msg() local
323 return _musb_submit_bulk_msg(host, udev, pipe, buffer, length); in musb_submit_bulk_msg()
330 struct musb_host_data *host = dev_get_priv(dev); in musb_submit_int_msg() local
331 return _musb_submit_int_msg(host, udev, pipe, buffer, length, interval, in musb_submit_int_msg()
339 struct musb_host_data *host = dev_get_priv(dev); in musb_create_int_queue() local
340 return _musb_create_int_queue(host, udev, pipe, queuesize, elementsize, in musb_create_int_queue()
347 struct musb_host_data *host = dev_get_priv(dev); in musb_poll_int_queue() local
348 return _musb_poll_int_queue(host, udev, queue); in musb_poll_int_queue()
354 struct musb_host_data *host = dev_get_priv(dev); in musb_destroy_int_queue() local
355 return _musb_destroy_int_queue(host, udev, queue); in musb_destroy_int_queue()
360 struct musb_host_data *host = dev_get_priv(dev); in musb_reset_root_port() local
361 return _musb_reset_root_port(host, udev); in musb_reset_root_port()
436 musbp = &musb_host.host; in musb_register()