[U-Boot-Users] [PATCH 2/5][MIPS] u-boot.lds: Fix __got_start and __got_end

Shinya Kuribayashi skuribay at ruby.dti.ne.jp
Sat Oct 20 17:42:16 CEST 2007


From: Shinya Kuribayashi <shinya.kuribayashi at necel.com>

Ensure that __got_start points to top of the `.got', and __got_end points
to bottom as well, so that we never fail to count num_got_entries.

Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi at necel.com>
---

 board/dbau1x00/u-boot.lds |    8 +++++---
 board/gth2/u-boot.lds     |    8 +++++---
 board/incaip/u-boot.lds   |    8 +++++---
 board/pb1x00/u-boot.lds   |    8 +++++---
 board/purple/u-boot.lds   |    8 +++++---
 board/tb0229/u-boot.lds   |    8 +++++---
 examples/mips.lds         |    8 +++++---
 7 files changed, 35 insertions(+), 21 deletions(-)

diff --git a/board/dbau1x00/u-boot.lds b/board/dbau1x00/u-boot.lds
index 75a3af6..9c71ef7 100644
--- a/board/dbau1x00/u-boot.lds
+++ b/board/dbau1x00/u-boot.lds
@@ -45,9 +45,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/board/gth2/u-boot.lds b/board/gth2/u-boot.lds
index 69c8c9d..0ab42db 100644
--- a/board/gth2/u-boot.lds
+++ b/board/gth2/u-boot.lds
@@ -45,9 +45,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/board/incaip/u-boot.lds b/board/incaip/u-boot.lds
index 75a3af6..9c71ef7 100644
--- a/board/incaip/u-boot.lds
+++ b/board/incaip/u-boot.lds
@@ -45,9 +45,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/board/pb1x00/u-boot.lds b/board/pb1x00/u-boot.lds
index 865be77..7329e6a 100644
--- a/board/pb1x00/u-boot.lds
+++ b/board/pb1x00/u-boot.lds
@@ -45,9 +45,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/board/purple/u-boot.lds b/board/purple/u-boot.lds
index 6b3783f..aa51cbf 100644
--- a/board/purple/u-boot.lds
+++ b/board/purple/u-boot.lds
@@ -55,9 +55,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/board/tb0229/u-boot.lds b/board/tb0229/u-boot.lds
index 26d8c81..148f5e6 100644
--- a/board/tb0229/u-boot.lds
+++ b/board/tb0229/u-boot.lds
@@ -45,9 +45,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 
diff --git a/examples/mips.lds b/examples/mips.lds
index 6f31eb7..3bd573c 100644
--- a/examples/mips.lds
+++ b/examples/mips.lds
@@ -41,9 +41,11 @@ SECTIONS
 
 	_gp = ALIGN(16);
 
-	__got_start = .;
-	.got  : { *(.got) }
-	__got_end = .;
+	.got : {
+	  __got_start = .;
+	  *(.got)
+	  __got_end = .;
+	}
 
 	.sdata  : { *(.sdata) }
 





More information about the U-Boot mailing list