Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\mmap.c Create Date:2022-07-28 14:49:33
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Create a list of vma's touched by the unmap, removing them from the mm's* vma list as we go..

Proto:static void detach_vmas_to_be_unmapped(struct mm_struct *mm, struct vm_area_struct *vma, struct vm_area_struct *prev, unsigned long end)

Type:void

Parameter:

TypeParameterName
struct mm_struct *mm
struct vm_area_struct *vma
struct vm_area_struct *prev
unsigned longend
2608  struct vm_area_struct * tail_vma = NULL
2610  insertion_point = If prev Then linked list of VM areas per task, sorted by address Else list of VMAs
2611  linked list of VM areas per task, sorted by address = NULL
2612  Do
2613  vma_rb_erase(vma, & mm_rb)
2614  number of VMAs --
2615  tail_vma = vma
2616  vma = linked list of VM areas per task, sorted by address
2617  When vma && Our start address within vm_mm. < end cycle
2618  insertion_point = vma
2619  If vma Then
2620  linked list of VM areas per task, sorted by address = prev
2621  Update augmented rbtree rb_subtree_gap values after vma->vm_start or* in the rbtree.
2622  Else highest vma end address = If prev Then vm_end_gap(prev) Else 0
2624  linked list of VM areas per task, sorted by address = NULL
2627  vmacache_invalidate(mm)
Caller
NameDescribe
__do_munmapMunmap is split into 2 main parts -- this part which finds* what needs doing, and the areas themselves, which do the* work. This now handles partial unmappings.* Jeremy Fitzhardinge