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 X-Spam-Level: X-Spam-Status: No, score=-8.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 45613C433E1 for ; Thu, 13 Aug 2020 20:53:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 165E720715 for ; Thu, 13 Aug 2020 20:53:10 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="BY/RaFL1" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726673AbgHMUxJ (ORCPT ); Thu, 13 Aug 2020 16:53:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45086 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726499AbgHMUxI (ORCPT ); Thu, 13 Aug 2020 16:53:08 -0400 Received: from mail-pl1-x643.google.com (mail-pl1-x643.google.com [IPv6:2607:f8b0:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AB549C061757; Thu, 13 Aug 2020 13:53:08 -0700 (PDT) Received: by mail-pl1-x643.google.com with SMTP id u10so3163190plr.7; Thu, 13 Aug 2020 13:53:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:cc:references:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=BY/RaFL1BVNPFlGHJzyLzey4vsiBfNtRMsw3MUihtFPevNI6wBAodIqL8l9LyiC8Oq Eo21w0GU1xVIaAU2FMgX28MU4LpFfWXG7LZOiSCe0R/mxr8L/6WKNnWW/OPaTZa0B53o auaWm/ULLH4BluQuWM3Ptb6CmqOTrQ3wf7Xp/8XN/Tn5603OECm26w+DcCTMJtNaXmdp 5P4+FVUNcAC7KebDKPDI9F01gUfj1ezszF/xQ4G1kPSHW2W3DFX2M7WfibPvOkoiAQnl +w3p5mbG0qTjS+NjvbNWIeaVGsRmDPPrP1xx/Yl/fB3LWVgi4GjTn4XyHDbY7oQiXx+I 3eEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=Vn5LSwrtCbvUnH3DNMnd7cHbNPNKTFXcs8VMTsBo56E7PVmMZ/c9x9KRUKnEngJ/LD HoA9l61jJ7MYOzk8PHFBWnh+Rwt1TfoZG11spTjdPs7PXVVnpdH9tpcXWobby/KjS4l4 z1PvdzJSY+lnlikb3wmhYF/RDQKBcoF6LKE4tWIAZFk9PnYjlgReSw8STbc6ACCueL68 jgu36wXjUjXJ87qYEukCQaJudPmT1FqJ0y+EJZUavBRu8ChBuEpdCp198dDPUrrChq0j XXf4BA+eNPAew4irM/9jC/KSPlwkHkN+oU8+y3UC1QzRRqe7oHMmE5e0ypb5YItgUkZ/ uuAQ== X-Gm-Message-State: AOAM531Bpxw9roDExDN4wEGR8yyNVYiVk5ntXQk7q25ZFKbIg6nrpX15 hVXuN0uTltSu2Hs0rO/o2z0= X-Google-Smtp-Source: ABdhPJwJ7SDcRA3ZGymFvn6xsKEpJWj4sIm+NKcGlAI2M7tYtar9FKkQpMc6BjAOeT2ZGaSmFR8MVw== X-Received: by 2002:a17:90a:8918:: with SMTP id u24mr6329006pjn.7.1597351988125; Thu, 13 Aug 2020 13:53:08 -0700 (PDT) Received: from [10.230.30.107] ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id z25sm6975261pfg.150.2020.08.13.13.52.58 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 Aug 2020 13:53:07 -0700 (PDT) From: Florian Fainelli Subject: Re: [PATCH stable v4.9 v2] arm64: entry: Place an SB sequence following an ERET instruction To: Greg KH , Will Deacon , Will Deacon Cc: linux-arm-kernel@lists.infradead.org, stable@vger.kernel.org, Catalin Marinas , Marc Zyngier , James Morse , Julien Thierry , Suzuki K Poulose , Mark Rutland , Mark Brown , Kristina Martsenko , Sami Tolvanen , Andrew Jones , Ard Biesheuvel , Nick Desaulniers , Fangrui Song , open list , "open list:KERNEL VIRTUAL MACHINE FOR ARM64 (KVM/arm64)" References: <20200709195034.15185-1-f.fainelli@gmail.com> <20200720130411.GB494210@kroah.com> <9c29080e-8b3a-571c-3296-e0487fa473fa@gmail.com> <20200807131429.GB664450@kroah.com> Message-ID: <647d771d-441b-39f9-809a-19335ef16036@gmail.com> Date: Thu, 13 Aug 2020 13:52:56 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 8/7/2020 11:17 AM, Florian Fainelli wrote: > > > On 8/7/2020 6:14 AM, Greg KH wrote: >> On Thu, Aug 06, 2020 at 01:00:54PM -0700, Florian Fainelli wrote: >>> >>> >>> On 7/20/2020 11:26 AM, Florian Fainelli wrote: >>>> On 7/20/20 6:04 AM, Greg KH wrote: >>>>> On Thu, Jul 09, 2020 at 12:50:23PM -0700, Florian Fainelli wrote: >>>>>> From: Will Deacon >>>>>> >>>>>> commit 679db70801da9fda91d26caf13bf5b5ccc74e8e8 upstream >>>>>> >>>>>> Some CPUs can speculate past an ERET instruction and potentially perform >>>>>> speculative accesses to memory before processing the exception return. >>>>>> Since the register state is often controlled by a lower privilege level >>>>>> at the point of an ERET, this could potentially be used as part of a >>>>>> side-channel attack. >>>>>> >>>>>> This patch emits an SB sequence after each ERET so that speculation is >>>>>> held up on exception return. >>>>>> >>>>>> Signed-off-by: Will Deacon >>>>>> [florian: Adjust hyp-entry.S to account for the label >>>>>> added change to hyp/entry.S] >>>>>> Signed-off-by: Florian Fainelli >>>>>> --- >>>>>> Changes in v2: >>>>>> >>>>>> - added missing hunk in hyp/entry.S per Will's feedback >>>>> >>>>> What about 4.19.y and 4.14.y trees? I can't take something for 4.9.y >>>>> and then have a regression if someone moves to a newer release, right? >>>> >>>> Sure, send you candidates for 4.14 and 4.19. >>> >>> Greg, did you have a chance to queue those changes for 4.9, 4.14 and 4.19? >>> >>> https://lore.kernel.org/linux-arm-kernel/20200720182538.13304-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200720182937.14099-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200709195034.15185-1-f.fainelli@gmail.com/ >> >> Nope, I was waiting for Will's "ack" for these. > > OK, Will, can you review those? Thanks Will, can you please review those patches? -- Florian 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 X-Spam-Level: X-Spam-Status: No, score=-8.3 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A2753C433DF for ; Thu, 13 Aug 2020 20:53:14 +0000 (UTC) Received: from mm01.cs.columbia.edu (mm01.cs.columbia.edu [128.59.11.253]) by mail.kernel.org (Postfix) with ESMTP id 0EF5B20715 for ; Thu, 13 Aug 2020 20:53:13 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="BY/RaFL1" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0EF5B20715 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvmarm-bounces@lists.cs.columbia.edu Received: from localhost (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 372684B9E9; Thu, 13 Aug 2020 16:53:13 -0400 (EDT) X-Virus-Scanned: at lists.cs.columbia.edu Authentication-Results: mm01.cs.columbia.edu (amavisd-new); dkim=softfail (fail, message has been altered) header.i=@gmail.com Received: from mm01.cs.columbia.edu ([127.0.0.1]) by localhost (mm01.cs.columbia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LWbpFXfRc8wN; Thu, 13 Aug 2020 16:53:12 -0400 (EDT) Received: from mm01.cs.columbia.edu (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 2DE064BA18; Thu, 13 Aug 2020 16:53:12 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 0D60B4B9E9 for ; Thu, 13 Aug 2020 16:53:11 -0400 (EDT) X-Virus-Scanned: at lists.cs.columbia.edu Received: from mm01.cs.columbia.edu ([127.0.0.1]) by localhost (mm01.cs.columbia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aV9msijYIYvr for ; Thu, 13 Aug 2020 16:53:09 -0400 (EDT) Received: from mail-pl1-f196.google.com (mail-pl1-f196.google.com [209.85.214.196]) by mm01.cs.columbia.edu (Postfix) with ESMTPS id C9B814B64E for ; Thu, 13 Aug 2020 16:53:09 -0400 (EDT) Received: by mail-pl1-f196.google.com with SMTP id r4so3174766pls.2 for ; Thu, 13 Aug 2020 13:53:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:cc:references:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=BY/RaFL1BVNPFlGHJzyLzey4vsiBfNtRMsw3MUihtFPevNI6wBAodIqL8l9LyiC8Oq Eo21w0GU1xVIaAU2FMgX28MU4LpFfWXG7LZOiSCe0R/mxr8L/6WKNnWW/OPaTZa0B53o auaWm/ULLH4BluQuWM3Ptb6CmqOTrQ3wf7Xp/8XN/Tn5603OECm26w+DcCTMJtNaXmdp 5P4+FVUNcAC7KebDKPDI9F01gUfj1ezszF/xQ4G1kPSHW2W3DFX2M7WfibPvOkoiAQnl +w3p5mbG0qTjS+NjvbNWIeaVGsRmDPPrP1xx/Yl/fB3LWVgi4GjTn4XyHDbY7oQiXx+I 3eEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=lpYdB0JtCZtpif365cfreuGj/Vi+94Pu0DsaW03kOq4yP4VOXHqJ4GMoTxFFhfI+yo HRJ30Iuqdp3AYJXjkx61NW6kgYGoen1hHkIhlGLPGG/8KoELXZT43EFeBlfN4OvojPVR UHCuYRiTg5e1o7irtz4ZYnjaAhiG3o85WDfrLdA89rq/C55iDfFlWtdE+pSEYVfJvpAt VsQvOr9nXGewYMv6RbyolsdliyWOm+J5BmmUiGn0tlotERqFCdHShIko/fjHT+j/n5QD fa9C1w2PcaYmm8kUd/+pA6aJVuqjbdWegiefmIP8nuNMe+OcwgprRiSk+7sWC0Pl0ysR vUJg== X-Gm-Message-State: AOAM531GgMOTwVTr4KIl0iHqzyZ2BZaMq2zF3hiwKaRhqBX0L6ZaE3vA P6MtONeZ2ebbmVwhjb22F9kVEzJ4 X-Google-Smtp-Source: ABdhPJwJ7SDcRA3ZGymFvn6xsKEpJWj4sIm+NKcGlAI2M7tYtar9FKkQpMc6BjAOeT2ZGaSmFR8MVw== X-Received: by 2002:a17:90a:8918:: with SMTP id u24mr6329006pjn.7.1597351988125; Thu, 13 Aug 2020 13:53:08 -0700 (PDT) Received: from [10.230.30.107] ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id z25sm6975261pfg.150.2020.08.13.13.52.58 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 Aug 2020 13:53:07 -0700 (PDT) From: Florian Fainelli Subject: Re: [PATCH stable v4.9 v2] arm64: entry: Place an SB sequence following an ERET instruction To: Greg KH , Will Deacon , Will Deacon References: <20200709195034.15185-1-f.fainelli@gmail.com> <20200720130411.GB494210@kroah.com> <9c29080e-8b3a-571c-3296-e0487fa473fa@gmail.com> <20200807131429.GB664450@kroah.com> Message-ID: <647d771d-441b-39f9-809a-19335ef16036@gmail.com> Date: Thu, 13 Aug 2020 13:52:56 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.1.1 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US Cc: Nick Desaulniers , Fangrui Song , Catalin Marinas , Kristina Martsenko , open list , stable@vger.kernel.org, "open list:KERNEL VIRTUAL MACHINE FOR ARM64 \(KVM/arm64\)" , Mark Brown , linux-arm-kernel@lists.infradead.org, Sami Tolvanen , Marc Zyngier , Ard Biesheuvel X-BeenThere: kvmarm@lists.cs.columbia.edu X-Mailman-Version: 2.1.14 Precedence: list List-Id: Where KVM/ARM decisions are made List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: kvmarm-bounces@lists.cs.columbia.edu Sender: kvmarm-bounces@lists.cs.columbia.edu On 8/7/2020 11:17 AM, Florian Fainelli wrote: > > > On 8/7/2020 6:14 AM, Greg KH wrote: >> On Thu, Aug 06, 2020 at 01:00:54PM -0700, Florian Fainelli wrote: >>> >>> >>> On 7/20/2020 11:26 AM, Florian Fainelli wrote: >>>> On 7/20/20 6:04 AM, Greg KH wrote: >>>>> On Thu, Jul 09, 2020 at 12:50:23PM -0700, Florian Fainelli wrote: >>>>>> From: Will Deacon >>>>>> >>>>>> commit 679db70801da9fda91d26caf13bf5b5ccc74e8e8 upstream >>>>>> >>>>>> Some CPUs can speculate past an ERET instruction and potentially perform >>>>>> speculative accesses to memory before processing the exception return. >>>>>> Since the register state is often controlled by a lower privilege level >>>>>> at the point of an ERET, this could potentially be used as part of a >>>>>> side-channel attack. >>>>>> >>>>>> This patch emits an SB sequence after each ERET so that speculation is >>>>>> held up on exception return. >>>>>> >>>>>> Signed-off-by: Will Deacon >>>>>> [florian: Adjust hyp-entry.S to account for the label >>>>>> added change to hyp/entry.S] >>>>>> Signed-off-by: Florian Fainelli >>>>>> --- >>>>>> Changes in v2: >>>>>> >>>>>> - added missing hunk in hyp/entry.S per Will's feedback >>>>> >>>>> What about 4.19.y and 4.14.y trees? I can't take something for 4.9.y >>>>> and then have a regression if someone moves to a newer release, right? >>>> >>>> Sure, send you candidates for 4.14 and 4.19. >>> >>> Greg, did you have a chance to queue those changes for 4.9, 4.14 and 4.19? >>> >>> https://lore.kernel.org/linux-arm-kernel/20200720182538.13304-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200720182937.14099-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200709195034.15185-1-f.fainelli@gmail.com/ >> >> Nope, I was waiting for Will's "ack" for these. > > OK, Will, can you review those? Thanks Will, can you please review those patches? -- Florian _______________________________________________ kvmarm mailing list kvmarm@lists.cs.columbia.edu https://lists.cs.columbia.edu/mailman/listinfo/kvmarm 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 X-Spam-Level: X-Spam-Status: No, score=-8.5 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3424EC433E1 for ; Thu, 13 Aug 2020 20:54:44 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 F408020715 for ; Thu, 13 Aug 2020 20:54:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="O7nUK7vM"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="BY/RaFL1" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F408020715 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:References: To:Subject:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=gd9gpmnRVx0JjsYL5eDsBF5/P6vjpK5AnKqfs2XVlyo=; b=O7nUK7vMWv3GwgN3e2Y9RSB8b PDO5y3VHwS6DmRoHLvfgs0O+yj3ZieBqdXtQuscqwYNtBcWBNVss/GPVotic7z6PC6wcMQ0v9IMCa g/iD+y6XgwaOkW9qL0y9I3ic6Ud7CRY/vkxpzVN9EDtTFTeouwH7+occbchg3Qz+xAyJYoVAosCzV h+DABzyOu40HGjujbmvAA5HSh+mtzCUkHuT2/DQEITTHrfPOfvDFngWszB8FctKf7my5BmgCRKU09 Xbprob1k9zo24jUno5H0U2/VdGroHvBqSl9r541TfpQ3YukBqW2Vb688hGbTxsN1om2CK/GZRj1OO P6aMUTEjQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k6KDp-0007SE-7O; Thu, 13 Aug 2020 20:53:13 +0000 Received: from mail-pl1-x642.google.com ([2607:f8b0:4864:20::642]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k6KDm-0007Rk-8G for linux-arm-kernel@lists.infradead.org; Thu, 13 Aug 2020 20:53:11 +0000 Received: by mail-pl1-x642.google.com with SMTP id q19so3180765pll.0 for ; Thu, 13 Aug 2020 13:53:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:cc:references:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=BY/RaFL1BVNPFlGHJzyLzey4vsiBfNtRMsw3MUihtFPevNI6wBAodIqL8l9LyiC8Oq Eo21w0GU1xVIaAU2FMgX28MU4LpFfWXG7LZOiSCe0R/mxr8L/6WKNnWW/OPaTZa0B53o auaWm/ULLH4BluQuWM3Ptb6CmqOTrQ3wf7Xp/8XN/Tn5603OECm26w+DcCTMJtNaXmdp 5P4+FVUNcAC7KebDKPDI9F01gUfj1ezszF/xQ4G1kPSHW2W3DFX2M7WfibPvOkoiAQnl +w3p5mbG0qTjS+NjvbNWIeaVGsRmDPPrP1xx/Yl/fB3LWVgi4GjTn4XyHDbY7oQiXx+I 3eEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=KMEdmNBQWTzUTOzp1bnF8SX2rCsME0fqtsH4k5tjFgk=; b=aMRJLw7sWurM3wdQt7A7nC3i/B1z95Iom9TQ3H3MiU6ZNsc77jedjjMP7coUvjmpeq bExUzAht8T4Dq1i7f2RarafqnqUEuR67UUmM71IqpPL+4TRNXbeHJ4SfPR/14eIRwv35 1F4dUC92XYpbVOqkPOjq6SUEXV8lO+RjN5GBxrlEUUait9HGjunc0bOonESE4XEs0VMC Z6Ta6OF/pOVZ/LeM55Z/yO/vQXfUgIcS0KlMj1UUZcQb7OdVDcGTBBMw/BwxrrdQ/t4i mVeGY/aCV2j9cG1z8Jm5R2orWlNOuUWgsOprhbEe9Tk70VjzHynswUSjsYoU2Qgg3SEu H3OA== X-Gm-Message-State: AOAM532jvxCAXQR6MbKZ6JCE8tgt2LIqeOFwsYEk46nkqSMK+g2aedwN CvlnMLSDnDfffj8Bhgt6Cjs= X-Google-Smtp-Source: ABdhPJwJ7SDcRA3ZGymFvn6xsKEpJWj4sIm+NKcGlAI2M7tYtar9FKkQpMc6BjAOeT2ZGaSmFR8MVw== X-Received: by 2002:a17:90a:8918:: with SMTP id u24mr6329006pjn.7.1597351988125; Thu, 13 Aug 2020 13:53:08 -0700 (PDT) Received: from [10.230.30.107] ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id z25sm6975261pfg.150.2020.08.13.13.52.58 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 Aug 2020 13:53:07 -0700 (PDT) From: Florian Fainelli Subject: Re: [PATCH stable v4.9 v2] arm64: entry: Place an SB sequence following an ERET instruction To: Greg KH , Will Deacon , Will Deacon References: <20200709195034.15185-1-f.fainelli@gmail.com> <20200720130411.GB494210@kroah.com> <9c29080e-8b3a-571c-3296-e0487fa473fa@gmail.com> <20200807131429.GB664450@kroah.com> Message-ID: <647d771d-441b-39f9-809a-19335ef16036@gmail.com> Date: Thu, 13 Aug 2020 13:52:56 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.1.1 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200813_165310_340680_87F65AF8 X-CRM114-Status: GOOD ( 15.99 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Nick Desaulniers , Andrew Jones , Fangrui Song , Suzuki K Poulose , Catalin Marinas , Kristina Martsenko , open list , stable@vger.kernel.org, "open list:KERNEL VIRTUAL MACHINE FOR ARM64 \(KVM/arm64\)" , Mark Brown , James Morse , linux-arm-kernel@lists.infradead.org, Sami Tolvanen , Marc Zyngier , Ard Biesheuvel , Julien Thierry Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 8/7/2020 11:17 AM, Florian Fainelli wrote: > > > On 8/7/2020 6:14 AM, Greg KH wrote: >> On Thu, Aug 06, 2020 at 01:00:54PM -0700, Florian Fainelli wrote: >>> >>> >>> On 7/20/2020 11:26 AM, Florian Fainelli wrote: >>>> On 7/20/20 6:04 AM, Greg KH wrote: >>>>> On Thu, Jul 09, 2020 at 12:50:23PM -0700, Florian Fainelli wrote: >>>>>> From: Will Deacon >>>>>> >>>>>> commit 679db70801da9fda91d26caf13bf5b5ccc74e8e8 upstream >>>>>> >>>>>> Some CPUs can speculate past an ERET instruction and potentially perform >>>>>> speculative accesses to memory before processing the exception return. >>>>>> Since the register state is often controlled by a lower privilege level >>>>>> at the point of an ERET, this could potentially be used as part of a >>>>>> side-channel attack. >>>>>> >>>>>> This patch emits an SB sequence after each ERET so that speculation is >>>>>> held up on exception return. >>>>>> >>>>>> Signed-off-by: Will Deacon >>>>>> [florian: Adjust hyp-entry.S to account for the label >>>>>> added change to hyp/entry.S] >>>>>> Signed-off-by: Florian Fainelli >>>>>> --- >>>>>> Changes in v2: >>>>>> >>>>>> - added missing hunk in hyp/entry.S per Will's feedback >>>>> >>>>> What about 4.19.y and 4.14.y trees? I can't take something for 4.9.y >>>>> and then have a regression if someone moves to a newer release, right? >>>> >>>> Sure, send you candidates for 4.14 and 4.19. >>> >>> Greg, did you have a chance to queue those changes for 4.9, 4.14 and 4.19? >>> >>> https://lore.kernel.org/linux-arm-kernel/20200720182538.13304-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200720182937.14099-1-f.fainelli@gmail.com/ >>> https://lore.kernel.org/linux-arm-kernel/20200709195034.15185-1-f.fainelli@gmail.com/ >> >> Nope, I was waiting for Will's "ack" for these. > > OK, Will, can you review those? Thanks Will, can you please review those patches? -- Florian _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel