函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:follow_p4d_mask

函数原型:static struct page *follow_p4d_mask(struct vm_area_struct *vma, unsigned long address, pgd_t *pgdp, unsigned int flags, struct follow_page_context *ctx)

返回类型:struct page

参数:

类型参数名称
struct vm_area_struct *vma
unsigned longaddress
pgd_t *pgdp
unsigned intflags
struct follow_page_context *ctx
471  p4d等于p4d_offset(pgdp, address)
472  如果The "p4d_xxx()" functions here are trivial for a folded two-level* setup: the pud is never bad, and a pud always exists (as it's folded* into the p4d entry)则返回:no_page_table(vma, flags)
474  BUILD_BUG_ON - break compile if a condition is true(p4d_huge( * p4d))
475  如果此条件成立可能性小(为编译器优化)(p4d_bad( * p4d))则返回:no_page_table(vma, flags)
478  如果is_hugepd(__hugepd(p4d_val( * p4d)))则
479  page等于follow_huge_pd(vma, address, __hugepd(p4d_val( * p4d)), flags, P4D_SHIFT)
482  如果page则返回:page
484  返回:no_page_table(vma, flags)
486  返回:follow_pud_mask(vma, address, p4d, flags, ctx)
调用者
名称描述
follow_page_maskllow_page_mask - look up a page descriptor from a user-virtual address*@vma: vm_area_struct mapping @address*@address: virtual address to look up*@flags: flags modifying lookup behaviour*@ctx: contains dev_pagemap for %ZONE_DEVICE memory pinning and a*