Function report |
Source Code:mm\huge_memory.c |
Create Date:2022-07-28 16:01:02 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:do_huge_pmd_anonymous_page
Proto:vm_fault_t do_huge_pmd_anonymous_page(struct vm_fault *vmf)
Type:vm_fault_t
Parameter:
Type | Parameter | Name |
---|---|---|
struct vm_fault * | vmf |
709 | vma = Target VMA |
714 | If Not transhuge_vma_suitable(vma, haddr) Then Return VM_FAULT_FALLBACK |
716 | If Value for the false possibility is greater at compile time(anon_vma_prepare(vma)) Then Return VM_FAULT_OOM |
718 | If Value for the false possibility is greater at compile time(khugepaged_enter(vma, Flags, see mm.h. )) Then Return VM_FAULT_OOM |
728 | If Value for the false possibility is greater at compile time(!pgtable) Then Return VM_FAULT_OOM |
733 | Disable counters |
734 | Return VM_FAULT_FALLBACK |
736 | Page table lock.* Protects pte page table if 'pte'* is not NULL, otherwise pmd. = pmd_lock(The address space we belong to. , Pointer to pmd entry matching* the 'address' ) |
737 | ret = 0 |
738 | set = false |
739 | If pmd_none( * Pointer to pmd entry matching* the 'address' ) Then |
741 | If ret Then |
743 | Else if userfaultfd_missing(vma) Then |
745 | ret = handle_userfault(vmf, missing pages tracking ) |
746 | VM_BUG_ON(ret & VM_FAULT_FALLBACK) |
747 | Else |
753 | Else spin_unlock(Page table lock.* Protects pte page table if 'pte'* is not NULL, otherwise pmd.) |
755 | If Not set Then pte_free - free PTE-level user page table page*@mm: the mm_struct of the current context*@pte_page: the `struct page` representing the page table |
757 | Return ret |
760 | page = alloc_hugepage_vma(gfp, vma, haddr, HPAGE_PMD_ORDER) |
762 | Disable counters |
763 | Return VM_FAULT_FALLBACK |
765 | prep_transhuge_page(page) |
766 | Return __do_huge_pmd_anonymous_page(vmf, page, gfp) |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |