函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:hmm_vma_handle_pmd

函数原型:static int hmm_vma_handle_pmd(struct mm_walk *walk, unsigned long addr, unsigned long end, uint64_t *pfns, pmd_t pmd)

返回类型:int

参数:

类型参数名称
struct mm_walk *walk
unsigned longaddr
unsigned longend
uint64_t *pfns
pmd_tpmd
218  hmm_vma_walk等于private
219  range等于range
224  npages等于endaddr右移PAGE_SHIFT determines the page size
225  cpu_flags等于pmd_to_hmm_pfn_flags(range, pmd)
226  hmm_range_need_fault(hmm_vma_walk, pfns, npages, cpu_flags, & fault, & write_fault)
229  如果pmd_protnone(pmd)或faultwrite_fault则返回:hmm_vma_walk_hole_() - handle a range lacking valid pmd or pte(s)*@addr: range virtual start address (inclusive)*@end: range virtual end address (exclusive)*@fault: should we fault or not ?*@write_fault: write fault ?*@walk: mm_walk structure* Return: 0
232  pfn等于pmd_pfn(pmd)加addr按位与PMD_MASK的反的值右移PAGE_SHIFT determines the page size 位的值
233 addr小于end循环
234  如果pmd_devmap(pmd)则
240  pfns[i]等于hmm_device_entry_from_pfn() - create a valid device entry value from pfn*@range: range use to encode HMM pfn value*@pfn: pfn value for which to create the device entry* Return: valid device entry for the pfn按位或cpu_flags
242  如果pgmap
243  put_dev_pagemap(pgmap)
244  pgmap = NULL
246  last等于end
247  返回:0
调用者
名称描述
hmm_vma_walk_pmd