blob: 254d9f274bef7e4389292ccb7e74fbc8ed307f1a [file] [log] [blame]
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +09001/*
2 * Copyright (C) 2008 Nobuhiro Iwamatsu
3 * Copyright (C) 2008 Renesas Solutions Corp.
4 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +09006 */
7
8OUTPUT_FORMAT("elf32-sh-linux", "elf32-sh-linux", "elf32-sh-linux")
9OUTPUT_ARCH(sh)
10ENTRY(_start)
11
12SECTIONS
13{
14 /*
Jean-Christophe PLAGNIOL-VILLARD6e743892009-06-04 12:06:44 +020015 * entry and reloct_dst will be provided via ldflags
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090016 */
Jean-Christophe PLAGNIOL-VILLARD6e743892009-06-04 12:06:44 +020017 . = .;
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090018
19 PROVIDE (_ftext = .);
20 PROVIDE (_fcode = .);
21 PROVIDE (_start = .);
22
23 .text :
24 {
Nobuhiro Iwamatsucb4148c2011-03-07 16:36:21 +090025 KEEP(arch/sh/cpu/sh2/start.o (.text))
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090026 . = ALIGN(8192);
Jean-Christophe PLAGNIOL-VILLARD4436c1e2008-09-10 22:48:01 +020027 common/env_embedded.o (.ppcenv)
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090028 . = ALIGN(8192);
Jean-Christophe PLAGNIOL-VILLARD4436c1e2008-09-10 22:48:01 +020029 common/env_embedded.o (.ppcenvr)
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090030 . = ALIGN(8192);
31 *(.text)
32 . = ALIGN(4);
33 } =0xFF
34 PROVIDE (_ecode = .);
35 .rodata :
36 {
Trent Piepho4438e5e2009-02-18 15:22:05 -080037 *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090038 . = ALIGN(4);
39 }
40 PROVIDE (_etext = .);
41
42
43 PROVIDE (_fdata = .);
44 .data :
45 {
46 *(.data)
47 . = ALIGN(4);
48 }
49 PROVIDE (_edata = .);
50
51 PROVIDE (_fgot = .);
52 .got :
53 {
54 *(.got)
55 . = ALIGN(4);
56 }
57 PROVIDE (_egot = .);
58
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090059
Marek Vasut607092a2012-10-12 10:27:03 +000060 .u_boot_list : {
Albert ARIBAUDc24895e2013-02-25 00:59:00 +000061 KEEP(*(SORT(.u_boot_list*)));
Marek Vasut607092a2012-10-12 10:27:03 +000062 }
63
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090064 PROVIDE (reloc_dst_end = .);
65
66 PROVIDE (bss_start = .);
67 PROVIDE (__bss_start = .);
68 .bss :
69 {
70 *(.bss)
71 . = ALIGN(4);
72 }
73 PROVIDE (bss_end = .);
74
Simon Glassed70c8f2013-03-14 06:54:53 +000075 PROVIDE (__bss_end = .);
Nobuhiro Iwamatsu6f7d4362008-08-31 23:02:04 +090076}