MCPcopy Create free account
hub / github.com/F-Stack/f-stack / pmap_update_pde_store

Function pmap_update_pde_store

freebsd/amd64/amd64/pmap.c:2630–2659  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2628}
2629
2630static void
2631pmap_update_pde_store(pmap_t pmap, pd_entry_t *pde, pd_entry_t newpde)
2632{
2633
2634 switch (pmap->pm_type) {
2635 case PT_X86:
2636 break;
2637 case PT_RVI:
2638 case PT_EPT:
2639 /*
2640 * XXX
2641 * This is a little bogus since the generation number is
2642 * supposed to be bumped up when a region of the address
2643 * space is invalidated in the page tables.
2644 *
2645 * In this case the old PDE entry is valid but yet we want
2646 * to make sure that any mappings using the old entry are
2647 * invalidated in the TLB.
2648 *
2649 * The reason this works as expected is because we rendezvous
2650 * "all" host cpus and force any vcpu context to exit as a
2651 * side-effect.
2652 */
2653 atomic_add_long(&pmap->pm_eptgen, 1);
2654 break;
2655 default:
2656 panic("pmap_update_pde_store: bad pm_type %d", pmap->pm_type);
2657 }
2658 pde_store(pde, newpde);
2659}
2660
2661/*
2662 * After changing the page size for the specified virtual address in the page

Callers 2

pmap_update_pde_actionFunction · 0.85
pmap_update_pdeFunction · 0.85

Calls 2

atomic_add_longFunction · 0.85
panicFunction · 0.50

Tested by

no test coverage detected