Re: [parisc-linux] rmap: parisc __flush_dcache_page

From: James Bottomley
Date: Thu Apr 08 2004 - 10:32:25 EST


On Thu, 2004-04-08 at 10:14, Andrea Arcangeli wrote:
> you'd need to take a semaphore there to be safe, so it's basically
> unfixable since you can't sleep or just trylock.

That's a bit of an unhelpful suggestion.

flush_dcache_page() exists to support coherency problems with virtual
aliasing and a feature of that is that you have to flush every
inequivalent user address which might be cached, hence the need for list
traversal.

Exactly why wouldn't a simple spinlock to protect page->mapping work? I
know we don't want to bloat struct page, but such a thing could go in
struct address_space?

James


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/