Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp2142507imm; Mon, 28 May 2018 02:28:49 -0700 (PDT) X-Google-Smtp-Source: AB8JxZruDIsTCjerFBIQw8QKwBj24TbhzHDdsdtq7oCoLSPDI9WPjsGUktFuwxBmSAH3+9rHgJ8x X-Received: by 2002:a63:7c43:: with SMTP id l3-v6mr10155977pgn.0.1527499729395; Mon, 28 May 2018 02:28:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527499729; cv=none; d=google.com; s=arc-20160816; b=OZnAu1Vjo8K8gEeQnHbRKb7Y6S4P0IhxbJ+hEMhIiLyCaettwwcDHYzcLXRrJ+rFrb D+mdaKnQ6dObj/dbI41s0VZuvi/OOUE0seS+U6p8/UbN1P6mvtS4sZ7KRtnPbcnDhuEG Zwcot4DREbNHUFrW92voNu5jwXa7VEcQCnyGRn1BGdzf1QzwkDQk5uWfjpqd/p7wX6BI 7ESa/arivmPkXIgFYAK6mAwpOqdzVMFFBtw2KNelx7RIGKOEWndrxD/lSr9fZCnkooY4 jaj+4A/iGvLqgGJw+PjTDin31e+S5/p4acA3yftPQF5iSrzcox6tGI4HVgM0ITqZH33r RZnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter :arc-authentication-results; bh=K2pnM9k4Ir5ms5fvVd46T5nd2LcbxCSfCNHsU2G0jPI=; b=SSaEH8yBZ6YxUxvAR9ERMdDXCDqklFMZlG8PiY/zHtU/bpwuUOS+V7tx5w8t8qP8K0 nct+5/JJpuO4cq7ePkSYJCtewQbNXRfkaC3v5ZwNVaQ+qr8ukGapUl/ZUvavwDVO5fMW tAlMLkbX5Uzbop5MsmLxKuBNe4CeirLEZ5u/5OtC8l2LA7zz3ILvjq9e49wwArRQbGO6 8LQ5HN7OAtMjs02CSiMWNENHjz6bEa8+vWoqR2ry8/EnbuUeWS3X2p8qmNEBpjbDb2QI WrPOEb3kWbIp02xsLqPAL9fE70bBZOKuzSJt6XlmVaeOnS7x72iUcGsnqvIRulxmQPUy IpHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=P6DMGZ9/; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c10-v6si10587448plz.190.2018.05.28.02.28.35; Mon, 28 May 2018 02:28:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=P6DMGZ9/; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933374AbeE1J0u (ORCPT + 99 others); Mon, 28 May 2018 05:26:50 -0400 Received: from conuserg-10.nifty.com ([210.131.2.77]:21964 "EHLO conuserg-10.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932146AbeE1JY2 (ORCPT ); Mon, 28 May 2018 05:24:28 -0400 Received: from grover.sesame (FL1-125-199-20-195.osk.mesh.ad.jp [125.199.20.195]) (authenticated) by conuserg-10.nifty.com with ESMTP id w4S9MInj027506; Mon, 28 May 2018 18:22:42 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-10.nifty.com w4S9MInj027506 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1527499362; bh=K2pnM9k4Ir5ms5fvVd46T5nd2LcbxCSfCNHsU2G0jPI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=P6DMGZ9/x2WuNVBCp3wwKsVlol9Owg9pp/x89/t4cFxaDC8m8q02stbgW5y1CjzHb sMci2jj68UfRWvErnvdxv0ZLFirlnkDJd2qU3BUkmGkfTIxkmRQFf9Mh9aftMyfgO6 t4IU1ZHW/TKBYr6Zp+E0P41RdnCCvFkmVn5rXtFzl9bJqFEZs2zX1TCR9JZHK8u031 ksldT2Lfrr6G7q70I3+zWD5v7b6ZLOBI4QGK1wXY+Fm/GqvaFMEbO3vo5zNTYjpa1d b77ReBts7qq/pK14j5fou6sWdq46+N9Lc3pPVor8cTgDXMr4jKs7tt0ASu3VTp1RXp DfacytbSLixDg== X-Nifty-SrcIP: [125.199.20.195] From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Kees Cook , Nicholas Piggin , "Luis R . Rodriguez" , Randy Dunlap , Ulf Magnusson , Sam Ravnborg , Linus Torvalds , Masahiro Yamada Subject: [PATCH v5 28/31] gcc-plugins: move GCC version check for PowerPC to Kconfig Date: Mon, 28 May 2018 18:22:05 +0900 Message-Id: <1527499328-13213-29-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1527499328-13213-1-git-send-email-yamada.masahiro@socionext.com> References: <1527499328-13213-1-git-send-email-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org For PowerPC, GCC 5.2 is the requirement for GCC plugins. Move the version check to Kconfig so that the GCC plugin menus will be hidden if an older compiler is in use. Signed-off-by: Masahiro Yamada Acked-by: Andrew Donnellan Reviewed-by: Kees Cook --- Changes in v5: None Changes in v4: None Changes in v3: - Move comment to Kconfig as well Changes in v2: None arch/powerpc/Kconfig | 2 +- scripts/Makefile.gcc-plugins | 8 -------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index c32a181..17e53e6 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -195,7 +195,7 @@ config PPC select HAVE_FTRACE_MCOUNT_RECORD select HAVE_FUNCTION_GRAPH_TRACER select HAVE_FUNCTION_TRACER - select HAVE_GCC_PLUGINS + select HAVE_GCC_PLUGINS if GCC_VERSION >= 50200 # plugin support on gcc <= 5.1 is buggy on PPC select HAVE_GENERIC_GUP select HAVE_HW_BREAKPOINT if PERF_EVENTS && (PPC_BOOK3S || PPC_8xx) select HAVE_IDE diff --git a/scripts/Makefile.gcc-plugins b/scripts/Makefile.gcc-plugins index 0ce3802..1e92353 100644 --- a/scripts/Makefile.gcc-plugins +++ b/scripts/Makefile.gcc-plugins @@ -53,14 +53,6 @@ gcc-plugins-check: FORCE ifdef CONFIG_GCC_PLUGINS ifeq ($(PLUGINCC),) ifneq ($(GCC_PLUGINS_CFLAGS),) - # Various gccs between 4.5 and 5.1 have bugs on powerpc due to missing - # header files. gcc <= 4.6 doesn't work at all, gccs from 4.8 to 5.1 have - # issues with 64-bit targets. - ifeq ($(ARCH),powerpc) - ifeq ($(call cc-ifversion, -le, 0501, y), y) - @echo "Cannot use CONFIG_GCC_PLUGINS: plugin support on gcc <= 5.1 is buggy on powerpc, please upgrade to gcc 5.2 or newer" >&2 && exit 1 - endif - endif ifeq ($(call cc-ifversion, -ge, 0405, y), y) $(Q)$(srctree)/scripts/gcc-plugin.sh --show-error "$(__PLUGINCC)" "$(HOSTCXX)" "$(CC)" || true @echo "Cannot use CONFIG_GCC_PLUGINS: your gcc installation does not support plugins, perhaps the necessary headers are missing?" >&2 && exit 1 -- 2.7.4