Received: by 10.223.185.116 with SMTP id b49csp422885wrg; Fri, 16 Feb 2018 01:04:13 -0800 (PST) X-Google-Smtp-Source: AH8x226VM/ApZpvi1tlgc/FYm9kt9234F3S91j/Hxr9pnnkE2GltczwdIswzSf+DuWiQZ2Rd79v/ X-Received: by 10.99.62.136 with SMTP id l130mr4575732pga.28.1518771853534; Fri, 16 Feb 2018 01:04:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518771853; cv=none; d=google.com; s=arc-20160816; b=xQU44s1LveADJr1RUvDZnIYSwZfia1AYKSWkoP4FxgpS+PLygWtYDsbT+oGk62APLu 8AJRKZhQdEPbbK5ScCs4VD5LsuR8lIteBUCisiObnPFiWC8OoeTVCmb/r8u0RcWLlLio O5vi273eL6nwL+U+HQPwaC5R/tn7BVlc8dEl9xdtmtPqUaDJPMSMzuGXdNvRWeidBKK/ WCHQ8/Kk7Sh08DXm+kBI4tvaSMsjMxBPARcUb4tvh1xKKp2J+/MOfUn+Ht/hAu2AUhRR eugDvyUlf9ENmADOOWZZDkuaby6OW2WyccDzGvOMCpoSPETc8dggfydepV83hcz6HP2J +uJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=gllUXNHXATY+54g5xiDHe8hhB4NOJl9G0abJ2D7xIjE=; b=qYD6a0LPMffegxGRuXgjFuSyVr2jXgPRkKQTw6D7OvXFsx4K4bTJQVGUJPnEY0Wd8n L+OBTM93nWlpNcseOmF5ReaIuF8e5EpKn3Y3nZ4C09RbPakAGH+Ca0+yxHbK5tTcn4cy cQ1ukcXjwcpcp+OgizBHaeFp8YRRp9CrlsQQzdWsjDQfRFsckND4+crf+PedJ+Irk6Cc zmmMonW4fTa59hVufQCFMZl23qKKOYuNKhacR1dx2ccM3N576hDNs7JYdZzrHLuUfG6Y WA+hzb2rDQv1fjVXeZVhl/20T0codqOtZ7IPgeMTTFHbrq+A1LL2Og9JGH0jGOdEMx+C jdAQ== ARC-Authentication-Results: i=1; mx.google.com; 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 f2-v6si663457pln.401.2018.02.16.01.03.47; Fri, 16 Feb 2018 01:04:13 -0800 (PST) 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; 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 S1425980AbeBOQdo (ORCPT + 99 others); Thu, 15 Feb 2018 11:33:44 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:32810 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1423426AbeBOPlr (ORCPT ); Thu, 15 Feb 2018 10:41:47 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 2D0808A6; Thu, 15 Feb 2018 15:41:47 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Will Deacon , Jayachandran C , Catalin Marinas Subject: [PATCH 4.15 071/202] [Variant 2/Spectre-v2] arm64: Branch predictor hardening for Cavium ThunderX2 Date: Thu, 15 Feb 2018 16:16:11 +0100 Message-Id: <20180215151717.205135826@linuxfoundation.org> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180215151712.768794354@linuxfoundation.org> References: <20180215151712.768794354@linuxfoundation.org> User-Agent: quilt/0.65 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Jayachandran C Commit f3d795d9b360 upstream. Use PSCI based mitigation for speculative execution attacks targeting the branch predictor. We use the same mechanism as the one used for Cortex-A CPUs, we expect the PSCI version call to have a side effect of clearing the BTBs. Acked-by: Will Deacon Signed-off-by: Jayachandran C Signed-off-by: Catalin Marinas Signed-off-by: Will Deacon Signed-off-by: Greg Kroah-Hartman --- arch/arm64/kernel/cpu_errata.c | 10 ++++++++++ 1 file changed, 10 insertions(+) --- a/arch/arm64/kernel/cpu_errata.c +++ b/arch/arm64/kernel/cpu_errata.c @@ -359,6 +359,16 @@ const struct arm64_cpu_capabilities arm6 .capability = ARM64_HARDEN_BP_POST_GUEST_EXIT, MIDR_ALL_VERSIONS(MIDR_QCOM_FALKOR_V1), }, + { + .capability = ARM64_HARDEN_BRANCH_PREDICTOR, + MIDR_ALL_VERSIONS(MIDR_BRCM_VULCAN), + .enable = enable_psci_bp_hardening, + }, + { + .capability = ARM64_HARDEN_BRANCH_PREDICTOR, + MIDR_ALL_VERSIONS(MIDR_CAVIUM_THUNDERX2), + .enable = enable_psci_bp_hardening, + }, #endif { }