[PATCH][RFC] NAND subpage read feature. Take 2.
Hamish Moffatt
hamish at cloud.net.au
Tue May 6 05:42:49 EDT 2008
On Tue, May 06, 2008 at 08:15:31AM +0200, Jörn Engel wrote:
> On Tue, 6 May 2008 10:15:15 +1000, Hamish Moffatt wrote:
> >
> > Caching only makes sense when you can read extra data at no cost.
>
> Not true. Caching makes sense when the benefits outweigh the costs,
> just like everything else. "No cost" is just a special case where even
> minimal benefits suffice.
>
> Nand already does caching, it just limits itself to a single page. If
> two consecutive reads hit the single page, it is only read once. Which
> easily fits your definition and just as easily helps single-threaded
> users. But two threads bouncing back and forth can already nullify the
> gains. It would be useful to keep as much old data around as there is
> DRAM for.
It makes sense to keep data that you had to read anyway, but with the
subpage read patch that's less than a whole page.
> [ Also, even ubi attach may benefit from caching under special
> circumstances. If you have just written an image and have enough ram,
> there is no reason to go back to flash. But that hardly matters in real
> life. ]
I agree. So are we talking about caching of data which we've read
anyway, or speculative reads? Because reading more than the user
requested is speculation afaict. If LogFS (for example) reads a whole
page even when it doesn't need it, that will degrade performance in some
cases.
Hamish
--
Hamish Moffatt VK3SB <hamish at debian.org> <hamish at cloud.net.au>
More information about the linux-mtd
mailing list