匿名和文件缺页中断
mmap的预备知识
缺页中断的区分
static inline vm_fault_t create_huge_pmd(struct vm_fault *vmf)
{
struct vm_area_struct *vma = vmf->vma;
if (vma_is_anonymous(vma))
return do_huge_pmd_anonymous_page(vmf);
if (vma->vm_ops->huge_fault)
return vma->vm_ops->huge_fault(vmf, PMD_ORDER);
return VM_FAULT_FALLBACK;
}文件页缺页中断
读
私有写
共享写
filemap_fault
refcount变化
do_sync_mmap_readahead()
Last updated