From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 43E2DC433EF for ; Thu, 28 Oct 2021 01:32:49 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0E8C161108 for ; Thu, 28 Oct 2021 01:32:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 0E8C161108 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ChYt7pT9uZfq6+U/16skVjzDQqkNrCzauvo6lmNYB1w=; b=VpDK5ZUT6KCaod aEFy56bNBAiV4mlSWP4TmPExgoC1Txr30Xswp7DN2uz6IzxO5fdj0emZiXujQwlrE4UA4nQn235cg DSAKDdPWhT9vfKdPtY4r6o+qKzcD1Ko4IkMUCFbiSyKXMeqHLsJSCqPSalU9ErI4iJqv7yWVo2Srn FrPyvqrfeaqZl8y7cN02y0Tjakz31vf0evsJus1YR3+SdUvb6wXulEK3p4ffcRX6R6kLC+akNvNqg cf7hysmKI/5iluPfJgGTJ7avysMmulwEiF8PSjLobHivroDw4LzQAE6+QqrEBp/60ghFYoW8PS5ZA QEJEY3XXKkri36GjHcIQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mfuG9-006cbB-6G; Thu, 28 Oct 2021 01:31:13 +0000 Received: from mga07.intel.com ([134.134.136.100]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mfuG3-006cYL-Fc for linux-arm-kernel@lists.infradead.org; Thu, 28 Oct 2021 01:31:08 +0000 X-IronPort-AV: E=McAfee;i="6200,9189,10150"; a="293761980" X-IronPort-AV: E=Sophos;i="5.87,188,1631602800"; d="scan'208";a="293761980" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Oct 2021 18:31:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.87,188,1631602800"; d="scan'208";a="486924662" Received: from gupta-dev2.jf.intel.com (HELO gupta-dev2.localdomain) ([10.54.74.119]) by orsmga007.jf.intel.com with ESMTP; 27 Oct 2021 18:31:05 -0700 Date: Wed, 27 Oct 2021 18:33:22 -0700 From: Pawan Gupta To: Russell King , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen Cc: x86@kernel.org, "H. Peter Anvin" , Kees Cook , Andrew Morton , Masahiro Yamada , "Peter Zijlstra (Intel)" , Sami Tolvanen , Colin Ian King , Frederic Weisbecker , Mike Rapoport , YiFei Zhu , "Steven Rostedt (VMware)" , Viresh Kumar , Andrey Konovalov , Mark Rutland , Wang Kefeng , Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= , Nathan Chancellor , Pawan Gupta , Nick Desaulniers , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v2 1/2] arch/Kconfig: Make CONFIG_CPU_SPECTRE available for all architectures Message-ID: <232b692cd79e4f6e4c3ee7055b5f02792a28d2c4.1635383031.git.pawan.kumar.gupta@linux.intel.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211027_183107_609143_367B2E94 X-CRM114-Status: GOOD ( 12.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Borrow CONFIG_CPU_SPECTRE from ARM to be available for all architectures. This will help in configuration of features that depend on CPU being affected by spectre class of vulnerabilities. Signed-off-by: Pawan Gupta --- arch/Kconfig | 3 +++ arch/arm/mm/Kconfig | 3 --- arch/x86/Kconfig | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/arch/Kconfig b/arch/Kconfig index 8df1c7102643..6aa856d51cb7 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -1091,6 +1091,9 @@ config ARCH_SUPPORTS_RT config CPU_NO_EFFICIENT_FFS def_bool n +config CPU_SPECTRE + bool + config HAVE_ARCH_VMAP_STACK def_bool n help diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index 8355c3895894..44551465fd03 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig @@ -828,9 +828,6 @@ config CPU_BPREDICT_DISABLE help Say Y here to disable branch prediction. If unsure, say N. -config CPU_SPECTRE - bool - config HARDEN_BRANCH_PREDICTOR bool "Harden the branch predictor against aliasing attacks" if EXPERT depends on CPU_SPECTRE diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index d9830e7e1060..769739da67c6 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -124,6 +124,7 @@ config X86 select CLKEVT_I8253 select CLOCKSOURCE_VALIDATE_LAST_CYCLE select CLOCKSOURCE_WATCHDOG + select CPU_SPECTRE select DCACHE_WORD_ACCESS select EDAC_ATOMIC_SCRUB select EDAC_SUPPORT -- 2.31.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel