flash read performance

Trent Piepho tpiepho at freescale.com
Fri Nov 14 21:02:27 EST 2008


On Tue, 11 Nov 2008, Andre Puschmann wrote:
> Trent Piepho schrieb:
>>> map.virt = ioremap(..);
>>> map.cached = ioremap_cached(..);
>>> map.inval_cache = inval_cache_fct();
>>
>> It depends on what mapping driver you're using.  It looks like only the
>> pxa2xx driver uses map.cached.  The physmap or of_physmap drivers that I'm
>> using don't use it.
>
> The flashmap-drive I am using is custom one made for the gumstix-board.
> However, it is almost identically to pxa2xx-driver from newer kernels.

I added support to physmap_of for using map.cached on ppc32, seems to be
working so far.

But, it turns out it doesn't work for XIP.  The flash drivers that support XIP
implement a ->point() method that something like AXFS or cramfs+xip use to
mmap the flash.  But these just return pointers to the uncached mapping.

>> In non-cached and guarded mode, I now get 13.61 vs 12.30 MB/s.  That's just
>> from slightly better timings because I could make them different for read
>> vs write.  The big difference is cached and non-guarded reads, which went
>> to 44.79 MB/s from 14.24 MB/s.  That boost is from using burst mode.
>
> Whop, this is great news. Btw. do you drive your flash in asynchronous
> or in synchronous mode? Do you have an extra flash configuration
> register that you need to modify in order to use the burst mode?
> My intel NOR flash has an extra read configuration register (RCR).
> However, for some reason I am not able to read/modify/read this register
> successfully.

In asynchronous mode.  I didn't have to program anything special in the flash
chip, just program the localbus controller to use page burst transfers.



More information about the linux-mtd mailing list