]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - board/amirix/ap1000/u-boot.lds
powerpc, 8xx: Fixup all 8xx u-boot.lds scripts
[karo-tx-uboot.git] / board / amirix / ap1000 / u-boot.lds
index 57fe1d9ce0861397db3d28672c0d1a8322316877..cd8f5cebab5a6b88a82ede61525587f24d9cadf3 100644 (file)
@@ -49,13 +49,14 @@ SECTIONS
   PROVIDE (erotext = .);
   .reloc   :
   {
-    KEEP(*(.got))
     _GOT2_TABLE_ = .;
     KEEP(*(.got2))
+    KEEP(*(.got))
+    PROVIDE(_GLOBAL_OFFSET_TABLE_ = . + 4);
     _FIXUP_TABLE_ = .;
     KEEP(*(.fixup))
   }
-  __got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
+  __got2_entries = ((_GLOBAL_OFFSET_TABLE_ - _GOT2_TABLE_) >> 2) - 1;
   __fixup_entries = (. - _FIXUP_TABLE_)>>2;
 
   .data    :