函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\events\core.c Create Date:2022-07-27 14:56:42
Last Modify:2022-05-20 07:50:19 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:perf_virt_to_phys

函数原型:static u64 perf_virt_to_phys(u64 virt)

返回类型:u64

参数:

类型参数名称
u64virt
6732  phys_addr等于0
6733  struct page * p = NULL
6735  如果非virt则返回:0
6738  如果virt大于等于TASK_SIZE
6740  如果virt_addr_valid((void * )(uintptr_t)virt)且非virt大于等于VMALLOC_STARTvirt小于VMALLOC_END的值则phys_addr等于virt_to_phys - map virtual addresses to physical*@address: address to remap* The returned physical address is the physical (CPU) mapping for* the memory address given. It is only valid to use this function on
6743  否则
6751  如果((mm != NULL) && (doesn't attempt to fault and will return short. == 1))则phys_addr等于Change "struct page" to physical address.(p)加virt取模PAGE_SIZE
6755  如果pput_page(p)
6759  返回:phys_addr
调用者
名称描述
perf_prepare_sample