Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:hugepage_vma_check

Proto:static bool hugepage_vma_check(struct vm_area_struct *vma, unsigned long vm_flags)

Type:bool

Parameter:

TypeParameterName
struct vm_area_struct *vma
unsigned longvm_flags
410  If Not (vm_flags & MADV_HUGEPAGE marked this vma ) && Not khugepaged_always() || vm_flags & MADV_NOHUGEPAGE marked this vma || st_bit - Determine whether a bit is set*@nr: bit number to test*@addr: Address to start counting from Then Return false
415  If shmem_file(File we map to (can be NULL). ) || IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_READ_ONLY_THP_FOR_FS) && File we map to (can be NULL). && vm_flags & ETXTBSY on write attempts.. Then
419  If Not IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_TRANSPARENT_HUGE_PAGECACHE) Then Return false
421  Return IS_ALIGNED((Our start address within vm_mm. >> PAGE_SHIFT determines the page size ) - Offset (within vm_file) in PAGE_SIZEunits , HPAGE_PMD_NR)
424  If Not Serialized by page_table_lock || Function pointers to deal with this struct. Then Return false
426  If is_vma_temporary_stack(vma) Then Return false
428  Return Not (vm_flags & VM_NO_KHUGEPAGED)
Caller
NameDescribe
khugepaged_enter_vma_merge
hugepage_vma_revalidateIf mmap_sem temporarily dropped, revalidate vma* before taking mmap_sem.* Return 0 if succeeds, otherwise return none-zero* value (scan code).
khugepaged_scan_mm_slot