[U-Boot] OT: SD/MMC-over-SPI and speed in linux

Wolfgang Wegner wolfgang at leila.ping.de
Thu May 6 15:13:14 CEST 2010


Hi all,

sorry for the off-topic question, but I seemingly did not yet find
the right search string and was hoping to find experienced embedded
people here to point me in the right direction.

I have connected a SD card to a coldfire MCF54455 via SPI, accessible
from both U-Boot and linux. The kernel is quite old, 2.6.25 from the
freescale LTIB, because freescale did not push their coldfire changes
back into any official tree.

In U-Boot, I can get read speeds with fatload of around 400 kBytes/second,
which seems reasonable as the card can handle 25 MHz SPI speed. (And, it
would be sufficient for our application.)

In the linux kernel, the read speed drops to around 35 kBytes/second,
regardless of using a filesystem or not. This is not only quite ridiculous
(as I would expect more optimized drivers in the kernel than in the
bootloader), but would give us real performance problems when writing
to the card. The SPI speed is detected and set correctly to 25 MHz by
the driver.

Does anybody know if this is a known limitation in (older) linux
mmc_spi implementation, or if this issue still exists? If it is
solved, can anybody point me to a patch/discussion/keyword where I can
find more information which part I would have to check or back-port?

Best regards,
Wolfgang



More information about the U-Boot mailing list