Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:remap_p4d_range

Proto:static inline int remap_p4d_range(struct mm_struct *mm, pgd_t *pgd, unsigned long addr, unsigned long end, unsigned long pfn, pgprot_t prot)

Type:int

Parameter:

TypeParameterName
struct mm_struct *mm
pgd_t *pgd
unsigned longaddr
unsigned longend
unsigned longpfn
pgprot_tprot
1888  pfn -= addr >> PAGE_SHIFT determines the page size
1889  p4d = The following ifdef needed to get the 5level-fixup.h header to work.* Remove it when 5level-fixup.h has been removed.
1890  If Not p4d Then Return -ENOMEM
1892  Do
1893  next = p4d_addr_end(addr, end)
1894  err = remap_pud_range(mm, p4d, addr, next, pfn + (addr >> PAGE_SHIFT determines the page size ), prot)
1896  If err Then Return err
1898  When p4d++, addr = next , addr != end cycle
1899  Return 0
Caller
NameDescribe
remap_pfn_rangemap_pfn_range - remap kernel memory to userspace*@vma: user vma to map to*@addr: target user address to start at*@pfn: physical address of kernel memory*@size: size of map area*@prot: page protection flags for this mapping