lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Tue,  9 Feb 2021 19:07:49 -0500
From:   Tong Zhang <ztong0001@...il.com>
To:     Andy Lutomirski <luto@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        x86@...nel.org, "H. Peter Anvin" <hpa@...or.com>,
        linux-kernel@...r.kernel.org
Cc:     ztong0001@...il.com
Subject: [PATCH v1] x86/vdso: fix CE on non-compatible cflags

I am getting some compilation error on when using CONFIG_X86_32 kernel
configuration

arch/x86/entry/vdso/vdso32/../vclock_gettime.c:29:1:
 error: ‘-mindirect-branch’ and ‘-fcf-protection’ are not compatible

add -fcf-protection=none when CONFIG_RETPOLINE=y

Signed-off-by: Tong Zhang <ztong0001@...il.com>
---
 arch/x86/entry/vdso/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/x86/entry/vdso/Makefile b/arch/x86/entry/vdso/Makefile
index 02e3e42f380b..37885336b53f 100644
--- a/arch/x86/entry/vdso/Makefile
+++ b/arch/x86/entry/vdso/Makefile
@@ -159,6 +159,7 @@ KBUILD_CFLAGS_32 += -DDISABLE_BRANCH_PROFILING
 ifdef CONFIG_RETPOLINE
 ifneq ($(RETPOLINE_VDSO_CFLAGS),)
   KBUILD_CFLAGS_32 += $(RETPOLINE_VDSO_CFLAGS)
+  KBUILD_CFLAGS_32 += $(call cc-option,-fcf-protection=none)
 endif
 endif
 
-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ