]> rtime.felk.cvut.cz Git - sysless.git/blob - board/h8300/h8eurobot/libs/h8canusb.ld-flash
15d522e1344f449385654243e7355b371fcf027d
[sysless.git] / board / h8300 / h8eurobot / libs / h8canusb.ld-flash
1 /* linker script for applications running from FLASH */
2
3 INCLUDE "h8canusb.ld-cfg"
4
5 /* PROVIDE ( sym = val ); */
6
7 PROVIDE( ___stack_top = ( __iram0_end & ~ 3 ) - 4 );
8 /*PROVIDE( ___heap_end = __ram_end );*/
9 PROVIDE( ___heap_end = __iram0_end - 0x200 );
10
11 STARTUP(crt0.o)
12 INPUT(bsp0common.o)
13
14 SECTIONS
15 {
16         .text :
17         {
18           . = ALIGN( 4 ) ;
19           text_start = . ;
20           LONG( ABSOLUTE( _start ) + 0x5a000000 ) /* JMP _start */
21 /*        KEEP (crt0.o(.text)) */
22           . = ALIGN( 4 ) ;
23           ___boot_fn_start = ALIGN( 0x4 ) ;
24           KEEP (*boot_fn.o(.text))
25           KEEP (*boot_fn.o(.rodata))
26           . = ALIGN( 4 ) ;
27           ___boot_fn_end = ALIGN( 0x4 ) ;
28           *(.text)
29           *(.rodata)
30           . = ALIGN( 4 ) ;
31           ___nls_str_start = ALIGN( 0x4 ) ;
32           *(.nls_str)                           
33           ___nls_str_end = ALIGN( 0x4 ) ;
34           *(.strings)
35           _etext = ALIGN( 0x10 ) ;
36         } > flashusr
37
38         .shadreg (NOLOAD) :
39         {
40           *(.shadreg)
41           . = ALIGN( 0x4 ) ;
42         } > iram0
43
44         .tors : 
45         {
46           ___ctors = . ;
47           *(.ctors)
48           ___ctors_end = . ;
49           ___dtors = . ;
50           *(.dtors)
51           ___dtors_end = . ;
52           . = ALIGN( 0x10 ) ;
53           ___data_lma = ALIGN( 0x10 ) ;
54         }  > flashusr
55
56         .data :
57             AT ( ADDR( .tors ) + SIZEOF( .tors ) )
58         {
59           _data_start = . ;
60           *(.data)
61           . = ALIGN( 0x4 ) ;
62           _edata = ALIGN( 0x4 ) ;
63         } > iram0 /*at> flashusr*/
64
65         /* ___data_lma = LOADADDR(.data) ; */
66
67         .bss :
68         {
69           _bss_start = ALIGN( 0x10 ) ;
70           *(.bss)
71           *(COMMON)
72           . = ALIGN( 0x4 ) ;
73           _end = ALIGN( 0x4 ) ;
74         } > iram0
75
76         .tiny : 
77         {
78           *(.tiny)
79         }  > iram0
80         
81         .eight : 
82         {
83           *(.eight)
84         }  > eight
85
86         .stab  0 (NOLOAD) : 
87         {
88           [ .stab ]
89         }
90
91         .stabstr  0 (NOLOAD) :
92         {
93           [ .stabstr ]
94         }
95 }