... to boot code, limiting their scope and thus allowing to drop
respective #undef-s from the linker script.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
An obvious alternative would be to convert boot code right away too, but
I think this has lower priority for now.
---
v7: Re-base.
v6: New.
--- a/xen/arch/x86/boot/head.S
+++ b/xen/arch/x86/boot/head.S
@@ -10,6 +10,15 @@
#include <asm/cpufeature.h>
#include <public/elfnote.h>
+#define ALIGN .align CONFIG_FUNCTION_ALIGNMENT, CODE_FILL
+#define ENTRY(name) \
+ ALIGN; \
+ GLOBAL(name)
+#define GLOBAL(name) \
+ .globl name; \
+ .hidden name; \
+ name:
+
.section .text.header, "ax", @progbits
.code32
--- a/xen/arch/x86/include/asm/config.h
+++ b/xen/arch/x86/include/asm/config.h
@@ -42,14 +42,6 @@
/* Linkage for x86 */
#ifdef __ASSEMBLY__
#define CODE_FILL 0x90
-#define ALIGN .align CONFIG_FUNCTION_ALIGNMENT, CODE_FILL
-#define ENTRY(name) \
- ALIGN; \
- GLOBAL(name)
-#define GLOBAL(name) \
- .globl name; \
- .hidden name; \
- name:
#endif
#define NR_hypercalls 64
--- a/xen/arch/x86/x86_64/entry.S
+++ b/xen/arch/x86/x86_64/entry.S
@@ -1260,7 +1260,7 @@ FUNC_LOCAL(autogen_stubs, 0) /* Automati
.if vec >= FIRST_IRQ_VECTOR
#endif
- ALIGN
+ .align CONFIG_FUNCTION_ALIGNMENT, CODE_FILL
1:
ENDBR64
pushq $0
--- a/xen/arch/x86/xen.lds.S
+++ b/xen/arch/x86/xen.lds.S
@@ -5,8 +5,6 @@
#include <xen/lib.h>
#include <xen/xen.lds.h>
#include <asm/page.h>
-#undef ENTRY
-#undef ALIGN
#ifdef EFI