函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:If the vma has a ->close operation then the driver probably needs to release* per-vma resources, so we don't attempt to merge those.

函数原型:static inline int is_mergeable_vma(struct vm_area_struct *vma, struct file *file, unsigned long vm_flags, struct vm_userfaultfd_ctx vm_userfaultfd_ctx)

返回类型:int

参数:

类型参数名称
struct vm_area_struct *vma
struct file *file
unsigned longvm_flags
struct vm_userfaultfd_ctxvm_userfaultfd_ctx
997  如果Flags, see mm.h. 按位异或vm_flags的值按位与VM_SOFTDIRTY的反则返回:0
999  如果File we map to (can be NULL). 不等于file则返回:0
1001  如果Function pointers to deal with this struct. close则返回:0
1003  如果非mm helpers 则返回:0
1005  返回:1
调用者
名称描述
can_vma_merge_beforeReturn true if we can merge this (vm_flags,anon_vma,file,vm_pgoff)* in front of (at a lower virtual address and file offset than) the vma.* We cannot merge two vmas if they have differently assigned (non-NULL)
can_vma_merge_afterReturn true if we can merge this (vm_flags,anon_vma,file,vm_pgoff)* beyond (at a higher virtual address and file offset than) the vma.* We cannot merge two vmas if they have differently assigned (non-NULL)