Hi,

On Sun, Nov 25, 2018 at 09:14:28AM -0800, Tony Lindgren wrote:
> * Aaro Koskinen <[email protected]> [181125 16:58]:
> > Below changes get traffic going with DMA & g_ether...
> 
> Oh cool, if you have dma and g_ether working, you should
> test it with a variable size ping test loop :) That should
> expose any issues within few minutes.

The ping test is working fine. Also setting MTU higher works fine.

I was also able to reduce the needed changes further, so only the below
are now needed for 15xx DMA.

The dma_dest_len() change I can understand.

But why the BURST_4 is not working in out direction?

--- a/drivers/usb/gadget/udc/omap_udc.c
+++ b/drivers/usb/gadget/udc/omap_udc.c
@@ -498,7 +498,7 @@ static u16 dma_dest_len(struct omap_ep *ep, dma_addr_t 
start)
 
        end |= start & (0xffff << 16);
        if (cpu_is_omap15xx())
-               end++;
+               end += sizeof(u16);
        if (end < start)
                end += 0x10000;
        return end - start;
@@ -754,8 +754,9 @@ static void dma_channel_claim(struct omap_ep *ep, unsigned 
channel)
                                UDC_DATA_DMA,
                                0, 0);
                        /* EMIFF or SDRC */
-                       omap_set_dma_dest_burst_mode(ep->lch,
-                                               OMAP_DMA_DATA_BURST_4);
+                       if (!cpu_is_omap15xx())
+                               omap_set_dma_dest_burst_mode(ep->lch,
+                                                       OMAP_DMA_DATA_BURST_4);
                        omap_set_dma_dest_data_pack(ep->lch, 1);
                }
        }

A.

Reply via email to