Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1287207pxb; Wed, 10 Feb 2021 05:05:40 -0800 (PST) X-Google-Smtp-Source: ABdhPJwji7szY7p4VrFD+dksAzex2OzJ4iDedE9vJvhhI08HtnHkWvcyQexaQFvBCnueO4xROinM X-Received: by 2002:a17:906:a2d2:: with SMTP id by18mr2751810ejb.262.1612962339898; Wed, 10 Feb 2021 05:05:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612962339; cv=none; d=google.com; s=arc-20160816; b=ESEhyra2uJjl+Zt0rVnmW39zBcu4YZXVmQgo/F8nZR9ONRjAOF+bWzSZpoE3GSqLbv mJNzqutPTjMaBwW68o5CUf8FuMFb8sPVLDZ2EUEzr6fB4s79ZdS7CK2Di9xrWXCrAU0U RuQ1Iyuoptpi72LkksP4L3fEef4dXbt+mR3wpNmv0VpuhgZtCbx7Goz0ynKepUxQvkXx U6nDi3OZjuGJav0AHLtnZqeTwGwBH/S+pSiv7pusSGOOvpN0u5yD8e+cqNttnTWdYFru M6PQ6PWHE5gn5owdsH+psHekxDPsNA90yDQTXHX/HTity/BJRrTfDbsrPaEdBLalsnDP OG/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:message-id:subject:references:in-reply-to :cc:to:from; bh=3dhq//RJXBe/B7p3FrVos4RiJucirE4zLqFtfFnB30g=; b=OZvgUC7WhiJ0B7FFDhBu2Lfq60KBzgDv31fuLQjhWbIeUmkj4KLhW4rnzkWlREGJ49 IzPNds+T3raep2sNi3TtqFQrqp21AVJZBpFaIq6niwLw1rmjFpujp0eSCkBJrQVfXyCA 7zUwH5aPzl8nx3FGRTRGllPHWF+uorjWUtlIr2S31sghQjQT5CVudHCgOwwXrKLUw69c uwrAz6XqPsrmJPPH54Q7mTTzOCaW4+yr92fZp3royOvm9LLQKHB2qkF+ruTUsZp9rJUW NTSchog+AKNqBLeoftdSwLY2aRx2TH171FCUqVp5y7AHaR2fdwQkgksQ0JfJsZgrA767 3pTw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q3si1274955edv.223.2021.02.10.05.05.15; Wed, 10 Feb 2021 05:05:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231865AbhBJNCm (ORCPT + 99 others); Wed, 10 Feb 2021 08:02:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49540 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231699AbhBJM55 (ORCPT ); Wed, 10 Feb 2021 07:57:57 -0500 Received: from ozlabs.org (ozlabs.org [IPv6:2401:3900:2:1::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 98264C061788 for ; Wed, 10 Feb 2021 04:57:32 -0800 (PST) Received: by ozlabs.org (Postfix, from userid 1034) id 4DbKY44w7Yz9sVw; Wed, 10 Feb 2021 23:57:27 +1100 (AEDT) From: Michael Ellerman To: Michael Ellerman , cmr@codefail.de, Benjamin Herrenschmidt , Christophe Leroy , Paul Mackerras Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org In-Reply-To: References: Subject: Re: [PATCH] powerpc/uaccess: Perform barrier_nospec() in KUAP allowance helpers Message-Id: <161296172412.3178259.4318567757525360600.b4-ty@ellerman.id.au> Date: Wed, 10 Feb 2021 23:57:27 +1100 (AEDT) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 7 Feb 2021 10:08:11 +0000 (UTC), Christophe Leroy wrote: > barrier_nospec() in uaccess helpers is there to protect against > speculative accesses around access_ok(). > > When using user_access_begin() sequences together with > unsafe_get_user() like macros, barrier_nospec() is called for > every single read although we know the access_ok() is done > onece. > > [...] Applied to powerpc/next. [1/1] powerpc/uaccess: Perform barrier_nospec() in KUAP allowance helpers https://git.kernel.org/powerpc/c/8524e2e76441fc615a3b5c1415823e051cc79eae cheers