Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2079552ybb; Thu, 2 Apr 2020 12:41:12 -0700 (PDT) X-Google-Smtp-Source: APiQypKbdEenj5c99aUsMv7JneXDOJS5cRTdpKpQy4OJibMzWsTwTr91aECLzPCuUloblmxhQNTS X-Received: by 2002:aca:3dd7:: with SMTP id k206mr534807oia.63.1585856472629; Thu, 02 Apr 2020 12:41:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585856472; cv=none; d=google.com; s=arc-20160816; b=PW+oVNvUCaL1gmaUNq1U9P+byEjGJE2inNY5UK9pu1Q9z0QmkNG6i3oWzCBvPByay+ HJcaPbQJNN1tTpTFGoyDlyrYye0kzWMzu0J8i+iheh1CzRA7vaKkiDfKpt+TsRjJEbTp HcSqAytTI2R/Mj7PBG0QVWwCVVUos9cKZwXB2rsBnS3xtAof7yh3H3XKuLm1I5jITdrQ TvtnhQTdzMR54cF4sN3vGTGjWSYb26lc4jpQXM4JPSL9gRVbD5SDyt426feiEJ/dyQ6X TKx3m+tZ+2/JzSKvHDfdJl+sShUgzZ3HzgEDcZwGnIGHygJYXc1AwXZYuC/F6Jq6jeKB 3Mvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=VNVfYQcU5r7QqnygVgwbeTwWR3NWKnCIk7XJifmEK+g=; b=WZmL708tBvGvghtkICTwg71A+VckCw1lHczr+b27nbeOR+fyO9NRb9MF3dJyWVQaY9 XDMGdY91boS3JX5Vw2mUVWyEzmkbtmPrw4aHI1awgLAtBz31HxeojKr9/Dcdn79DiJ5l ADN5TH/a2ab0U+Uwbz314WQK3bspR/Mjhr9shsMB3xvKdUxaidCs+2USzZk4jvmudLAS 001UEu2g/CGSLX/LR02GvEl6ChQjRvBI7E8Jr20DOveR/fBhabMkCjZWHdqK5lNA046W fSREbI+sRjB5Q7LbqZx+Rvg/vyD1SYvO6SXyPg+PQ0HvhdieXo59BC4kXwWStjooqhjK rRbw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=WFRj2oMO; 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 i124si2683213oib.172.2020.04.02.12.40.59; Thu, 02 Apr 2020 12:41:12 -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=@linux-foundation.org header.s=google header.b=WFRj2oMO; 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 S2388720AbgDBTdM (ORCPT + 99 others); Thu, 2 Apr 2020 15:33:12 -0400 Received: from mail-ed1-f68.google.com ([209.85.208.68]:46148 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729033AbgDBTdM (ORCPT ); Thu, 2 Apr 2020 15:33:12 -0400 Received: by mail-ed1-f68.google.com with SMTP id cf14so5827617edb.13 for ; Thu, 02 Apr 2020 12:33:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=VNVfYQcU5r7QqnygVgwbeTwWR3NWKnCIk7XJifmEK+g=; b=WFRj2oMOOBQ9Ye/JZJICZujrvRy2hkbOR9uXKlMdFDvf9Q5Lq80wgWioeP0e0rs0oj n0Wk/vH8ieHoUcWgLtyDYX5P7nJxjuAYNdlNyNknULgO81UVaZJ0LqdKLLefqzuqrqZf RMdkwJXPuZPoAbZGgiU6xp+RQahaYFh5oXLKg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=VNVfYQcU5r7QqnygVgwbeTwWR3NWKnCIk7XJifmEK+g=; b=hJUbA6WWPUpTFFAEP2Kd7TpSl6r3vL5oV0fTTRf7jkKLHnA+lsxHTr05lzfjaBzDqD midmDoGUVwyFK+15epjG0rmHLjRf5eg0ON7QVXvFTiElW1SCT1V7FuWBOL1wflod36J8 bTNXUUjaTMzbdh4jxdbvVaxgJyTAHdfx6gkeJY92d151z600Ljn8njLx8UPJHRIq+EZ2 QgZXrnn2sbtrODH04by/zfJwnj5j08W8qlMKdc8I5daXw455W0VsWFq9MCp8wXUNox+w eZGCWwFMiJPWMywk9nfCIojoGMinLFAvygqkh+BoimqQixf0C6NxamotWlX5vOOUZMGG 0xpw== X-Gm-Message-State: AGi0Pub0fya7nc2XwaMBXW5GPwiXa8MqT5ah6MWL39BmMmE2eK0Fghd2 g0XFKZPF8DhJv45XbSdEGpL4XfnVhc0= X-Received: by 2002:a05:6402:17a7:: with SMTP id j7mr4646605edy.334.1585855988524; Thu, 02 Apr 2020 12:33:08 -0700 (PDT) Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com. [209.85.221.47]) by smtp.gmail.com with ESMTPSA id d23sm1246832ejk.26.2020.04.02.12.33.08 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Apr 2020 12:33:08 -0700 (PDT) Received: by mail-wr1-f47.google.com with SMTP id c7so5639304wrx.5 for ; Thu, 02 Apr 2020 12:33:08 -0700 (PDT) X-Received: by 2002:a2e:8911:: with SMTP id d17mr2938169lji.16.1585855628859; Thu, 02 Apr 2020 12:27:08 -0700 (PDT) MIME-Version: 1.0 References: <27106d62fdbd4ffb47796236050e418131cb837f.1585811416.git.christophe.leroy@c-s.fr> <20200402162942.GG23230@ZenIV.linux.org.uk> <67e21b65-0e2d-7ca5-7518-cec1b7abc46c@c-s.fr> <20200402175032.GH23230@ZenIV.linux.org.uk> <202004021132.813F8E88@keescook> In-Reply-To: <202004021132.813F8E88@keescook> From: Linus Torvalds Date: Thu, 2 Apr 2020 12:26:52 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH RESEND 1/4] uaccess: Add user_read_access_begin/end and user_write_access_begin/end To: Kees Cook Cc: Al Viro , Christophe Leroy , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , Dave Airlie , Daniel Vetter , Andrew Morton , Peter Anvin , Linux Kernel Mailing List , linuxppc-dev , Linux-MM , linux-arch , Russell King , Christian Borntraeger 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 On Thu, Apr 2, 2020 at 11:36 AM Kees Cook wrote: > > Yup, I think it's a weakness of the ARM implementation and I'd like to > not extend it further. AFAIK we should never nest, but I would not be > surprised at all if we did. Wel, at least the user_access_begin/end() sections can't nest. objtool verifies and warns about that on x86. > If we were looking at a design goal for all architectures, I'd like > to be doing what the public PaX patchset We already do better than PaX ever did. Seriously. Mainline has long since passed their hacky garbage. Plus PaX and grsecurity should be actively shunned. Don't look at it, don't use it, and tell everybody you know to not use that shit. Linus