diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 2004-06-21 22:35:48 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 2004-06-21 22:35:48 +0000 |
commit | 7603b38588139b41a7f72c1875ee7d5cc0ec4a51 (patch) | |
tree | ed0172845a09cba1679d2b079e12ae0e38070255 | |
parent | 6385ffc6399b16f5cb79dac7dc2046aae9d54377 (diff) |
Pure luck has protected us from this bug until now: locore.S
%r9 are not saved over function calls
and more we did not even want &proc0 as the old process in switch_search, but zero. Fixes bsd.rd.
-rw-r--r-- | sys/arch/amd64/amd64/locore.S | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/amd64/amd64/locore.S b/sys/arch/amd64/amd64/locore.S index 732eea0a0df..665161f05c6 100644 --- a/sys/arch/amd64/amd64/locore.S +++ b/sys/arch/amd64/amd64/locore.S @@ -1,4 +1,4 @@ -/* $OpenBSD: locore.S,v 1.11 2004/06/13 21:49:12 niklas Exp $ */ +/* $OpenBSD: locore.S,v 1.12 2004/06/21 22:35:47 niklas Exp $ */ /* $NetBSD: locore.S,v 1.2 2003/04/26 19:34:45 fvdl Exp $ */ /* @@ -1036,8 +1036,8 @@ ENTRY(switch_exit) call *%rsi /* Jump into cpu_switch() with the right state. */ - movq %r9, %r13 - movq $0, CPUVAR(CURPROC) + xorq %r13, %r13 + movq %r13, CPUVAR(CURPROC) jmp switch_search /* |