Function report |
Source Code:mm\memory.c |
Create Date:2022-07-28 14:42:16 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:This routine handles present pages, when users try to write* to a shared page. It is done by copying the page to a new address* and decrementing the shared-page counter for the old page.* Note that this routine assumes that the protection checks have been
Proto:static vm_fault_t do_wp_page(struct vm_fault *vmf)__releases(vmf->ptl)
Type:vm_fault_t
Parameter:
Type | Parameter | Name |
---|---|---|
struct vm_fault * | vmf |
2717 | vma = Target VMA |
2728 | If (Flags, see mm.h. & (VM_WRITE | VM_SHARED)) == (VM_WRITE | VM_SHARED) Then Return Handle write page faults for VM_MIXEDMAP or VM_PFNMAP for a VM_SHARED* mapping |
2745 | If Not Return true if the page was successfully locked Then |
2746 | get_page(->fault handlers should return a* page here, unless VM_FAULT_NOPAGE* is set (which is also implied by* VM_FAULT_ERROR).) |
2747 | pte_unmap_unlock(Pointer to pte entry matching* the 'address'. NULL if the page* table hasn't been allocated., Page table lock.* Protects pte page table if 'pte'* is not NULL, otherwise pmd.) |
2753 | pte_unmap_unlock(Pointer to pte entry matching* the 'address'. NULL if the page* table hasn't been allocated., Page table lock.* Protects pte page table if 'pte'* is not NULL, otherwise pmd.) |
2754 | put_page(->fault handlers should return a* page here, unless VM_FAULT_NOPAGE* is set (which is also implied by* VM_FAULT_ERROR).) |
2755 | Return 0 |
2760 | reused = reuse_ksm_page(->fault handlers should return a* page here, unless VM_FAULT_NOPAGE* is set (which is also implied by* VM_FAULT_ERROR)., Target VMA , Faulting virtual address ) |
2766 | Return VM_FAULT_WRITE |
2769 | If total_map_swapcount == 1 Then |
2781 | Return VM_FAULT_WRITE |
2784 | Else if Value for the false possibility is greater at compile time((Flags, see mm.h. & (VM_WRITE | VM_SHARED)) == (VM_WRITE | VM_SHARED)) Then |
2786 | Return wp_page_shared(vmf) |
2788 | copy : |
2792 | get_page(->fault handlers should return a* page here, unless VM_FAULT_NOPAGE* is set (which is also implied by* VM_FAULT_ERROR).) |
2794 | pte_unmap_unlock(Pointer to pte entry matching* the 'address'. NULL if the page* table hasn't been allocated., Page table lock.* Protects pte page table if 'pte'* is not NULL, otherwise pmd.) |
Name | Describe |
---|---|
do_swap_page | We enter with non-exclusive mmap_sem (to exclude vma changes,* but allow concurrent faults), and pte mapped but not yet locked.* We return with pte unmapped and unlocked.* We return with the mmap_sem locked or unlocked in the same cases |
handle_pte_fault | These routines also need to handle stuff like marking pages dirty* and/or accessed for architectures that don't do it in hardware (most* RISC architectures) |
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 |