Skip to content

Commit

Permalink
BACKPORT: arm64: add a workaround for GNU gold with ARM64_MODULE_PLTS
Browse files Browse the repository at this point in the history
All current versions of GNU gold crash when linking kernel modules
with ARM64_MODULE_PLTS due to a known bug:

  https://sourceware.org/bugzilla/show_bug.cgi?id=14592

To work around the problem, this change removes NOLOAD from .plt
and .init.plt.

Bug: 62093296
Bug: 67506682
Change-Id: Ie59c15dc2e60859361b5c7dac5a515eabf8bb005
(am from https://patchwork.kernel.org/patch/10085781/)
Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
(cherry picked from commit 331f1f5c7b05132e71232e33eba32b57d1683afc)
Signed-off-by: Dan Aloni <daloni@magicleap.com>
Signed-off-by: Davide Garberi <dade.garberi@gmail.com>
  • Loading branch information
samitolvanen authored and Flamefire committed Apr 30, 2024
1 parent 440068b commit 1feaf5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm64/kernel/module.lds
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SECTIONS {
.plt (NOLOAD) : { BYTE(0) }
.plt : { BYTE(0) }
}

0 comments on commit 1feaf5b

Please sign in to comment.