summaryrefslogtreecommitdiff
path: root/arch/arm/cpu
diff options
context:
space:
mode:
authorPo-Yu Chuang <ratbert@faraday-tech.com>2011-03-01 23:02:04 +0000
committerAlbert Aribaud <albert.aribaud@free.fr>2011-03-27 19:18:52 +0200
commitf326cbba98bae21d41df8daac0bd78121d557af1 (patch)
treef22e894ede1e38fd6d048367ba50d4c539860b1e /arch/arm/cpu
parent44c6e6591cb451ae606f8bde71dd5fb7b4002544 (diff)
arm: fix incorrect monitor protection region in FLASH
Monitor protection region in FLASH did not cover .rel.dyn and .dynsym sections, because it uses __bss_start to compute monitor_flash_len. Use _end instead. Add _end to linker scripts for end of u-boot image Add _end_ofs to all the start.S. Signed-off-by: Po-Yu Chuang <ratbert@faraday-tech.com>
Diffstat (limited to 'arch/arm/cpu')
-rw-r--r--arch/arm/cpu/arm1136/start.S4
-rw-r--r--arch/arm/cpu/arm1136/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm1176/start.S4
-rw-r--r--arch/arm/cpu/arm1176/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm720t/start.S4
-rw-r--r--arch/arm/cpu/arm720t/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm920t/ep93xx/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm920t/start.S4
-rw-r--r--arch/arm/cpu/arm920t/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm925t/start.S4
-rw-r--r--arch/arm/cpu/arm925t/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm926ejs/start.S4
-rw-r--r--arch/arm/cpu/arm926ejs/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm946es/start.S4
-rw-r--r--arch/arm/cpu/arm946es/u-boot.lds2
-rw-r--r--arch/arm/cpu/arm_intcm/start.S4
-rw-r--r--arch/arm/cpu/arm_intcm/u-boot.lds2
-rw-r--r--arch/arm/cpu/armv7/start.S4
-rw-r--r--arch/arm/cpu/armv7/u-boot.lds2
-rw-r--r--arch/arm/cpu/ixp/start.S4
-rw-r--r--arch/arm/cpu/ixp/u-boot.lds2
-rw-r--r--arch/arm/cpu/lh7a40x/start.S4
-rw-r--r--arch/arm/cpu/lh7a40x/u-boot.lds2
-rw-r--r--arch/arm/cpu/pxa/start.S4
-rw-r--r--arch/arm/cpu/pxa/u-boot.lds2
-rw-r--r--arch/arm/cpu/s3c44b0/start.S4
-rw-r--r--arch/arm/cpu/s3c44b0/u-boot.lds2
-rw-r--r--arch/arm/cpu/sa1100/start.S4
-rw-r--r--arch/arm/cpu/sa1100/u-boot.lds2
29 files changed, 86 insertions, 0 deletions
diff --git a/arch/arm/cpu/arm1136/start.S b/arch/arm/cpu/arm1136/start.S
index 64426fa2a84..3c5f3ef5fab 100644
--- a/arch/arm/cpu/arm1136/start.S
+++ b/arch/arm/cpu/arm1136/start.S
@@ -104,6 +104,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm1136/u-boot.lds b/arch/arm/cpu/arm1136/u-boot.lds
index 1e0e90b4afe..d1e28518ad8 100644
--- a/arch/arm/cpu/arm1136/u-boot.lds
+++ b/arch/arm/cpu/arm1136/u-boot.lds
@@ -72,6 +72,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm1176/start.S b/arch/arm/cpu/arm1176/start.S
index c1302df6535..6ae118ac45a 100644
--- a/arch/arm/cpu/arm1176/start.S
+++ b/arch/arm/cpu/arm1176/start.S
@@ -123,6 +123,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
/* IRQ stack memory (calculated at run-time) + 8 bytes */
.globl IRQ_STACK_START_IN
IRQ_STACK_START_IN:
diff --git a/arch/arm/cpu/arm1176/u-boot.lds b/arch/arm/cpu/arm1176/u-boot.lds
index 170e5165508..27d66380bdf 100644
--- a/arch/arm/cpu/arm1176/u-boot.lds
+++ b/arch/arm/cpu/arm1176/u-boot.lds
@@ -61,6 +61,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm720t/start.S b/arch/arm/cpu/arm720t/start.S
index c521753f3bb..e774c3ff678 100644
--- a/arch/arm/cpu/arm720t/start.S
+++ b/arch/arm/cpu/arm720t/start.S
@@ -93,6 +93,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm720t/u-boot.lds b/arch/arm/cpu/arm720t/u-boot.lds
index deda9fb0db1..9370fadcf5c 100644
--- a/arch/arm/cpu/arm720t/u-boot.lds
+++ b/arch/arm/cpu/arm720t/u-boot.lds
@@ -62,6 +62,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm920t/ep93xx/u-boot.lds b/arch/arm/cpu/arm920t/ep93xx/u-boot.lds
index 4cc82a54b18..dc6ba34082e 100644
--- a/arch/arm/cpu/arm920t/ep93xx/u-boot.lds
+++ b/arch/arm/cpu/arm920t/ep93xx/u-boot.lds
@@ -56,4 +56,6 @@ SECTIONS
__bss_start = .;
.bss : { *(.bss) }
__bss_end__ = .;
+
+ _end = .;
}
diff --git a/arch/arm/cpu/arm920t/start.S b/arch/arm/cpu/arm920t/start.S
index 6db61c215c5..a7476b0550b 100644
--- a/arch/arm/cpu/arm920t/start.S
+++ b/arch/arm/cpu/arm920t/start.S
@@ -89,6 +89,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm920t/u-boot.lds b/arch/arm/cpu/arm920t/u-boot.lds
index d6dc21c55dd..17ba60423ba 100644
--- a/arch/arm/cpu/arm920t/u-boot.lds
+++ b/arch/arm/cpu/arm920t/u-boot.lds
@@ -71,6 +71,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm925t/start.S b/arch/arm/cpu/arm925t/start.S
index b89cf4ae813..39f2e997d29 100644
--- a/arch/arm/cpu/arm925t/start.S
+++ b/arch/arm/cpu/arm925t/start.S
@@ -99,6 +99,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm925t/u-boot.lds b/arch/arm/cpu/arm925t/u-boot.lds
index 4ad1f8ed075..64e76f55e36 100644
--- a/arch/arm/cpu/arm925t/u-boot.lds
+++ b/arch/arm/cpu/arm925t/u-boot.lds
@@ -66,6 +66,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm926ejs/start.S b/arch/arm/cpu/arm926ejs/start.S
index 7798ef82a9e..fefcfa2f886 100644
--- a/arch/arm/cpu/arm926ejs/start.S
+++ b/arch/arm/cpu/arm926ejs/start.S
@@ -133,6 +133,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm926ejs/u-boot.lds b/arch/arm/cpu/arm926ejs/u-boot.lds
index b7a5b9e66f0..1480e0c960f 100644
--- a/arch/arm/cpu/arm926ejs/u-boot.lds
+++ b/arch/arm/cpu/arm926ejs/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm946es/start.S b/arch/arm/cpu/arm946es/start.S
index 1b6b188516c..00914f42e9c 100644
--- a/arch/arm/cpu/arm946es/start.S
+++ b/arch/arm/cpu/arm946es/start.S
@@ -105,6 +105,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm946es/u-boot.lds b/arch/arm/cpu/arm946es/u-boot.lds
index fe4a646dfdd..ff938e44d8f 100644
--- a/arch/arm/cpu/arm946es/u-boot.lds
+++ b/arch/arm/cpu/arm946es/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/arm_intcm/start.S b/arch/arm/cpu/arm_intcm/start.S
index da2c265fcbb..2fd3b9a05a3 100644
--- a/arch/arm/cpu/arm_intcm/start.S
+++ b/arch/arm/cpu/arm_intcm/start.S
@@ -101,6 +101,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/arm_intcm/u-boot.lds b/arch/arm/cpu/arm_intcm/u-boot.lds
index 899fab06ff7..f4a146c9a81 100644
--- a/arch/arm/cpu/arm_intcm/u-boot.lds
+++ b/arch/arm/cpu/arm_intcm/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/armv7/start.S b/arch/arm/cpu/armv7/start.S
index bc7bae85c02..d83d5018379 100644
--- a/arch/arm/cpu/armv7/start.S
+++ b/arch/arm/cpu/armv7/start.S
@@ -81,6 +81,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/armv7/u-boot.lds b/arch/arm/cpu/armv7/u-boot.lds
index de8024459dd..dbae54d4f8a 100644
--- a/arch/arm/cpu/armv7/u-boot.lds
+++ b/arch/arm/cpu/armv7/u-boot.lds
@@ -66,6 +66,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/ixp/start.S b/arch/arm/cpu/ixp/start.S
index f8bfed7cc61..561c1f4795d 100644
--- a/arch/arm/cpu/ixp/start.S
+++ b/arch/arm/cpu/ixp/start.S
@@ -112,6 +112,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/ixp/u-boot.lds b/arch/arm/cpu/ixp/u-boot.lds
index 7029c6c7d9c..3587f8aa6be 100644
--- a/arch/arm/cpu/ixp/u-boot.lds
+++ b/arch/arm/cpu/ixp/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/lh7a40x/start.S b/arch/arm/cpu/lh7a40x/start.S
index bd821a270d9..81242b1ed48 100644
--- a/arch/arm/cpu/lh7a40x/start.S
+++ b/arch/arm/cpu/lh7a40x/start.S
@@ -89,6 +89,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/lh7a40x/u-boot.lds b/arch/arm/cpu/lh7a40x/u-boot.lds
index b15ab1e572c..30934ff3e3d 100644
--- a/arch/arm/cpu/lh7a40x/u-boot.lds
+++ b/arch/arm/cpu/lh7a40x/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/pxa/start.S b/arch/arm/cpu/pxa/start.S
index ca072c47449..f1dbc3b35d6 100644
--- a/arch/arm/cpu/pxa/start.S
+++ b/arch/arm/cpu/pxa/start.S
@@ -106,6 +106,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/pxa/u-boot.lds b/arch/arm/cpu/pxa/u-boot.lds
index dfb9b77535b..e163369bc34 100644
--- a/arch/arm/cpu/pxa/u-boot.lds
+++ b/arch/arm/cpu/pxa/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/s3c44b0/start.S b/arch/arm/cpu/s3c44b0/start.S
index ac1c4fb58e6..10f5284d457 100644
--- a/arch/arm/cpu/s3c44b0/start.S
+++ b/arch/arm/cpu/s3c44b0/start.S
@@ -80,6 +80,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/s3c44b0/u-boot.lds b/arch/arm/cpu/s3c44b0/u-boot.lds
index 797edbc9438..74a259c0d57 100644
--- a/arch/arm/cpu/s3c44b0/u-boot.lds
+++ b/arch/arm/cpu/s3c44b0/u-boot.lds
@@ -63,6 +63,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)
diff --git a/arch/arm/cpu/sa1100/start.S b/arch/arm/cpu/sa1100/start.S
index 5cfe19bcc59..b27e9701528 100644
--- a/arch/arm/cpu/sa1100/start.S
+++ b/arch/arm/cpu/sa1100/start.S
@@ -90,6 +90,10 @@ _bss_start_ofs:
_bss_end_ofs:
.word __bss_end__ - _start
+.globl _end_ofs
+_end_ofs:
+ .word _end - _start
+
#ifdef CONFIG_USE_IRQ
/* IRQ stack memory (calculated at run-time) */
.globl IRQ_STACK_START
diff --git a/arch/arm/cpu/sa1100/u-boot.lds b/arch/arm/cpu/sa1100/u-boot.lds
index 0ac13296b91..e6381dacf6d 100644
--- a/arch/arm/cpu/sa1100/u-boot.lds
+++ b/arch/arm/cpu/sa1100/u-boot.lds
@@ -66,6 +66,8 @@ SECTIONS
*(.dynsym)
}
+ _end = .;
+
.bss __rel_dyn_start (OVERLAY) : {
__bss_start = .;
*(.bss)