1/* 2 * Copyright (C) 2016 Vladimir Zapolskiy <vz@mleia.com> 3 * Copyright (C) 2008-2009 Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com> 4 * Copyright (C) 2008 Mark Jonas <mark.jonas@de.bosch.com> 5 * Copyright (C) 2007 Nobuhiro Iwamatsu <iwamatsu@nigauri.org> 6 * 7 * SPDX-License-Identifier: GPL-2.0+ 8 */ 9 10#include "config.h" 11 12OUTPUT_FORMAT("elf32-sh-linux", "elf32-sh-linux", "elf32-sh-linux") 13OUTPUT_ARCH(sh) 14 15MEMORY 16{ 17 ram : ORIGIN = CONFIG_SYS_SDRAM_BASE, LENGTH = CONFIG_SYS_SDRAM_SIZE 18} 19 20ENTRY(_start) 21 22SECTIONS 23{ 24 reloc_dst = .; 25 26 PROVIDE (_ftext = .); 27 PROVIDE (_fcode = .); 28 PROVIDE (_start = .); 29 30 .text : 31 { 32 KEEP(*/start.o (.text)) 33 KEEP(CONFIG_BOARDDIR/lowlevel_init.o (.text .spiboot1.text)) 34 KEEP(*(.spiboot2.text)) 35 . = ALIGN(8192); 36 env/embedded.o (.ppcenv) 37 . = ALIGN(8192); 38 env/embedded.o (.ppcenvr) 39 . = ALIGN(8192); 40 *(.text) 41 . = ALIGN(4); 42 } >ram =0xFF 43 PROVIDE (_ecode = .); 44 .rodata : 45 { 46 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) 47 . = ALIGN(4); 48 } >ram 49 PROVIDE (_etext = .); 50 51 52 PROVIDE (_fdata = .); 53 .data : 54 { 55 *(.data) 56 . = ALIGN(4); 57 } >ram 58 PROVIDE (_edata = .); 59 60 PROVIDE (_fgot = .); 61 .got : 62 { 63 *(.got.plt) *(.got) 64 . = ALIGN(4); 65 } >ram 66 PROVIDE (_egot = .); 67 68 .u_boot_list : { 69 KEEP(*(SORT(.u_boot_list*))); 70 } >ram 71 72 PROVIDE (__init_end = .); 73 PROVIDE (reloc_dst_end = .); 74 75 PROVIDE (bss_start = .); 76 PROVIDE (__bss_start = .); 77 .bss : 78 { 79 *(.bss) 80 . = ALIGN(4); 81 } >ram 82 PROVIDE (bss_end = .); 83 PROVIDE (__bss_end = .); 84} 85