From: patrick Date: Sat, 10 Feb 2018 07:02:21 +0000 (+0000) Subject: Supplying entropy from etext has created a regression on arm where we X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=e845b8ed2fc120b92ce19527b80f172f300fc5fc;p=openbsd Supplying entropy from etext has created a regression on arm where we get an alignment fault while copying the data. Turns out that since we have .rodata in the text segment, it's very easily possible that etext remains unaligned. Work around this by word-aligning etext. The next step is to split .rodata out of the text segment. ok deraadt@ --- diff --git a/sys/arch/arm/conf/kern.ldscript b/sys/arch/arm/conf/kern.ldscript index 77fc9948f47..d844dd64a22 100644 --- a/sys/arch/arm/conf/kern.ldscript +++ b/sys/arch/arm/conf/kern.ldscript @@ -1,4 +1,4 @@ -/* $OpenBSD: kern.ldscript,v 1.1 2018/02/10 06:52:47 patrick Exp $ */ +/* $OpenBSD: kern.ldscript,v 1.2 2018/02/10 07:02:21 patrick Exp $ */ /* $NetBSD: ldscript.evbarm,v 1.2 2003/03/05 23:54:22 thorpej Exp $ */ OUTPUT_ARCH(arm) @@ -24,6 +24,7 @@ SECTIONS *(.glue_7t) *(.glue_7) *(.rodata) *(.rodata.*) } =0 + . = ALIGN(4); PROVIDE (__etext = .); PROVIDE (_etext = .); PROVIDE (etext = .);