summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
Diffstat (limited to 'firmware')
-rw-r--r--firmware/app.lds79
1 files changed, 79 insertions, 0 deletions
diff --git a/firmware/app.lds b/firmware/app.lds
index 9fef2ec46d..83a09a81d0 100644
--- a/firmware/app.lds
+++ b/firmware/app.lds
@@ -1,3 +1,5 @@
1#include "config.h"
2
1ENTRY(start) 3ENTRY(start)
2OUTPUT_FORMAT(elf32-sh) 4OUTPUT_FORMAT(elf32-sh)
3INPUT(crt0.o) 5INPUT(crt0.o)
@@ -16,12 +18,88 @@ INPUT(crt0.o)
16 18
17MEMORY 19MEMORY
18{ 20{
21#ifdef NEO_MEMORY
22 ROM : ORIGIN = 0x00020000, LENGTH = 0x1E0000
23 SRAM : ORIGIN = 0x0C000000, LENGTH = 0x40000
24#else
19 DRAM : ORIGIN = ORIGADDR, LENGTH = DRAMSIZE 25 DRAM : ORIGIN = ORIGADDR, LENGTH = DRAMSIZE
26#endif
20 IRAM : ORIGIN = 0x0f000000, LENGTH = 0x1000 27 IRAM : ORIGIN = 0x0f000000, LENGTH = 0x1000
21} 28}
22 29
23SECTIONS 30SECTIONS
24{ 31{
32#ifdef NEO_MEMORY
33 .bss :
34 {
35 _edata = .;
36 *(.bss)
37 *(COMMON)
38 _end = .;
39 } > SRAM
40
41 .text :
42 {
43 . = ALIGN(0x4);
44 *(.vectors);
45 . = ALIGN(0x200);
46 *(.init.text)
47 *(.text)
48 } > ROM
49
50 .rodata :
51 {
52 *(.rodata)
53 *(.rodata.str1.4)
54 . = ALIGN(0x4);
55 } > ROM
56
57 .data : AT ( LOADADDR(.romdata) )
58 {
59 _datastart = .;
60 *(.data)
61 _dataend = .;
62 } > SRAM
63
64 .iram : AT ( _iramcopy )
65 {
66 _iramstart = .;
67 *(.icode)
68 *(.idata)
69 _iramend = .;
70 } > IRAM
71
72 .romdata :
73 {
74 _datacopy = .;
75 . += SIZEOF(.data);
76 _iramcopy = .;
77 . += SIZEOF(.iram);
78 } > ROM
79
80 .stack :
81 {
82 _stackbegin = .;
83 *(.stack)
84 . += 0x1000;
85 _stackend = .;
86 } > SRAM
87
88 .mp3buf :
89 {
90 _mp3buffer = .;
91 } > SRAM
92
93 .mp3end 0x0C040000 - 0x300:
94 {
95 _mp3end = .;
96 } > SRAM
97
98 .plugin 0x0C040000:
99 {
100 _pluginbuf = .;
101 } > SRAM
102#else
25 .vectors : 103 .vectors :
26 { 104 {
27 *(.resetvectors); 105 *(.resetvectors);
@@ -97,4 +175,5 @@ SECTIONS
97 *(.idata) 175 *(.idata)
98 _iramend = .; 176 _iramend = .;
99 } > IRAM 177 } > IRAM
178#endif
100} 179}