Bladeren bron

arm: fix linker script for building efi binaries

On arm, the linker script is missing section collection for data and
bss.  This causes some symbols (notably static array symbols) not to
get relocated correctly and the resulting efi binary to crash.  Fix
this by correctly collecting all the data and bss sections.

Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: Nigel Croxon <nigel.croxon@hpe.com>
Nigel Croxon 9 jaren geleden
bovenliggende
commit
06db4a2b53
1 gewijzigde bestanden met toevoegingen van 2 en 1 verwijderingen
  1. 2 1
      gnuefi/elf_arm_efi.lds

+ 2 - 1
gnuefi/elf_arm_efi.lds

@@ -22,7 +22,7 @@ SECTIONS
    *(.sdata)
    *(.data)
    *(.data1)
-   *(.data)
+   *(.data.*)
    *(.got.plt)
    *(.got)
 
@@ -34,6 +34,7 @@ SECTIONS
    *(.scommon)
    *(.dynbss)
    *(.bss)
+   *(.bss.*)
    *(COMMON)
    . = ALIGN(16);
    _bss_end = .;