From: Jeff Dike Date: Sun, 6 May 2007 21:51:49 +0000 (-0700) Subject: uml: only flush areas covered by VMA X-Git-Tag: v2.6.22-rc1~836 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=1e7371c1a11f041d641cc0ff113bf1daa1bd98b9;p=linux-2.6-omap-h63xx.git uml: only flush areas covered by VMA When doing a full address space flush, only look at areas covered by a VMA. Signed-off-by: Jeff Dike Cc: Paolo 'Blaisorblade' Giarrusso Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/arch/um/kernel/skas/tlb.c b/arch/um/kernel/skas/tlb.c index b3d722ddde3..c0f0693743b 100644 --- a/arch/um/kernel/skas/tlb.c +++ b/arch/um/kernel/skas/tlb.c @@ -89,8 +89,13 @@ void flush_tlb_mm_skas(struct mm_struct *mm) void force_flush_all_skas(void) { - unsigned long end = proc_mm ? task_size : CONFIG_STUB_START; - fix_range(current->mm, 0, end, 1); + struct mm_struct *mm = current->mm; + struct vm_area_struct *vma = mm->mmap; + + while(vma != NULL) { + fix_range(mm, vma->vm_start, vma->vm_end, 1); + vma = vma->vm_next; + } } void flush_tlb_page_skas(struct vm_area_struct *vma, unsigned long address)