On Tue, 2011-06-28 at 11:46 +0800, Shaohua Li wrote: > __tlb_remove_page switchs to a new batch page, but still checks space in the > old batch. This check always fails, and causes force tlb flush. > > Signed-off-by: Shaohua Li <shaohua.li@xxxxxxxxx> Indeed! Acked-by: Peter Zijlstra <a.p.zijlstra@xxxxxxxxx> > diff --git a/mm/memory.c b/mm/memory.c > index 40b7531..9b8a01d 100644 > --- a/mm/memory.c > +++ b/mm/memory.c > @@ -305,6 +305,7 @@ int __tlb_remove_page(struct mmu_gather *tlb, struct page *page) > if (batch->nr == batch->max) { > if (!tlb_next_batch(tlb)) > return 0; > + batch = tlb->active; > } > VM_BUG_ON(batch->nr > batch->max); > > > -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: <a href