Lines Matching refs:crq

524 static int s3c2410_udc_read_fifo_crq(struct usb_ctrlrequest *crq)  in s3c2410_udc_read_fifo_crq()  argument
526 unsigned char *outbuf = (unsigned char *)crq; in s3c2410_udc_read_fifo_crq()
541 bytes_read, crq->bRequest, crq->bRequestType, in s3c2410_udc_read_fifo_crq()
542 crq->wValue, crq->wIndex, crq->wLength); in s3c2410_udc_read_fifo_crq()
548 struct usb_ctrlrequest *crq) in s3c2410_udc_get_status() argument
551 u8 ep_num = crq->wIndex & 0x7F; in s3c2410_udc_get_status()
552 u8 is_in = crq->wIndex & USB_DIR_IN; in s3c2410_udc_get_status()
554 switch (crq->bRequestType & USB_RECIP_MASK) { in s3c2410_udc_get_status()
563 if (ep_num > 4 || crq->wLength > 2) in s3c2410_udc_get_status()
601 struct usb_ctrlrequest *crq, in s3c2410_udc_handle_ep0_idle() argument
612 len = s3c2410_udc_read_fifo_crq(crq); in s3c2410_udc_handle_ep0_idle()
613 if (len != sizeof(*crq)) { in s3c2410_udc_handle_ep0_idle()
616 sizeof(*crq), len); in s3c2410_udc_handle_ep0_idle()
622 crq->bRequest, crq->bRequestType, crq->wLength); in s3c2410_udc_handle_ep0_idle()
625 dev->req_std = (crq->bRequestType & USB_TYPE_MASK) in s3c2410_udc_handle_ep0_idle()
630 switch (crq->bRequest) { in s3c2410_udc_handle_ep0_idle()
634 if (crq->bRequestType == USB_RECIP_DEVICE) { in s3c2410_udc_handle_ep0_idle()
643 if (crq->bRequestType == USB_RECIP_INTERFACE) { in s3c2410_udc_handle_ep0_idle()
652 if (crq->bRequestType == USB_RECIP_DEVICE) { in s3c2410_udc_handle_ep0_idle()
653 tmp = crq->wValue & 0x7F; in s3c2410_udc_handle_ep0_idle()
667 if (!s3c2410_udc_get_status(dev, crq)) in s3c2410_udc_handle_ep0_idle()
675 if (crq->bRequestType != USB_RECIP_ENDPOINT) in s3c2410_udc_handle_ep0_idle()
678 if (crq->wValue != USB_ENDPOINT_HALT || crq->wLength != 0) in s3c2410_udc_handle_ep0_idle()
681 s3c2410_udc_set_halt(&dev->ep[crq->wIndex & 0x7f].ep, 0); in s3c2410_udc_handle_ep0_idle()
688 if (crq->bRequestType != USB_RECIP_ENDPOINT) in s3c2410_udc_handle_ep0_idle()
691 if (crq->wValue != USB_ENDPOINT_HALT || crq->wLength != 0) in s3c2410_udc_handle_ep0_idle()
694 s3c2410_udc_set_halt(&dev->ep[crq->wIndex & 0x7f].ep, 1); in s3c2410_udc_handle_ep0_idle()
703 if (crq->bRequestType & USB_DIR_IN) in s3c2410_udc_handle_ep0_idle()
712 ret = dev->driver->setup(&dev->gadget, crq); in s3c2410_udc_handle_ep0_idle()
716 crq->bRequest, ret); in s3c2410_udc_handle_ep0_idle()
744 struct usb_ctrlrequest crq; in s3c2410_udc_handle_ep0() local
779 s3c2410_udc_handle_ep0_idle(dev, ep, &crq, ep0csr); in s3c2410_udc_handle_ep0()