函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:ksm_madvise

函数原型:int ksm_madvise(struct vm_area_struct *vma, unsigned long start, unsigned long end, int advice, unsigned long *vm_flags)

返回类型:int

参数:

类型参数名称
struct vm_area_struct *vma
unsigned longstart
unsigned longend
intadvice
unsigned long *vm_flags
2431  mm等于The address space we belong to.
2435  :advice恒等于KSM may merge identical pages
2439  如果vm_flags按位与KSM may merge identical pages 按位或VM_SHARED按位或VM_MAYSHARE按位或Page-ranges managed without "struct page", just pure PFN 按位或Memory mapped I/O or similar 按位或Cannot expand with mremap() 按位或Huge TLB Page VM 按位或Can contain "struct page" and pure PFN pages 的值则返回:0
2444  如果vma_is_dax(vma)则返回:0
2457  err等于__ksm_enter(mm)
2458  如果err则返回:err
2462  vm_flags或等于KSM may merge identical pages
2463  退出
2465  :advice恒等于KSM may not merge identical pages
2466  如果非vm_flags按位与KSM may merge identical pages 的值则返回:0
2471  如果err则返回:err
2475  vm_flags与等于KSM may merge identical pages 的反
2476  退出
2479  返回:0
调用者
名称描述
madvise_behaviorWe can potentially split a vm area into separate* areas, each area with its own behavior.
move_vma