From 81f4abfa61564b93356daf55ae3fb113794fc052 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vincent=20Rivi=C3=A8re?= Date: Wed, 7 Nov 2012 20:57:09 +0000 Subject: [PATCH] Better BaS alignment handling. --- bas.lk.in | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bas.lk.in b/bas.lk.in index de853e9..8d5bba5 100644 --- a/bas.lk.in +++ b/bas.lk.in @@ -71,11 +71,15 @@ SECTIONS { #if (FORMAT == elf32-m68k) *(.rodata) *(.rodata.*) - . = ALIGN(4); #endif } > flash - .bas _Bas_base : AT (ADDR(.text) + SIZEOF(.text)) + .bas _Bas_base : + /* The BaS is stored in the flash, just after the init part. + * Then it will be copied to its final location in the RAM. + * This data must be aligned for optimal copy loop speed. + */ + AT (ALIGN(ADDR(.text) + SIZEOF(.text), 4)) { objs/BaS.o(.text) /* put other routines into the same segment (RAM) as BaS.o */