[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[xen stable-4.21] x86/efi: Explicitly set NX_COMPAT on xen.efi



commit eeea3d1dbc937b949e583b3f74994cbbeb446090
Author:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Thu Nov 26 17:49:40 2026 +0100
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Thu Nov 26 17:49:40 2026 +0100

    x86/efi: Explicitly set NX_COMPAT on xen.efi
    
    Binutils between 2.36 and 2.44 set NX_COMPAT by default.  Outside of this
    range, programs have to ask for it explicitly.
    
    Xen is NX_COMPAT-able; Xen does not execute from it's stack at all.  The
    property is mandated by the Microsoft UEFI signing requirements.
    
    The --nxcompat option is available since binutils 2.20 and llvm 6, so can be
    used unconditionally given our toolchain baseline.
    
    Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
    master commit: f460efb764c694304573d1a555477638d8c34f25
    master date: 2026-11-25 14:20:22 +0000
---
 xen/arch/x86/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/xen/arch/x86/Makefile b/xen/arch/x86/Makefile
index 269a1a3acb..dad75d9a8e 100644
--- a/xen/arch/x86/Makefile
+++ b/xen/arch/x86/Makefile
@@ -170,6 +170,7 @@ EFI_LDFLAGS += --major-image-version=$(XEN_VERSION)
 EFI_LDFLAGS += --minor-image-version=$(XEN_SUBVERSION)
 EFI_LDFLAGS += --major-os-version=2 --minor-os-version=0
 EFI_LDFLAGS += --major-subsystem-version=2 --minor-subsystem-version=0
+EFI_LDFLAGS += --nxcompat
 # It seems ld unfortunately can't set a custom timestamp, so add a zero value
 # for the timestamp (option --no-insert-timestamp) if SOURCE_DATE_EPOCH is
 # defined to make reproducible builds possible.
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.21



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.