| Subject | Re: [PATCH 08/21] mm: Preemptible mmu_gather | From | Peter Zijlstra <> | Date | Mon, 29 Nov 2010 21:47:02 +0100 |
| |
On Mon, 2010-11-29 at 11:53 +0900, KAMEZAWA Hiroyuki wrote: > On Fri, 26 Nov 2010 15:38:51 +0100 > Peter Zijlstra <a.p.zijlstra@chello.nl> wrote: > > > Make mmu_gather preemptible by using a small on stack list and use > > an option allocation to speed things up. > > > > Preemptible mmu_gather is desired in general and usable once > > i_mmap_lock becomes a mutex. Doing it before the mutex conversion > > saves us from having to rework the code by moving the mmu_gather > > bits inside the i_mmap_lock. > > > > Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> > > Cc: David Miller <davem@davemloft.net> > > Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> > > Cc: Russell King <rmk@arm.linux.org.uk> > > Cc: Paul Mundt <lethal@linux-sh.org> > > Cc: Jeff Dike <jdike@addtoit.com> > > Cc: Tony Luck <tony.luck@intel.com> > > Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> > > Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> > > Interesting, Hmm, how about using the 1st freed pages as tlb->pages > rathet than calling alloc_page() ? no benefits ?
We could try that, but we need to be careful there, you need to wait till after the TLB invalidate and possibly an RCU period for the page-directory pages (sparc/powerpc).
So doing an optimistic allocation before the TLB invalidate seems saner.
Also, see patch 20.
|