diff options
Diffstat (limited to 'drivers/usb/gadget/s3c_udc_otg.c')
-rw-r--r-- | drivers/usb/gadget/s3c_udc_otg.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/drivers/usb/gadget/s3c_udc_otg.c b/drivers/usb/gadget/s3c_udc_otg.c index a4f33cd..6a28e4f 100644 --- a/drivers/usb/gadget/s3c_udc_otg.c +++ b/drivers/usb/gadget/s3c_udc_otg.c @@ -672,13 +672,17 @@ static void set_max_pktsize(struct s3c_udc *dev, enum usb_device_speed speed) } else { ep0_fifo_size = 64; ep_fifo_size = 64; - ep_fifo_size2 = 64; + ep_fifo_size2 = 1023; dev->gadget.speed = USB_SPEED_FULL; } dev->ep[0].ep.maxpacket = ep0_fifo_size; - for (i = 1; i < S3C_MAX_ENDPOINTS; i++) - dev->ep[i].ep.maxpacket = ep_fifo_size; + for (i = 1; i < S3C_MAX_ENDPOINTS; i++) { + if (dev->ep[i].bmAttributes == USB_ENDPOINT_XFER_ISOC) + dev->ep[i].ep.maxpacket = ep_fifo_size2; + else + dev->ep[i].ep.maxpacket = ep_fifo_size; + } /* EP0 - Control IN (64 bytes)*/ ep_ctrl = __raw_readl(dev->regs + S3C_UDC_OTG_DIEPCTL(EP0_CON)); @@ -710,6 +714,7 @@ static int s3c_ep_enable(struct usb_ep *_ep, /* xfer types must match, except that interrupt ~= bulk */ if (ep->bmAttributes != desc->bmAttributes && ep->bmAttributes != USB_ENDPOINT_XFER_BULK + && ep->bmAttributes != USB_ENDPOINT_XFER_ISOC && desc->bmAttributes != USB_ENDPOINT_XFER_INT) { DEBUG("%s: %s type mismatch\n", __func__, _ep->name); @@ -1176,16 +1181,16 @@ static struct s3c_udc memory = { }, .ep[15] = { .ep = { - .name = "ep15-int", + .name = "ep15-iso", .ops = &s3c_ep_ops, - .maxpacket = EP_FIFO_SIZE, + .maxpacket = EP_FIFO_SIZE2, }, .dev = &memory, .bEndpointAddress = USB_DIR_IN | 15, - .bmAttributes = USB_ENDPOINT_XFER_INT, + .bmAttributes = USB_ENDPOINT_XFER_ISOC, - .ep_type = ep_interrupt, + .ep_type = ep_iso_in, .fifo = (unsigned int) S3C_UDC_OTG_EP15_FIFO, }, }; |