Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/amd64/stand/prekern Remove XXX: set FRAMESIZE to th...
details: https://anonhg.NetBSD.org/src/rev/3f998e791d7b
branches: trunk
changeset: 357537:3f998e791d7b
user: maxv <maxv%NetBSD.org@localhost>
date: Tue Nov 14 13:58:07 2017 +0000
description:
Remove XXX: set FRAMESIZE to the kernel value. Verily I don't understand
why we are doing that in the non-kaslr kernels, but let's just reproduce
the behavior.
jump_kernel is changed to use callq, so that the stack alignment is
preserved.
diffstat:
sys/arch/amd64/stand/prekern/locore.S | 6 +++---
sys/arch/amd64/stand/prekern/redef.h | 5 ++---
2 files changed, 5 insertions(+), 6 deletions(-)
diffs (34 lines):
diff -r 2ed45b98f5e1 -r 3f998e791d7b sys/arch/amd64/stand/prekern/locore.S
--- a/sys/arch/amd64/stand/prekern/locore.S Tue Nov 14 12:20:55 2017 +0000
+++ b/sys/arch/amd64/stand/prekern/locore.S Tue Nov 14 13:58:07 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: locore.S,v 1.4 2017/11/10 08:05:38 maxv Exp $ */
+/* $NetBSD: locore.S,v 1.5 2017/11/14 13:58:07 maxv Exp $ */
/*
* Copyright (c) 1998, 2000, 2007, 2008, 2016, 2017 The NetBSD Foundation, Inc.
@@ -623,6 +623,6 @@
ENTRY(jump_kernel)
movq _C_LABEL(stkva),%rsp
- movq $exec_kernel,%rax
- jmpq *%rax
+ xorq %rbp,%rbp
+ callq exec_kernel
END(jump_kernel)
diff -r 2ed45b98f5e1 -r 3f998e791d7b sys/arch/amd64/stand/prekern/redef.h
--- a/sys/arch/amd64/stand/prekern/redef.h Tue Nov 14 12:20:55 2017 +0000
+++ b/sys/arch/amd64/stand/prekern/redef.h Tue Nov 14 13:58:07 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: redef.h,v 1.1 2017/10/10 09:29:14 maxv Exp $ */
+/* $NetBSD: redef.h,v 1.2 2017/11/14 13:58:07 maxv Exp $ */
/*
* Copyright (c) 2017 The NetBSD Foundation, Inc. All rights reserved.
@@ -43,5 +43,4 @@
* -------------------------------------------------------------------------- */
#define PDE_SIZE 8
-#define FRAMESIZE 8 /* XXX */
-
+#define FRAMESIZE 240
Home |
Main Index |
Thread Index |
Old Index