summaryrefslogtreecommitdiff
path: root/arch/sh/cpu
diff options
context:
space:
mode:
authorVladimir Zapolskiy <vz@mleia.com>2016-11-28 00:15:25 +0200
committerTom Rini <trini@konsulko.com>2016-12-02 21:32:46 -0500
commit3f8b5391ec531adec6fa7602aeb8894b7a23d44d (patch)
tree82865fbe3afc5f93cb4cd0bb1a363a48be5aedbc /arch/sh/cpu
parente2099d78c89428b23173e98d1d5fba4af3109fc2 (diff)
sh4: use single u-boot linker script for all boards
Three supported SH4/SH4A boards with the bootloader image stored on SPI flash have own flavour of a linker script, in turn they are equal among each other. The only difference is that the text from lowlevel_init.o is placed right after start.o, which makes sense. Note that .bss section is not marked as NOLOAD, because for about 10 years this is a default option of a GNU linker, either the attribute is found or not the resulting image file is the same. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/sh/cpu')
-rw-r--r--arch/sh/cpu/u-boot.lds4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/sh/cpu/u-boot.lds b/arch/sh/cpu/u-boot.lds
index 78611c21e6..6f38563303 100644
--- a/arch/sh/cpu/u-boot.lds
+++ b/arch/sh/cpu/u-boot.lds
@@ -11,6 +11,8 @@
* SPDX-License-Identifier: GPL-2.0+
*/
+#include "config.h"
+
OUTPUT_FORMAT("elf32-sh-linux", "elf32-sh-linux", "elf32-sh-linux")
OUTPUT_ARCH(sh)
ENTRY(_start)
@@ -29,6 +31,8 @@ SECTIONS
.text :
{
KEEP(*/start.o (.text))
+ KEEP(CONFIG_BOARDDIR/lowlevel_init.o (.spiboot1.text))
+ KEEP(*(.spiboot2.text))
. = ALIGN(8192);
common/env_embedded.o (.ppcenv)
. = ALIGN(8192);