37 pr_dinfo2(vmm,
"mm_do_unmap: vaddr=" PTR_FMT ", n_pages=%zu, do_unref=%d", vaddr, n_pages, do_unref);
39 size_t n_pages1 = n_pages;
41 const ptr_t vaddr2 = vaddr;
42 const size_t n_pages2 = n_pages;
79#if MOS_CONFIG(PML4_HUGE_CAPABLE)
80 if (platform_pml4e_is_huge(pml4e))
81 return platform_pml4e_get_huge_pfn(pml4e) + (vaddr & PML4_HUGE_MASK) /
MOS_PAGE_SIZE;
89#if MOS_CONFIG(PML3_HUGE_CAPABLE)
99#if MOS_CONFIG(PML2_HUGE_CAPABLE)
125#if MOS_CONFIG(PML4_HUGE_CAPABLE)
126 if (platform_pml4e_is_huge(pml4e))
139#if MOS_CONFIG(PML3_HUGE_CAPABLE)
153#if MOS_CONFIG(PML2_HUGE_CAPABLE)
vm_flags platform_pml3e_get_flags(const pml3e_t *pml3e)
vm_flags platform_pml4e_get_flags(const pml4e_t *pml4e)
vm_flags platform_pml1e_get_flags(const pml1e_t *pml1e)
vm_flags platform_pml2e_get_flags(const pml2e_t *pml2e)
bool platform_pml3e_is_huge(const pml3e_t *pml3e)
pfn_t platform_pml2e_get_huge_pfn(const pml2e_t *pml2)
bool platform_pml2e_is_huge(const pml2e_t *pml2e)
pfn_t platform_pml3e_get_huge_pfn(const pml3e_t *pml3)
const pagetable_walk_options_t pagetable_do_copy_callbacks
const pagetable_walk_options_t pagetable_do_flag_callbacks
const pagetable_walk_options_t pagetable_do_map_callbacks
const pagetable_walk_options_t pagetable_do_mask_callbacks
const pagetable_walk_options_t pagetable_do_unmap_callbacks
__BEGIN_DECLS phyframe_t * mm_get_free_page(void)
#define phyframe_va(frame)
#define mm_free_page(frame)
#define mmstat_dec1(type)
#define mmstat_inc1(type)
#define ALIGN_DOWN_TO_PAGE(addr)
pfn_t pml1e_get_pfn(const pml1e_t *pml1e)
bool pml1e_is_present(const pml1e_t *pml1e)
pml1e_t * pml1_entry(pml1_t pml1, ptr_t vaddr)
pml1_t pml2e_get_or_create_pml1(pml2e_t *pml2e)
bool pml2e_is_present(const pml2e_t *pml2e)
pml2e_t * pml2_entry(pml2_t pml2, ptr_t vaddr)
pml2_t pml3e_get_or_create_pml2(pml3e_t *pml3e)
bool pml3e_is_present(const pml3e_t *pml3e)
pml3e_t * pml3_entry(pml3_t pml3, ptr_t vaddr)
pml3_t pml4e_get_or_create_pml3(pml4e_t *pml4e)
pml4e_t * pml4_entry(pml4_t pml4, ptr_t vaddr)
bool pml4e_is_present(const pml4e_t *pml4e)
pml5e_t * pml5_entry(pml5_t pml5, ptr_t vaddr)
bool pml5e_is_present(const pml5e_t *pml5e)
pml4_t pml5e_get_or_create_pml4(pml5e_t *pml5e)
void pml5_traverse(pml5_t pml5, ptr_t *vaddr, size_t *n_pages, pagetable_walk_options_t callback, void *data)
__nodiscard bool pml5_destroy_range(pml5_t pml5, ptr_t *vaddr, size_t *n_pages)
#define pr_dinfo2(feat, fmt,...)
vm_flags mm_do_get_flags(pgd_t max, ptr_t vaddr)
void __destroy_page_table(void *table)
void * __create_page_table(void)
void mm_do_map(pgd_t pgd, ptr_t vaddr, pfn_t pfn, size_t n_pages, vm_flags flags, bool do_refcount)
bool mm_do_get_present(pgd_t max, ptr_t vaddr)
void mm_do_copy(pgd_t src, pgd_t dst, ptr_t vaddr, size_t n_pages)
void mm_do_mask_flags(pgd_t max, ptr_t vaddr, size_t n_pages, vm_flags mask)
void mm_do_flag(pgd_t max, ptr_t vaddr, size_t n_pages, vm_flags flags)
pfn_t mm_do_get_pfn(pgd_t max, ptr_t vaddr)
void mm_do_unmap(pgd_t max, ptr_t vaddr, size_t n_pages, bool do_unref)