flush_cache_mm(mm); /* Use ~0UL here to ensure all VMAs in the mm are unmapped */ mm->map_count -= unmap_vmas(&tlb, mm, mm->mmap, 0, ~0UL, &nr_accounted, NULL); 
/* Use -1 here to ensure all VMAs in the mm are unmapped */ mm->map_count -= unmap_vmas(&tlb, mm, vma, 0, -1, &nr_accounted, NULL); 
void exit_mmap(struct mm_struct *mm){	struct mmu_gather *tlb;	struct vm_area_struct *vma;	unsigned long nr_accounted = 0;	lru_add_drain();	spin_lock(&mm->page_table_lock);	tlb = tlb_gather_mmu(mm, 1);	flush_cache_mm(mm);	/* Use ~0UL here to ensure all VMAs in the mm are unmapped */	mm->map_count -= unmap_vmas(&tlb, mm, mm->mmap, 0,					~0UL, &nr_accounted, NULL);	vm_unacct_memory(nr_accounted);	BUG_ON(mm->map_count);	/* This is just debugging */	clear_page_range(tlb, FIRST_USER_PGD_NR * PGDIR_SIZE, MM_VM_SIZE(mm));		tlb_finish_mmu(tlb, 0, MM_VM_SIZE(mm));	vma = mm->mmap;	mm->mmap = mm->mmap_cache = NULL;	mm->mm_rb = RB_ROOT;	set_mm_counter(mm, rss, 0);	mm->total_vm = 0;	mm->locked_vm = 0;	spin_unlock(&mm->page_table_lock);	/*	 * Walk the list again, actually closing and freeing it	 * without holding any MM locks.	 */	while (vma) {		struct vm_area_struct *next = vma->vm_next;		remove_vm_struct(vma);		vma = next;	}}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/e0da382c92626ad1d7f4b7527d19b80104d67a83/mmap.c/clean/mm/mmap.c