PERFORCE change 184933 for review
John Baldwin
jhb at FreeBSD.org
Wed Oct 20 14:25:20 UTC 2010
http://p4web.freebsd.org/@@184933?ac=10
Change 184933 by jhb at jhb_jhbbsd on 2010/10/20 14:24:16
Drop these local changes. alc@ committed an alternate fix.
Affected files ...
.. //depot/projects/smpng/sys/i386/i386/vm86.c#25 edit
.. //depot/projects/smpng/sys/i386/include/pmap.h#52 edit
Differences ...
==== //depot/projects/smpng/sys/i386/i386/vm86.c#25 (text+ko) ====
@@ -592,7 +592,7 @@
mtx_lock(&vm86_lock);
for (i = 0; i < vmc->npages; i++) {
- page = pmap_kextract_early(vmc->pmap[i].kva & PG_FRAME);
+ page = vtophys(vmc->pmap[i].kva & PG_FRAME);
entry = vmc->pmap[i].pte_num;
vmc->pmap[i].old_pte = pte[entry];
pte[entry] = page | PG_V | PG_RW | PG_U;
==== //depot/projects/smpng/sys/i386/include/pmap.h#52 (text+ko) ====
@@ -302,29 +302,6 @@
return (pa);
}
-/*
- * A version of pmap_kextract() that is safe to call before
- * pmap_bootstrap(). This is used in vm86_datacall(). If
- * pmap_bootstrap() has not been called, then KPTmap is not yet
- * initialized, so fall back to using vtopte() instead.
- */
-static __inline vm_paddr_t
-pmap_kextract_early(vm_offset_t va)
-{
- vm_paddr_t pa;
-
- if ((pa = PTD[va >> PDRSHIFT]) & PG_PS) {
- pa = (pa & PG_PS_FRAME) | (va & PDRMASK);
- } else {
- if (KPTmap == NULL)
- pa = *vtopte(va);
- else
- pa = KPTmap[i386_btop(va)];
- pa = (pa & PG_FRAME) | (va & PAGE_MASK);
- }
- return (pa);
-}
-
#define PT_UPDATES_FLUSH()
#endif
More information about the p4-projects
mailing list