aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/kernel/vmlinux.lds.S
diff options
context:
space:
mode:
Diffstat (limited to 'arch/blackfin/kernel/vmlinux.lds.S')
-rw-r--r--arch/blackfin/kernel/vmlinux.lds.S28
1 files changed, 16 insertions, 12 deletions
diff --git a/arch/blackfin/kernel/vmlinux.lds.S b/arch/blackfin/kernel/vmlinux.lds.S
index f39707c6590d..66799e763dc9 100644
--- a/arch/blackfin/kernel/vmlinux.lds.S
+++ b/arch/blackfin/kernel/vmlinux.lds.S
@@ -121,8 +121,6 @@ SECTIONS
121 EXIT_DATA 121 EXIT_DATA
122 } 122 }
123 123
124 __l1_lma_start = .;
125
126 .text_l1 L1_CODE_START : AT(LOADADDR(.exit.data) + SIZEOF(.exit.data)) 124 .text_l1 L1_CODE_START : AT(LOADADDR(.exit.data) + SIZEOF(.exit.data))
127 { 125 {
128 . = ALIGN(4); 126 . = ALIGN(4);
@@ -134,9 +132,11 @@ SECTIONS
134 . = ALIGN(4); 132 . = ALIGN(4);
135 __etext_l1 = .; 133 __etext_l1 = .;
136 } 134 }
137 ASSERT (SIZEOF(.text_l1) <= L1_CODE_LENGTH, "L1 text overflow!") 135 __text_l1_lma = LOADADDR(.text_l1);
136 __text_l1_len = SIZEOF(.text_l1);
137 ASSERT (__text_l1_len <= L1_CODE_LENGTH, "L1 text overflow!")
138 138
139 .data_l1 L1_DATA_A_START : AT(LOADADDR(.text_l1) + SIZEOF(.text_l1)) 139 .data_l1 L1_DATA_A_START : AT(__text_l1_lma + __text_l1_len)
140 { 140 {
141 . = ALIGN(4); 141 . = ALIGN(4);
142 __sdata_l1 = .; 142 __sdata_l1 = .;
@@ -152,9 +152,11 @@ SECTIONS
152 . = ALIGN(4); 152 . = ALIGN(4);
153 __ebss_l1 = .; 153 __ebss_l1 = .;
154 } 154 }
155 ASSERT (SIZEOF(.data_l1) <= L1_DATA_A_LENGTH, "L1 data A overflow!") 155 __data_l1_lma = LOADADDR(.data_l1);
156 __data_l1_len = SIZEOF(.data_l1);
157 ASSERT (__data_l1_len <= L1_DATA_A_LENGTH, "L1 data A overflow!")
156 158
157 .data_b_l1 L1_DATA_B_START : AT(LOADADDR(.data_l1) + SIZEOF(.data_l1)) 159 .data_b_l1 L1_DATA_B_START : AT(__data_l1_lma + __data_l1_len)
158 { 160 {
159 . = ALIGN(4); 161 . = ALIGN(4);
160 __sdata_b_l1 = .; 162 __sdata_b_l1 = .;
@@ -167,11 +169,11 @@ SECTIONS
167 . = ALIGN(4); 169 . = ALIGN(4);
168 __ebss_b_l1 = .; 170 __ebss_b_l1 = .;
169 } 171 }
170 ASSERT (SIZEOF(.data_b_l1) <= L1_DATA_B_LENGTH, "L1 data B overflow!") 172 __data_b_l1_lma = LOADADDR(.data_b_l1);
171 173 __data_b_l1_len = SIZEOF(.data_b_l1);
172 __l2_lma_start = LOADADDR(.data_b_l1) + SIZEOF(.data_b_l1); 174 ASSERT (__data_b_l1_len <= L1_DATA_B_LENGTH, "L1 data B overflow!")
173 175
174 .text_data_l2 L2_START : AT(LOADADDR(.data_b_l1) + SIZEOF(.data_b_l1)) 176 .text_data_l2 L2_START : AT(__data_b_l1_lma + __data_b_l1_len)
175 { 177 {
176 . = ALIGN(4); 178 . = ALIGN(4);
177 __stext_l2 = .; 179 __stext_l2 = .;
@@ -193,12 +195,14 @@ SECTIONS
193 . = ALIGN(4); 195 . = ALIGN(4);
194 __ebss_l2 = .; 196 __ebss_l2 = .;
195 } 197 }
196 ASSERT (SIZEOF(.text_data_l2) <= L2_LENGTH, "L2 overflow!") 198 __l2_lma = LOADADDR(.text_data_l2);
199 __l2_len = SIZEOF(.text_data_l2);
200 ASSERT (__l2_len <= L2_LENGTH, "L2 overflow!")
197 201
198 /* Force trailing alignment of our init section so that when we 202 /* Force trailing alignment of our init section so that when we
199 * free our init memory, we don't leave behind a partial page. 203 * free our init memory, we don't leave behind a partial page.
200 */ 204 */
201 . = LOADADDR(.text_data_l2) + SIZEOF(.text_data_l2); 205 . = __l2_lma + __l2_len;
202 . = ALIGN(PAGE_SIZE); 206 . = ALIGN(PAGE_SIZE);
203 ___init_end = .; 207 ___init_end = .;
204 208