]> git.ipfire.org Git - thirdparty/grub.git/commit
arm: Move trampolines into code section
authorAlexander Graf <agraf@csgraf.de>
Tue, 30 Apr 2019 20:43:56 +0000 (22:43 +0200)
committerDaniel Kiper <daniel.kiper@oracle.com>
Mon, 6 May 2019 10:10:27 +0000 (12:10 +0200)
commit1ce93f944df0a71439a996076f2bee8c496af89d
tree5888bdf5edc7bbef01df80a0302d44c36bf668f5
parent4dd4ceec023111a4ccf69f8de6fa0885c6847a35
arm: Move trampolines into code section

When creating T32->A32 transition jumps, the relocation code in grub
will generate trampolines. These trampolines live in the .data section
of our PE binary which means they are not marked as executable.

This misbehavior was unmasked by commit a51f953f4ee87 ("mkimage: Align
efi sections on 4k boundary") which made the X/NX boundary more obvious
because everything became page aligned.

To put things into proper order, let's move the arm trampolines into the
.text section instead. That way everyone knows they are executable.

Fixes: a51f953f4ee87 ("mkimage: Align efi sections on 4k boundary")
Reported-by: Julien ROBIN <julien.robin28@free.fr>
Reported-by: Leif Lindholm <leif.lindholm@linaro.org>
Signed-off-by: Alexander Graf <agraf@csgraf.de>
Tested-by: Julien ROBIN <julien.robin28@free.fr>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
Tested-by: Leif Lindholm <leif.lindholm@linaro.org>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
util/grub-mkimagexx.c