Re: [QUESTION] bulk out performance

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Saturday 21 March 2009, Ming Lei wrote:
> I use g_zero(f_sourcesink configuration) as test device and omap3 musb
> as UDC, the result
> of usbtest testcase 5(bulk out) only have ~8MB/s, but testcase 6(bulk
> in) can reach ~24MB/sec.
> Why is there so much difference between bulk out and bulk in transfer?

It's been a LONG time since I looked at such issues with
MUSB hardware, but the short version of the story is that
the DMA linkage works sanely for TX, much less so for RX.
That depends a bit on the specific hardware, of course...

Have a look at in drivers/usb/musb/cppi_dma.c under headings
"CPPI TX" and "CPPI RX Woes".  Its my understanding that very
similar problems appear with all DMA linkages to that core,
even ones using Mentor's own DMA (like OMAP3).  Some newer
parts may have at least partially resolved that, and I know
Felipe has been working on  this issue (for OMAP3).

Think of it this way:  "mode 0" DMA is one DMA per packet;
pretty much at the "why even bother" level.  That's the only
mode that seems to work well for RX.  While "mode 1" handles
many packets per DMA transfer ... works well for TX, but for
RX the *NORMAL* case (transfer terminates by "short packet")
is not handled well.  (Only the mass storage driver makes a
habit of using any other transfer termination mode.)

- Dave

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux