linux/arch/x86/xen
Ard Biesheuvel 223abe96ac x86/xen: Avoid relocatable quantities in Xen ELF notes
Xen puts virtual and physical addresses into ELF notes that are treated
by the linker as relocatable by default. Doing so is not only pointless,
given that the ELF notes are only intended for consumption by Xen before
the kernel boots. It is also a KASLR leak, given that the kernel's ELF
notes are exposed via the world readable /sys/kernel/notes.

So emit these constants in a way that prevents the linker from marking
them as relocatable. This involves place-relative relocations (which
subtract their own virtual address from the symbol value) and linker
provided absolute symbols that add the address of the place to the
desired value.

Tested-by: Jason Andryuk <jason.andryuk@amd.com>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Jason Andryuk <jason.andryuk@amd.com>
Message-ID: <20241009160438.3884381-11-ardb+git@google.com>
Signed-off-by: Juergen Gross <jgross@suse.com>
2024-10-29 17:23:36 +01:00
..
apic.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
debugfs.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
efi.c xen/efi: refactor deprecated strncpy 2023-09-19 07:04:49 +02:00
enlighten_hvm.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
enlighten_pv.c x86/xen: mark boot CPU of PV guest in MSR_IA32_APICBASE 2024-10-08 16:18:57 +02:00
enlighten_pvh.c xen/pvh: Setup gsi for passthrough device 2024-09-25 09:54:52 +02:00
enlighten.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
grant-table.c
irq.c x86/paravirt: Move some functions and defines to alternative.c 2023-12-10 20:30:31 +01:00
Kconfig treewide: replace or remove redundant def_bool in Kconfig files 2024-02-20 20:47:45 +09:00
Makefile
mmu_hvm.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
mmu_pv.c ALong with the usual shower of singleton patches, notable patch series in 2024-09-21 07:29:05 -07:00
mmu.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
multicalls.c xen: fix multicall debug data referencing 2024-07-23 12:23:20 +02:00
p2m.c xen: allow mapping ACPI data using a different physical address 2024-09-12 08:25:07 +02:00
platform-pci-unplug.c
pmu.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
setup.c xen: tolerate ACPI NVS memory overlapping with Xen allocated memory 2024-09-12 08:25:12 +02:00
smp_hvm.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
smp_pv.c xen: fix multicall debug data referencing 2024-07-23 12:23:20 +02:00
smp.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
spinlock.c x86/xen: remove deprecated xen_nopvspin boot parameter 2024-07-11 16:33:51 +02:00
suspend_hvm.c
suspend_pv.c
suspend.c x86/xen: eliminate some private header files 2024-07-11 16:33:48 +02:00
time.c x86/xen/time: Reduce Xen timer tick 2024-07-02 09:35:52 +02:00
trace.c
vga.c x86: Do not include <asm/bootparam.h> in several files 2024-01-30 15:17:24 +01:00
xen-asm.S Linux 6.8-rc4 2024-02-14 10:45:07 +01:00
xen-head.S x86/xen: Avoid relocatable quantities in Xen ELF notes 2024-10-29 17:23:36 +01:00
xen-ops.h xen: add capability to remap non-RAM pages to different PFNs 2024-09-10 15:26:34 +02:00