Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/arch/i386/i386/locore.S,v rcsdiff: /ftp/cvs/cvsroot/src/sys/arch/i386/i386/locore.S,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.64 retrieving revision 1.65 diff -u -p -r1.64 -r1.65 --- src/sys/arch/i386/i386/locore.S 2008/01/20 12:43:00 1.64 +++ src/sys/arch/i386/i386/locore.S 2008/01/21 08:22:42 1.65 @@ -1,4 +1,4 @@ -/* $NetBSD: locore.S,v 1.64 2008/01/20 12:43:00 skrll Exp $ */ +/* $NetBSD: locore.S,v 1.65 2008/01/21 08:22:42 skrll Exp $ */ /* * Copyright-o-rama! @@ -141,7 +141,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: locore.S,v 1.64 2008/01/20 12:43:00 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: locore.S,v 1.65 2008/01/21 08:22:42 skrll Exp $"); #include "opt_compat_oldboot.h" #include "opt_ddb.h" @@ -880,22 +880,19 @@ ENTRY(longjmp) movl $1,%eax # return 1 ret +/* + * void dumpsys(void) + * + * Mimic cpu_switchto() for postmortem debugging. + */ ENTRY(dumpsys) - # mimic cpu_switchto() for postmortem debugging. - - # build a fake switch frame. - pushl %ebx - pushl %esi - pushl %edi - - # save a context. - movl $dumppcb,%eax - movl %esp,PCB_ESP(%eax) - movl %ebp,PCB_EBP(%eax) - - call _C_LABEL(dodumpsys) - - addl $(3*4), %esp # sizeof(switchframe) - sizeof(%eip) + pushl %ebx # set up fake switchframe + pushl %esi # and save context + pushl %edi + movl %esp,_C_LABEL(dumppcb)+PCB_ESP + movl %ebp,_C_LABEL(dumppcb)+PCB_EBP + call _C_LABEL(dodumpsys) # dump! + addl $(3*4), %esp # unwind switchframe ret /*