Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:vm_brk_flags

Proto:int vm_brk_flags(unsigned long addr, unsigned long request, unsigned long flags)

Type:int

Parameter:

TypeParameterName
unsigned longaddr
unsigned longrequest
unsigned longflags
3045  mm = mm
3049  LIST_HEAD(uf)
3051  len = align the pointer to the (next) page boundary (request)
3052  If len < request Then Return -ENOMEM
3054  If Not len Then Return 0
3057  If lock for writing Then Return -EINTR
3060  ret = his is really a simplified "do_mmap". it only handles* anonymous maps. eventually we may be able to do some* brk-specific accounting here.
3061  populate = (def_flags & VM_LOCKED) != 0
3062  lease a write lock
3063  userfaultfd_unmap_complete(mm, & uf)
3064  If populate && Not ret Then mm_populate(addr, len)
3066  Return ret
Caller
NameDescribe
vm_brk
load_elf_interpThis is much more generalized than the library routine read function,so we keep this separate. Technically the library read functionis only provided so that we can read a.out libraries that havean ELF header