svn commit: r200352 - head/sys/i386/i386
Kip Macy
kmacy at FreeBSD.org
Wed Dec 9 23:48:48 PST 2009
Author: kmacy
Date: Thu Dec 10 07:48:47 2009
New Revision: 200352
URL: http://svn.freebsd.org/changeset/base/200352
Log:
for PV XEN translate page table entries from machine (real) to physical (logical) addresses so that kgdb can
translate them to the correct coredump offsets
Modified:
head/sys/i386/i386/minidump_machdep.c
Modified: head/sys/i386/i386/minidump_machdep.c
==============================================================================
--- head/sys/i386/i386/minidump_machdep.c Thu Dec 10 06:42:28 2009 (r200351)
+++ head/sys/i386/i386/minidump_machdep.c Thu Dec 10 07:48:47 2009 (r200352)
@@ -313,7 +313,23 @@ minidumpsys(struct dumperinfo *di)
}
if ((pd[j] & PG_V) == PG_V) {
pa = xpmap_mtop(pd[j] & PG_FRAME);
+#ifndef XEN
error = blk_write(di, 0, pa, PAGE_SIZE);
+#else
+ pt = pmap_kenter_temporary(pa, 0);
+ memcpy(fakept, pt, PAGE_SIZE);
+ for (i = 0; i < NPTEPG; i++)
+ fakept[i] = xpmap_mtop(fakept[i]);
+ error = blk_write(di, (char *)&fakept, 0, PAGE_SIZE);
+ if (error)
+ goto fail;
+ /* flush, in case we reuse fakept in the same block */
+ error = blk_flush(di);
+ if (error)
+ goto fail;
+ bzero(fakept, sizeof(fakept));
+#endif
+
if (error)
goto fail;
} else {
More information about the svn-src-all
mailing list