Low perfomance when read from usb flash drive

Steve Calfee stevecalfee at gmail.com
Tue Mar 3 14:15:44 PST 2009


> I think the reduced performance can be explained by a clamp on the interrupt
> rate around 1000 interrupts per second instead of 8000. Maybe someone has an
> explanation for this?
>
> The EHCI is being programmed to interrupt at 125us intervals, but there seems
> to be limits other places.
>
> It is possible to workaround this in the umass driver by doing the cmd + read
> in one operation.

Hi Hans,

I am looking at using FreeBSD in an embedded product. I have not
examined your ehci software, but I am aware of how Linux and other
OSes run the controller.

Why are you taking an interrupt every uFrame SOF? What can you
possibly do then? You are not in a RTOS, you  are not guaranteed to
even get that fast an interrupt. The whole point of the magic ehci DMA
engine is that many transactions can be programmed and then they can
interrupt when they are done. The Periodic list is set up with
(hopefully) enough transactions that the OS can keep up, and async
doesn't care at all - the only impact is possible xfer speed. Taking
really fast periodic (uFrame) interrupts guarantees no faster
transfers than just having the end of transfer interrupt.

Just wondering.

Regards, Steve


More information about the freebsd-usb mailing list