int err = 0;
mp_disable_preemption();
-#if NCOPY_WINDOWS > 0
- mapwindow_t *src_map, *dst_map;
- /* We rely on MTRRs here */
- src_map = pmap_get_mapwindow((pt_entry_t)(INTEL_PTE_VALID | ((pmap_paddr_t)src64 & PG_FRAME) | INTEL_PTE_REF));
- dst_map = pmap_get_mapwindow((pt_entry_t)(INTEL_PTE_VALID | INTEL_PTE_RW | ((pmap_paddr_t)dst64 & PG_FRAME) | INTEL_PTE_REF | INTEL_PTE_MOD));
- src = (void *) ((uintptr_t)src_map->prv_CADDR | ((uint32_t)src64 & INTEL_OFFMASK));
- dst = (void *) ((uintptr_t)dst_map->prv_CADDR | ((uint32_t)dst64 & INTEL_OFFMASK));
-#elif defined(__x86_64__)
addr64_t debug_pa = 0;
/* If either destination or source are outside the
kprintf("Remapping debugger physical window at %p to 0x%llx\n", (void *)debugger_window_kva, debug_pa);
#endif
}
-#endif
/* ensure we stay within a page */
if (((((uint32_t)src64 & (I386_PGBYTES - 1)) + bytes) > I386_PGBYTES) || ((((uint32_t)dst64 & (I386_PGBYTES - 1)) + bytes) > I386_PGBYTES)) {
panic("ml_copy_phys spans pages, src: 0x%llx, dst: 0x%llx", src64, dst64);
break;
}
-#if NCOPY_WINDOWS > 0
- pmap_put_mapwindow(src_map);
- pmap_put_mapwindow(dst_map);
-#endif
mp_enable_preemption();
return err;