From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933652AbdKCRNB (ORCPT ); Fri, 3 Nov 2017 13:13:01 -0400 Received: from mail-io0-f193.google.com ([209.85.223.193]:43980 "EHLO mail-io0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933563AbdKCRM6 (ORCPT ); Fri, 3 Nov 2017 13:12:58 -0400 X-Google-Smtp-Source: ABhQp+Tm1jKB+bKQ/FJM8+0Ry6jeWpyOQo2gxhObLcPlwLqJW8k6RRUYb+85KSLAB76N3vWjNApoBw== From: Sami Tolvanen To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Greg Hackmann , Kees Cook , Matthias Kaehlcke , Nick Desaulniers , Sami Tolvanen Subject: [PATCH 11/15] arm64: explicitly pass --no-fix-cortex-a53-843419 to GNU gold Date: Fri, 3 Nov 2017 10:11:56 -0700 Message-Id: <20171103171203.107569-13-samitolvanen@google.com> X-Mailer: git-send-email 2.15.0.403.gc27cc4dac6-goog In-Reply-To: <20171103171203.107569-1-samitolvanen@google.com> References: <20171103171203.107569-1-samitolvanen@google.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Some versions of GNU gold are known to produce broken code with --fix-cortex-a53-843419 as explained in this bug: https://sourceware.org/bugzilla/show_bug.cgi?id=21491 If ARM64_ERRATUM_843419 is disabled and we're using GNU gold, pass --no-fix-cortex-a53-843419 to the linker to ensure the erratum fix is not used even if the linker is configured to enable it by default. Signed-off-by: Sami Tolvanen --- arch/arm64/Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index c16bd1ab37f8..0c1fb297c98e 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -26,6 +26,11 @@ LDFLAGS_vmlinux += --fix-cortex-a53-843419 endif endif +ifeq ($(CONFIG_ARM64_ERRATUM_843419),) +# https://sourceware.org/bugzilla/show_bug.cgi?id=21491 +LDFLAGS_GOLD += --no-fix-cortex-a53-843419 +endif + KBUILD_DEFCONFIG := defconfig # Check for binutils support for specific extensions -- 2.15.0.403.gc27cc4dac6-goog