From: Thomas Weißschuh Date: Tue, 28 Oct 2025 09:15:37 +0000 (+0100) Subject: x86/um: Move ELF_PLATFORM fallback to x86-specific code X-Git-Tag: v6.19-rc1~104^2~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c1b077515116dc7916dbf72d8803a682c5989aa6;p=thirdparty%2Flinux.git x86/um: Move ELF_PLATFORM fallback to x86-specific code The generic UM code should not have references to x86-specific value. Move the fallback into the x86-specific header. Signed-off-by: Thomas Weißschuh Link: https://patch.msgid.link/20251028-uml-remove-32bit-pseudo-vdso-v1-2-e930063eff5f@weissschuh.net Signed-off-by: Johannes Berg --- diff --git a/arch/um/os-Linux/elf_aux.c b/arch/um/os-Linux/elf_aux.c index a62fe39e85c90..4aadb9ea5ae3a 100644 --- a/arch/um/os-Linux/elf_aux.c +++ b/arch/um/os-Linux/elf_aux.c @@ -71,7 +71,4 @@ __init void scan_elf_aux( char **envp) else { vsyscall_end = vsyscall_ehdr + page_size; } - - if (!elf_aux_platform) - elf_aux_platform = "i586"; } diff --git a/arch/x86/um/asm/elf.h b/arch/x86/um/asm/elf.h index 62ed5d68a9788..e7a045e014718 100644 --- a/arch/x86/um/asm/elf.h +++ b/arch/x86/um/asm/elf.h @@ -69,7 +69,8 @@ } while (0); extern char * elf_aux_platform; -#define ELF_PLATFORM (elf_aux_platform) +#define ELF_PLATFORM_FALLBACK "i586" +#define ELF_PLATFORM (elf_aux_platform ?: ELF_PLATFORM_FALLBACK) extern unsigned long vsyscall_ehdr; extern unsigned long vsyscall_end;