From bb24280ffce6a8bc6b03d29a43ec16ac14e9ec85 Mon Sep 17 00:00:00 2001 From: David Brownell Date: Tue, 27 May 2008 19:24:20 -0700 Subject: [PATCH] USB: at91_udc: updated fifo sizes It turns out newer versions of the AT91 UDC hardware have increased sizes of some of the FIFOs. Reporting that is a Good Thing. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman --- drivers/usb/gadget/at91_udc.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/drivers/usb/gadget/at91_udc.c b/drivers/usb/gadget/at91_udc.c index b6b2a0a5ba3..e2d8a5d86c4 100644 --- a/drivers/usb/gadget/at91_udc.c +++ b/drivers/usb/gadget/at91_udc.c @@ -1687,6 +1687,19 @@ static int __init at91udc_probe(struct platform_device *pdev) udc->board.pullup_active_low); } + /* newer chips have more FIFO memory than rm9200 */ + if (cpu_is_at91sam9260()) { + udc->ep[0].maxpacket = 64; + udc->ep[3].maxpacket = 64; + udc->ep[4].maxpacket = 512; + udc->ep[5].maxpacket = 512; + } else if (cpu_is_at91sam9261()) { + udc->ep[3].maxpacket = 64; + } else if (cpu_is_at91sam9263()) { + udc->ep[0].maxpacket = 64; + udc->ep[3].maxpacket = 64; + } + udc->udp_baseaddr = ioremap(res->start, res->end - res->start + 1); if (!udc->udp_baseaddr) { retval = -ENOMEM; -- 2.20.1