函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\mmap.c Create Date:2022-07-27 16:17:31
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Verify that the stack growth is acceptable and* update accounting. This is shared with both the

函数原型:static int acct_stack_growth(struct vm_area_struct *vma, unsigned long size, unsigned long grow)

返回类型:int

参数:

类型参数名称
struct vm_area_struct *vma
unsigned longsize
unsigned longgrowup and grow-down cases.
2274  mm等于The address space we belong to.
2278  如果非Return true if the calling process may expand its vm space by the passed* number of pages则返回:负ENOMEM
2282  如果size大于rlimit(RLIMIT_STACK)则返回:负ENOMEM
2286  如果Flags, see mm.h. 按位与VM_LOCKED
2289  locked等于 Pages that have PG_mlocked set up and grow-down cases.
2290  limit等于rlimit(RLIMIT_MEMLOCK)
2291  limit右移等于PAGE_SHIFT determines the page size
2292  如果locked大于limit且非操作权限检查则返回:负ENOMEM
2297  new_start等于如果Flags, see mm.h. 按位与VM_GROWSUPOur start address within vm_mm. 否则The first byte after our end addresswithin vm_mm. size
2299  如果is_hugepage_only_range(The address space we belong to. , new_start, size)则返回:负EFAULT
2306  如果security_vm_enough_memory_mm(mm, up and grow-down cases.)则返回:负ENOMEM
2309  返回:0
调用者
名称描述
expand_downwardsvma is the first one with address < vma->vm_start. Have to extend vma.