Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/aarch64 Fix alignment of .text section by changing ...
details: https://anonhg.NetBSD.org/src/rev/fc2b59fb3181
branches: trunk
changeset: 465804:fc2b59fb3181
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Wed Dec 04 11:24:31 2019 +0000
description:
Fix alignment of .text section by changing load address to
0xffffffc000000000 and adding 64 bytes of padding before the entry point.
diffstat:
sys/arch/aarch64/aarch64/start.S | 9 +++++++--
sys/arch/aarch64/conf/Makefile.aarch64 | 4 ++--
2 files changed, 9 insertions(+), 4 deletions(-)
diffs (48 lines):
diff -r 817bb9446b23 -r fc2b59fb3181 sys/arch/aarch64/aarch64/start.S
--- a/sys/arch/aarch64/aarch64/start.S Wed Dec 04 11:21:34 2019 +0000
+++ b/sys/arch/aarch64/aarch64/start.S Wed Dec 04 11:24:31 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: start.S,v 1.2 2018/10/18 09:01:51 skrll Exp $ */
+/* $NetBSD: start.S,v 1.3 2019/12/04 11:24:31 jmcneill Exp $ */
/*
* Copyright (c) 2017 Ryo Shimizu <ryo%nerv.org@localhost>
@@ -32,7 +32,7 @@
#include <aarch64/asm.h>
-RCSID("$NetBSD: start.S,v 1.2 2018/10/18 09:01:51 skrll Exp $")
+RCSID("$NetBSD: start.S,v 1.3 2019/12/04 11:24:31 jmcneill Exp $")
/* load far effective address (pc relative) */
.macro ADDR, reg, addr
@@ -41,6 +41,11 @@
.endm
/*
+ * Padding at start of kernel image to make room for 64-byte header (non-ELF booting)
+ */
+.space 64, 0x0
+
+/*
* Kernel start routine for aarch64 boards.
*/
.global start
diff -r 817bb9446b23 -r fc2b59fb3181 sys/arch/aarch64/conf/Makefile.aarch64
--- a/sys/arch/aarch64/conf/Makefile.aarch64 Wed Dec 04 11:21:34 2019 +0000
+++ b/sys/arch/aarch64/conf/Makefile.aarch64 Wed Dec 04 11:24:31 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.aarch64,v 1.15 2019/03/03 07:04:40 maxv Exp $
+# $NetBSD: Makefile.aarch64,v 1.16 2019/12/04 11:24:31 jmcneill Exp $
# Makefile for NetBSD
#
@@ -74,7 +74,7 @@
## (5) link settings
##
KERNLDSCRIPT?= ${ARM}/conf/kern.ldscript
-LOADADDRESS?= 0xffffffc000000040
+LOADADDRESS?= 0xffffffc000000000
LINKFLAGS_NORMAL= -X
# Strip AArch64 mapping symbols from the kernel image, as they interfere
Home |
Main Index |
Thread Index |
Old Index