Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:change_pte_range

Proto:static unsigned long change_pte_range(struct vm_area_struct *vma, pmd_t *pmd, unsigned long addr, unsigned long end, pgprot_t newprot, int dirty_accountable, int prot_numa)

Type:unsigned long

Parameter:

TypeParameterName
struct vm_area_struct *vma
pmd_t *pmd
unsigned longaddr
unsigned longend
pgprot_tnewprot
intdirty_accountable
intprot_numa
44  pages = 0
45  target_node = NUMA_NO_NODE
53  If This is a noop if Transparent Hugepage Support is not built into* the kernel Then Return 0
61  pte = pte_offset_map_lock(The address space we belong to. , pmd, addr, & ptl)
64  If prot_numa && Not (Flags, see mm.h. & VM_SHARED) && atomic_read( & mm_users) == 1 Then target_node = Returns the number of the current Node.
68  flush_tlb_batched_pending(The address space we belong to. )
69  A facility to provide lazy MMU batching()
70  Do
71  oldpte = pte
72  If pte_present(oldpte) Then
80  If prot_numa Then
124  pages++
157  When pte++, addr += PAGE_SIZE , addr != end cycle
158  arch_leave_lazy_mmu_mode()
159  pte_unmap_unlock(pte - 1, ptl)
161  Return pages
Caller
NameDescribe
change_pmd_range