1//------------------------------------------------------------------------------
2//      Linker scatter for running in external SDRAM on the AT91SAM9260
3//------------------------------------------------------------------------------
4
5//
6// Define a memory region that covers the entire 4 GB addressible space of the
7// processor.
8//
9define memory mem with size = 4G;
10
11//
12// Define a region for the on-chip flash.
13//
14define region FLASH = mem:[from 0x70000000 to 0x707FFFFF];
15
16//
17// Define a region for the on-chip SRAM.
18//
19define region SRAM  = mem:[from 0x70800000 to 0x73FFFFFF];
20
21//
22// Indicate that the read/write values should be initialized by copying from
23// flash.
24//
25initialize by copy { readwrite };
26
27//
28// Indicate that the noinit values should be left alone.  This includes the
29// stack, which if initialized will destroy the return address from the
30// initialization code, causing the processor to branch to zero and fault.
31//
32do not initialize { section .noinit };
33
34//
35// Place the interrupt vectors at the start of flash.
36//
37place at start of FLASH { readonly section .intvec };
38
39//
40// Place the remainder of the read-only items into flash.
41//
42place in FLASH { readonly };
43
44//
45// Place the RAM vector table at the start of SRAM.
46//
47place at start of SRAM { section VTABLE };
48
49//
50// Place all read/write items into SRAM.
51//
52place in SRAM { readwrite};
53keep { section FSymTab };
54keep { section VSymTab };
55keep { section .rti_fn* };
56