summaryrefslogtreecommitdiff
path: root/arch/x86/entry/vdso/common/Makefile.include
AgeCommit message (Collapse)Author
2026-01-16x86/entry/vdso: Fix filtering of vdso compiler flagsH. Peter Anvin
This fixes several typos in the filtering of compiler flags for vdso, discovered by Chris Mason using an AI script: 1. "-fno-PIE" was written as "fno-PIE". 2. "CC_PLUGINS_FLAGS" was written as "CC_PLUGIN_FLAGS" To the best of my knowledge, none of these actually had any real impact on the build at this time but they are genuine bugs which could break things at any point in the future. Chris's script also found that "CONFIG_X86_USER_SHADOW_STACK" was missing "CONFIG_", but it needs a different fix. [ dhansen: remove CONFIG_X86_USER_SHADOW_STACK munging, add mention in changelog. ] Closes: https://lore.kernel.org/20260116035807.2307742-1-clm@meta.com Fixes: 693c819fedcd ("x86/entry/vdso: Refactor the vdso build") Reported-by: Chris Mason <clm@meta.com> Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Link: https://patch.msgid.link/20260116204057.386268-3-hpa@zytor.com
2026-01-13x86/entry/vdso: Refactor the vdso buildH. Peter Anvin
- Separate out the vdso sources into common, vdso32, and vdso64 directories. - Build the 32- and 64-bit vdsos in their respective subdirectories; this greatly simplifies the build flags handling. - Unify the mangling of Makefile flags between the 32- and 64-bit vdso code as much as possible; all common rules are put in arch/x86/entry/vdso/common/Makefile.include. The remaining is very simple for 32 bits; the 64-bit one is only slightly more complicated because it contains the x32 generation rule. - Define __DISABLE_EXPORTS when building the vdso. This need seems to have been masked by different ordering compile flags before. - Change CONFIG_X86_64 to BUILD_VDSO32_64 in vdso32/system_call.S, to make it compatible with including fake_32bit_build.h. - The -fcf-protection= option was "leaking" from the kernel build, for reasons that was not clear to me. Furthermore, several distributions ship with it set to a default value other than "-fcf-protection=none". Make it match the configuration options for *user space*. Note that this patch may seem large, but the vast majority of it is simply code movement. Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Link: https://patch.msgid.link/20251216212606.1325678-4-hpa@zytor.com