[parisc-linux] Re: RFC: mmap patch

David S. Miller davem@redhat.com
Sat, 08 Mar 2003 15:00:23 -0800 (PST)


   From: Matthew Wilcox <willy@debian.org>
   Date: Sat, 8 Mar 2003 22:45:03 +0000
   
   The upshot is that if two addresses are congruent modulo 4MB and they
   map to the same physical address, the cache will detect it.  I've been
   thinking about (ab)using kmap() for this for a while.  The trouble
   is we'd need to have 1024 slots just to be guaranteed space to map 1
   page -- if we need to guarantee to be able to map two pages at once,
   we need 2048 slots (ie 8MB of virtual space).  Etc.  I have no idea how
   many pages we expect to be able to map simultaneously, and haven't been
   able to get a straight answer out of anyone so far.

You need merely 8MB of address space (2 * 4MB) if you implement
my {copy,clear}_user_page() dynamic mapping hack, that will be
tons more cheaper than any kmap based scheme and also be nicer
on the TLB as there will be zero TLB changes occurring around
the copy/clear.

People can continue to talk about all their bright new idea, which
is fine, but it feels like my known-working ideas are being ignored.