[lkml]   [2010]   [May]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] MMC: at91_mci: modify cache flush routines
On Wed, May 12, 2010 at 02:19:29PM -0700, Andrew Morton wrote:
> The flush_kernel_dcache_page() documentation specifically says that
> thou shalt run flush_kernel_dcache_page() _prior_ to kunmapping the
> page.

Hmm, interesting - I can't see why that would be, but it doesn't make
any difference for ARM (and this is an ARM only driver).

> I don't know if that makes a difference in the real world, but heck why
> not:

In the interests of stopping cut'n'paste bugs into other drivers, I'd
say this is a good idea even if it makes no difference to ARM.

> However, I'm wondering why you chose flush_kernel_dcache_page() instead
> of plain old flush_dcache_page(). Is this a pagecache or possibly
> direct-io page we're dealing with here?

It's whatever the block layers hand us - which would be page cache pages,
and I'd assume also DIO pages (I'm not up on DIO stuff though.)

It's also my understanding that the preferred interface for drivers which
write to page cache pages is flush_kernel_dcache_page() rather than

 \ /
  Last update: 2010-05-12 23:33    [W:0.037 / U:3.944 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site