Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/mac68k/mac68k Align tmpstk to 4-byte boundary as re...



details:   https://anonhg.NetBSD.org/src/rev/2a1e9ecd3b73
branches:  trunk
changeset: 1012079:2a1e9ecd3b73
user:      rin <rin%NetBSD.org@localhost>
date:      Tue Jul 21 05:45:38 2020 +0000

description:
Align tmpstk to 4-byte boundary as required by System V (ELF) ABI.

Fix GCC8-compiled kernel crash during very early boot stage when
printf decimal numbers; __umoddi3 corrupts stack frame which is not
aligned properly.

diffstat:

 sys/arch/mac68k/mac68k/locore.s |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diffs (17 lines):

diff -r ee9aaf4265ef -r 2a1e9ecd3b73 sys/arch/mac68k/mac68k/locore.s
--- a/sys/arch/mac68k/mac68k/locore.s   Tue Jul 21 05:33:51 2020 +0000
+++ b/sys/arch/mac68k/mac68k/locore.s   Tue Jul 21 05:45:38 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: locore.s,v 1.171 2018/12/19 13:57:48 maxv Exp $        */
+/*     $NetBSD: locore.s,v 1.172 2020/07/21 05:45:38 rin Exp $ */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -1367,6 +1367,7 @@
        .long   0x18621862      | this is our stack overflow checker.
 
        .space  4 * PAGE_SIZE
+       .align  4
 ASLOCAL(tmpstk)
 
 GLOBAL(machineid)



Home | Main Index | Thread Index | Old Index