kernel: tweak the maximum allocation size to improve memory allocator performance
[openwrt.git] / target / linux / pxa / patches-2.6.21 / 008-pxa2xx_udc.patch
1 --- a/drivers/usb/gadget/pxa2xx_udc.c
2 +++ b/drivers/usb/gadget/pxa2xx_udc.c
3 @@ -51,6 +51,7 @@
4 #include <asm/mach-types.h>
5 #include <asm/unaligned.h>
6 #include <asm/hardware.h>
7 +#include <asm/mach/irq.h>
8 #ifdef CONFIG_ARCH_PXA
9 #include <asm/arch/pxa-regs.h>
10 #endif
11 @@ -101,6 +102,10 @@ static const char ep0name [] = "ep0";
12
13 #endif
14
15 +#ifdef CONFIG_ARCH_GUMSTIX
16 +#undef CONFIG_USB_PXA2XX_SMALL
17 +#endif
18 +
19 #include "pxa2xx_udc.h"
20
21
22 @@ -2541,6 +2546,41 @@ static int __init pxa2xx_udc_probe(struc
23 }
24 #endif
25
26 + /* Reset UDCCS register to be able to recover from whatever
27 + * state UDC was previously in. */
28 + *dev->ep[ 2].reg_udccs = UDCCS_BO_RPC | UDCCS_BO_SST;
29 +#ifndef CONFIG_USB_PXA2XX_SMALL
30 + *dev->ep[ 7].reg_udccs = UDCCS_BO_RPC | UDCCS_BO_SST;
31 + *dev->ep[12].reg_udccs = UDCCS_BO_RPC | UDCCS_BO_SST;
32 +#endif
33 +
34 + *dev->ep[ 1].reg_udccs = UDCCS_BI_TPC | UDCCS_BI_FTF |
35 + UDCCS_BI_TUR | UDCCS_BI_SST | UDCCS_BI_TSP;
36 +#ifndef CONFIG_USB_PXA2XX_SMALL
37 + *dev->ep[ 6].reg_udccs = UDCCS_BI_TPC | UDCCS_BI_FTF |
38 + UDCCS_BI_TUR | UDCCS_BI_SST | UDCCS_BI_TSP;
39 + *dev->ep[11].reg_udccs = UDCCS_BI_TPC | UDCCS_BI_FTF |
40 + UDCCS_BI_TUR | UDCCS_BI_SST | UDCCS_BI_TSP;
41 +
42 + *dev->ep[ 3].reg_udccs = UDCCS_II_TPC | UDCCS_II_FTF |
43 + UDCCS_II_TUR | UDCCS_II_TSP;
44 + *dev->ep[ 8].reg_udccs = UDCCS_II_TPC | UDCCS_II_FTF |
45 + UDCCS_II_TUR | UDCCS_II_TSP;
46 + *dev->ep[13].reg_udccs = UDCCS_II_TPC | UDCCS_II_FTF |
47 + UDCCS_II_TUR | UDCCS_II_TSP;
48 +
49 + *dev->ep[ 4].reg_udccs = UDCCS_IO_RPC | UDCCS_IO_ROF;
50 + *dev->ep[ 9].reg_udccs = UDCCS_IO_RPC | UDCCS_IO_ROF;
51 + *dev->ep[11].reg_udccs = UDCCS_IO_RPC | UDCCS_IO_ROF;
52 +
53 + *dev->ep[ 5].reg_udccs = UDCCS_INT_TPC | UDCCS_INT_FTF |
54 + UDCCS_INT_TUR | UDCCS_INT_SST;
55 + *dev->ep[10].reg_udccs = UDCCS_INT_TPC | UDCCS_INT_FTF |
56 + UDCCS_INT_TUR | UDCCS_INT_SST;
57 + *dev->ep[15].reg_udccs = UDCCS_INT_TPC | UDCCS_INT_FTF |
58 + UDCCS_INT_TUR | UDCCS_INT_SST;
59 +#endif
60 +
61 /* other non-static parts of init */
62 dev->dev = &pdev->dev;
63 dev->mach = pdev->dev.platform_data;
This page took 0.045649 seconds and 5 git commands to generate.