]> git.sur5r.net Git - freertos/blob - Demo/ColdFire_MCF52259_CodeWarrior/lcf/MCF52259_INTERNAL_FLASH.lcf
Start to re-arrange files to include FreeRTOS+ in main download.
[freertos] / Demo / ColdFire_MCF52259_CodeWarrior / lcf / MCF52259_INTERNAL_FLASH.lcf
1 #  NOTE: The debugger uses the Illegal Instruction Vector to stop.\r
2 #  A small subroutine is written at the location VBR+0x408-VBR+0x40B\r
3 #  to handle the exception.  The Illegal Instruction Vector in\r
4 #  the the vector table at VBR+0x10 is then pointed to it.  When the\r
5 #  debugger encounters an illegal instruction, it jumps to this \r
6 #  subroutine, which ends with an RTE, then exits.\r
7 #  Do not overwrite this area of memory otherwise the debugger may not \r
8 #  exit properly.\r
9 # */\r
10 \r
11 MEMORY\r
12 {\r
13         vectorflash(RX) : ORIGIN = 0x00000000, LENGTH = 0x00000418\r
14 \r
15     flash   (RX)   : ORIGIN = 0x00000420, LENGTH = 0x0007FC00\r
16         vectorram(RWX) : ORIGIN = 0x20000000, LENGTH = 0x00000400\r
17         sram    (RWX)  : ORIGIN = 0x20000400, LENGTH = 0x0000FA00\r
18         ipsbar  (RWX)  : ORIGIN = 0x40000000, LENGTH = 0x0\r
19 }\r
20 \r
21 SECTIONS \r
22 {\r
23         .ipsbar  : {} > ipsbar\r
24     \r
25         .vectorflash :\r
26         {\r
27                 mcf5225x_vectors.s (.text)\r
28     } > vectorflash\r
29     \r
30         .flash :\r
31         {\r
32                 *(.text)\r
33                 .                          = ALIGN(0x10);\r
34                 *(.rodata)\r
35 \r
36                 ___DATA_ROM        = .;\r
37     } > flash\r
38     \r
39     .data : AT(___DATA_ROM) \r
40         {\r
41                 ___DATA_RAM    = . ;\r
42 \r
43         *(.exception)   \r
44                 .              = ALIGN(0x10);   \r
45                 __exception_table_start__ = .;\r
46             EXCEPTION\r
47                 __exception_table_end__   = .;\r
48 \r
49                 ___sinit__     = .;\r
50             STATICINIT\r
51 \r
52         *(.data)\r
53         *(.relocate_code)\r
54                 .              = ALIGN (0x10);\r
55                 ___DATA_END    = .;\r
56 \r
57                 __START_SDATA  = .;\r
58         *(.sdata)\r
59 \r
60                 .              = ALIGN (0x10);\r
61                 __END_SDATA    = .;\r
62 \r
63                 __SDA_BASE     = .;\r
64                 .              = ALIGN(0x10);\r
65         } > sram\r
66 \r
67         .bss :\r
68         {\r
69                 . = ALIGN(0x10);\r
70                 __START_SBSS = .;\r
71                 *(.sbss)\r
72                 *(SCOMMON)\r
73                 __END_SBSS   = .;\r
74 \r
75                 . = ALIGN(0x10);\r
76                 __START_BSS  = .;\r
77                 *(.bss)\r
78                 *(COMMON)\r
79                 __END_BSS    = .;       \r
80         ___BSS_START = __START_SBSS;\r
81         ___BSS_END   = __END_BSS;\r
82         . = ALIGN(0x10);\r
83 \r
84         } >> sram\r
85 \r
86         ___FLASH                = ADDR(.vectorflash);\r
87         ___FLASH_SIZE   = 0x00080000;\r
88         ___SRAM                 = 0x20000400;\r
89         ___SRAM_SIZE    = 0x0000FC00;\r
90 \r
91         ___VECTOR_RAM   = 0x20000000;\r
92         ___IPSBAR               = ADDR(.ipsbar);\r
93 \r
94     ___SP_SIZE      = 0x200;\r
95         ___HEAP_START   = .;\r
96         ___HEAP_END             = ___SRAM + ___SRAM_SIZE - ___SP_SIZE;\r
97         ___SP_END               = ___HEAP_END;\r
98         ___SP_INIT              = ___SP_END + ___SP_SIZE;\r
99         \r
100         ___heap_addr    = ___HEAP_START;\r
101         ___heap_size    = ___HEAP_END - ___HEAP_START ;\r
102         __SP_INIT               = ___SP_INIT;\r
103 }\r