|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [PATCH 4/6] x86/efi: discard multiboot related entry code for PE binary
From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
The multiboot and PVH entry points are not used in the PE binary, hence
discard them in the linker script when doing a PE build.
That removes some relocations that otherwise appear due to the entry point
code in head.S not being position independent.
No functional change intended.
Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
---
xen/arch/x86/boot/head.S | 3 ++-
xen/arch/x86/xen.lds.S | 2 ++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/xen/arch/x86/boot/head.S b/xen/arch/x86/boot/head.S
index 77bb7a9e21..90faf411b9 100644
--- a/xen/arch/x86/boot/head.S
+++ b/xen/arch/x86/boot/head.S
@@ -152,7 +152,7 @@ vga_text_buffer:
efi_platform:
.byte 0
- .section .init.text, "ax", @progbits
+ .section .init.multiboot, "ax", @progbits
early_error: /* Here to improve the disassembly. */
@@ -710,6 +710,7 @@ trampoline_setup:
/* Jump into the relocated trampoline. */
lret
+ .section .init.text, "ax", @progbits
ENTRY(trampoline_start)
#include "trampoline.S"
ENTRY(trampoline_end)
diff --git a/xen/arch/x86/xen.lds.S b/xen/arch/x86/xen.lds.S
index 907f826ae0..a5a85e9b8a 100644
--- a/xen/arch/x86/xen.lds.S
+++ b/xen/arch/x86/xen.lds.S
@@ -59,6 +59,7 @@ SECTIONS
. = __image_base__;
/DISCARD/ : {
*(.text.header)
+ *(.init.multiboot)
}
#endif
@@ -200,6 +201,7 @@ SECTIONS
_sinittext = .;
*(.init.text)
*(.text.startup)
+ *(.init.multiboot)
_einittext = .;
/*
* Here are the replacement instructions. The linker sticks them
--
2.43.0
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |