-#define PMAP_ENTER(pmap, virtual_address, page, protection, flags, wired) \
- MACRO_BEGIN \
- pmap_t __pmap = (pmap); \
- vm_page_t __page = (page); \
- vm_prot_t __prot__ = (protection); \
- \
- if (__pmap == kernel_pmap) { \
- __prot__ |= VM_PROT_WRITE; \
- } else { \
- assert(!__page->encrypted); \
- } \
- \
- pmap_enter( \
- __pmap, \
- (virtual_address), \
- __page->phys_page, \
- __prot__, \
- flags, \
- (wired) \
- ); \
- MACRO_END