Lines Matching refs:p2m

4  * Xen leaves the responsibility for maintaining p2m mappings to the
5 * guests themselves, but it must also access and update the p2m array
8 * The logical flat p2m table is mapped to a linear kernel memory area.
18 * p2m p2m p2m ...
37 * INVALID_P2M_ENTRY. This page may be referenced multiple times in the p2m
161 static void p2m_init(unsigned long *p2m)
166 p2m[i] = INVALID_P2M_ENTRY;
169 static void p2m_init_identity(unsigned long *p2m, unsigned long pfn)
174 p2m[i] = IDENTITY_FRAME(pfn + i);
289 /* Set up p2m_top to point to the domain-builder provided p2m pages */
326 static void __init xen_rebuild_p2m_list(unsigned long *p2m)
353 * Try to map missing/identity PMDs or p2m-pages if possible.
356 * Chunk size to test is one p2m page if we are in the middle
376 /* Use initial p2m page contents. */
379 ptep = populate_extra_pte((unsigned long)(p2m + pfn));
386 /* Map complete missing or identity p2m-page. */
389 ptep = populate_extra_pte((unsigned long)(p2m + pfn));
400 (unsigned long)(p2m + pfn) + i * PMD_SIZE);
418 pr_notice("p2m virtual area at %p, size is %lx\n", vm.addr, vm.size);
520 * Fully allocate the p2m structure for a given pfn. We need to check
583 /* p2m leaf page is missing */
584 unsigned long *p2m;
586 p2m = alloc_p2m_page();
587 if (!p2m)
591 p2m_init(p2m);
593 p2m_init_identity(p2m, pfn & ~(P2M_PER_PAGE - 1));
601 pfn_pte(PFN_DOWN(__pa(p2m)), PAGE_KERNEL));
605 mid_mfn[p2m_mid_index(pfn)] = virt_to_mfn(p2m);
606 p2m = NULL;
611 if (p2m)
612 free_p2m_page(p2m);
615 /* Expanded the p2m? */
650 /* Only invalid entries allowed above the highest p2m covered frame. */
655 * The interface requires atomic updates on p2m elements.
837 debugfs_create_file("p2m", 0600, d_mmu_debug, NULL, &p2m_dump_fops);