mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 10:11:27 +01:00
xen: introduce DECL_SECTION_WITH_LADDR
Introduce DECL_SECTION_WITH_LADDR in order to signal whether
DECL_SECTION() should specify a load address or not.
Update {ppc,x86}/xen.lds.S to use DECL_SECTION_WITH_LADDR.
Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
1 parent
542ac112fc
commit
17d32cf2ec
3 files changed
+12
-2
No files matched your search
@@ -1,4 +1,6 @@
|
||||
#include <xen/lib.h>
|
||||
|
||||
#define DECL_SECTION_WITH_LADDR
|
||||
#include <xen/xen.lds.h>
|
||||
|
||||
OUTPUT_ARCH(powerpc:common64)
|
||||
|
||||
@@ -3,6 +3,10 @@
|
||||
|
||||
#include <xen/cache.h>
|
||||
#include <xen/lib.h>
|
||||
|
||||
#ifndef EFI
|
||||
# define DECL_SECTION_WITH_LADDR
|
||||
#endif
|
||||
#include <xen/xen.lds.h>
|
||||
#include <asm/page.h>
|
||||
|
||||
@@ -10,9 +14,7 @@
|
||||
|
||||
#define FORMAT "pei-x86-64"
|
||||
#undef __XEN_VIRT_START
|
||||
#undef DECL_SECTION
|
||||
#define __XEN_VIRT_START __image_base__
|
||||
#define DECL_SECTION(x) x :
|
||||
|
||||
ENTRY(efi_start)
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
* Common macros to be used in architecture specific linker scripts.
|
||||
*/
|
||||
|
||||
#ifdef DECL_SECTION_WITH_LADDR
|
||||
|
||||
/*
|
||||
* Declare a section whose load address is based at PA 0 rather than
|
||||
* Xen's virtual base address.
|
||||
@@ -15,6 +17,10 @@
|
||||
# define DECL_SECTION(x) x : AT(ADDR(x) - __XEN_VIRT_START)
|
||||
#endif
|
||||
|
||||
#else /* !DECL_SECTION_WITH_LADDR */
|
||||
#define DECL_SECTION(x) x :
|
||||
#endif
|
||||
|
||||
/*
|
||||
* To avoid any confusion, please note that the EFI macro does not correspond
|
||||
* to EFI support and is used when linking a native EFI (i.e. PE/COFF) binary,
|
||||
|
||||