Subversion Repositories freemyipod

Rev

Rev 881 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 881 Rev 946
Line 11... Line 11...
11
#endif
11
#endif
12
#ifndef SDRAM_SIZE
12
#ifndef SDRAM_SIZE
13
#define SDRAM_SIZE DEFAULT_SDRAM_SIZE
13
#define SDRAM_SIZE DEFAULT_SDRAM_SIZE
14
#endif
14
#endif
15
 
15
 
-
 
16
#ifndef VECTORS_REGION
-
 
17
#define VECTORS_REGION SRAM
-
 
18
#endif
-
 
19
#ifndef VECTORS_BASE
-
 
20
#define VECTORS_BASE SRAM_BASE
-
 
21
#endif
16
#ifndef CODE_REGION
22
#ifndef CODE_REGION
17
#define CODE_REGION SDRAM
23
#define CODE_REGION SDRAM
18
#endif
24
#endif
-
 
25
#ifndef CODE_BASE
-
 
26
#define CODE_BASE
-
 
27
#endif
19
#ifndef BSS_REGION
28
#ifndef BSS_REGION
20
#define BSS_REGION SDRAM
29
#define BSS_REGION SDRAM
21
#endif
30
#endif
-
 
31
#ifndef BSS_BASE
-
 
32
#define BSS_BASE
-
 
33
#endif
22
#ifndef DMABSS_REGION
34
#ifndef DMABSS_REGION
23
#define DMABSS_REGION SRAM
35
#define DMABSS_REGION SRAM
24
#endif
36
#endif
-
 
37
#ifndef DMABSS_BASE
-
 
38
#define DMABSS_BASE
-
 
39
#endif
25
#ifndef STACK_REGION
40
#ifndef STACK_REGION
26
#define STACK_REGION SRAM
41
#define STACK_REGION SRAM
27
#endif
42
#endif
-
 
43
#ifndef STACK_BASE
-
 
44
#define STACK_BASE
-
 
45
#endif
28
 
46
 
29
#ifndef STACK_SIZE
47
#ifndef STACK_SIZE
30
#define STACK_SIZE 0x1000
48
#define STACK_SIZE 0x1000
31
#endif
49
#endif
32
 
50
 
Line 42... Line 60...
42
{
60
{
43
    SRAM : ORIGIN = SRAM_BASE, LENGTH = SRAM_SIZE
61
    SRAM : ORIGIN = SRAM_BASE, LENGTH = SRAM_SIZE
44
    SDRAM : ORIGIN = SDRAM_BASE, LENGTH = SDRAM_SIZE
62
    SDRAM : ORIGIN = SDRAM_BASE, LENGTH = SDRAM_SIZE
45
}
63
}
46
 
64
 
47
_entry = _vectors;
65
_entry = _init;
48
ENTRY(_entry)
66
ENTRY(_entry)
49
 
67
 
50
SECTIONS
68
SECTIONS
51
{
69
{
52
 
70
 
53
    .text :
71
    .text CODE_BASE :
54
    {
72
    {
-
 
73
        _init = .;
-
 
74
        KEEP(*(.init))
-
 
75
        _init_end = .;
55
        _text = .;
76
        _text = .;
56
        KEEP(*(.vectors))
-
 
57
        *(.text)
77
        *(.text)
58
        *(.text.*)
78
        *(.text.*)
59
        *(.rodata)
79
        *(.rodata)
60
        *(.rodata.*)
80
        *(.rodata.*)
61
        *(.dmarodata)
81
        *(.dmarodata)
Line 68... Line 88...
68
        . = ALIGN(1 << CACHEALIGN_BITS);
88
        . = ALIGN(1 << CACHEALIGN_BITS);
69
    } >CODE_REGION
89
    } >CODE_REGION
70
 
90
 
71
    _text_size = _text_end - _text;
91
    _text_size = _text_end - _text;
72
 
92
 
-
 
93
    .vectors VECTORS_BASE :
-
 
94
    {
-
 
95
        _vectors = .;
-
 
96
        KEEP(*(.vectors))
-
 
97
        _vectors_end = .;
-
 
98
    } >VECTORS_REGION AT>CODE_REGION
-
 
99
 
-
 
100
    _vectors_src = LOADADDR(.vectors);
-
 
101
    _vectors_size = _vectors_end - _vectors;
-
 
102
 
-
 
103
    .dummy _text_end - 4 :
-
 
104
    {
-
 
105
        . += 4;
-
 
106
        . = ALIGN(1 << CACHEALIGN_BITS);
-
 
107
    } >CODE_REGION
-
 
108
 
73
    .bss (NOLOAD) :
109
    .bss BSS_BASE (NOLOAD) :
74
    {
110
    {
75
        . = ALIGN(1 << CACHEALIGN_BITS);
111
        . = ALIGN(1 << CACHEALIGN_BITS);
76
        _bss = .;
112
        _bss = .;
77
        *(.bss)
113
        *(.bss)
78
        *(.bss.*)
114
        *(.bss.*)
Line 81... Line 117...
81
        _bss_end = .;
117
        _bss_end = .;
82
    } >BSS_REGION
118
    } >BSS_REGION
83
 
119
 
84
    _bss_size = _bss_end - _bss;
120
    _bss_size = _bss_end - _bss;
85
 
121
 
86
    .dmabss (NOLOAD) :
122
    .dmabss DMABSS_BASE (NOLOAD) :
87
    {
123
    {
88
        . = ALIGN(1 << CACHEALIGN_BITS);
124
        . = ALIGN(1 << CACHEALIGN_BITS);
89
        _dmabss = .;
125
        _dmabss = .;
90
        *(.dmabss)
126
        *(.dmabss)
91
        *(.dmabss.*)
127
        *(.dmabss.*)
Line 93... Line 129...
93
        _dmabss_end = .;
129
        _dmabss_end = .;
94
    } >DMABSS_REGION
130
    } >DMABSS_REGION
95
 
131
 
96
    _dmabss_size = _dmabss_end - _dmabss;
132
    _dmabss_size = _dmabss_end - _dmabss;
97
 
133
 
98
    .stack (NOLOAD) :
134
    .stack STACK_BASE (NOLOAD) :
99
    {
135
    {
100
        . = ALIGN(1 << CACHEALIGN_BITS);
136
        . = ALIGN(1 << CACHEALIGN_BITS);
101
        _stack = .;
137
        _stack = .;
102
        . = . + STACK_SIZE;
138
        . = . + STACK_SIZE;
103
        _stack_top = .;
139
        _stack_top = .;