Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2110634pxa; Mon, 24 Aug 2020 05:36:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxRb6Tsd1YkiazB1j79iFF+X402zeZVvcxN0J0WqaNRd0u7tBpJyMujF/lADa9kIxBWfF7K X-Received: by 2002:a17:906:e093:: with SMTP id gh19mr5281408ejb.210.1598272573656; Mon, 24 Aug 2020 05:36:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598272573; cv=none; d=google.com; s=arc-20160816; b=n6gS4WPYi+GLpK7CMRc+R4xm9fWPoSj/aeno0eM1qSPg+gw/rkAWiJ1/3nYv13us3N dx3sqtCdShdKJHyuEvSB8rexypJVJkJoqUXh8kEl6tGrZ05hhY/aMnEaNdaOUXHWJOen 02fy8chOjHZRSsf1X+KRyfCZKdGhWDcALzDexjBecGaGAM0A/q4dr2o0104EY31TjV+6 MyIqwQ/+MAYE86UH0TNONUJMitxm7PUPrf0tx8gu02f2c2LFsmCRzsEHPDZKK1GIQ2+U 7X+alUwRLlCbq6Kd6ddsPFWovBSPwyK6mg7N30e3BiFUoQWP/pZCAkHJEPBBPWgKjy9U bJ+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from :dkim-signature:dkim-signature:date; bh=Qr6lUHBkLuLxAPZNmigB/IH+DYgyFTNeFwwb/3iSrGU=; b=aDMBKc6h2x1KR7ov7RJWiIlrb/1DNtqCxvJm+GzpbB41r5Zcr6nwCdTIPWiApCwRQ8 q1FarLfVb0kRm29KrrFjV1Vjh5itqJznsfLgA/Cha86Fy09R4OThrXbEc5QrCUmlQcjG O4lYQwkf0ExhSejAo1TgFOqMdDMkenNjBAvb3Sx3kGDXbmUocvKwNtpjx5UL3AKokErR ywt5KTfg0fwNGQ/kg1v7ojvBMUad7zYhzM0lWsL+A0mZ5jQeI44gaF4DEHsNNTfOqQUo CzX7Uyg5flZ0K0CG7WXNt3iBStvaCwtRL+F0UCdbRN4HO+MlzCR0xnqzcr1cIKltNekJ CfHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=E6ZKWqWp; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=SvhkcAV3; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ng5si5143970ejb.90.2020.08.24.05.35.49; Mon, 24 Aug 2020 05:36:13 -0700 (PDT) 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; dkim=pass header.i=@linutronix.de header.s=2020 header.b=E6ZKWqWp; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=SvhkcAV3; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726876AbgHXMdA (ORCPT + 99 others); Mon, 24 Aug 2020 08:33:00 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:42494 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726765AbgHXMcx (ORCPT ); Mon, 24 Aug 2020 08:32:53 -0400 Date: Mon, 24 Aug 2020 14:32:47 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1598272369; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Qr6lUHBkLuLxAPZNmigB/IH+DYgyFTNeFwwb/3iSrGU=; b=E6ZKWqWp00DLUq6qhieA0ftDeXWlXvoGZp+Ms2MXHBT9cykq4O2bVe1ZFTAFq+xhHIxbsE 4RTPpH8VY8i3Y4neiCBBTEYGypzpAK8ZaZUwkCLV0s01pohlTwnP+vQ5gn1tZamJ7vj7XZ kFVmie62X2ToAlH+1Gqgu8S+CVN1vh+G6KuvzzA+PWF70quvEDHYJHfvBTk6i7VusoHRTA EGO3YcAgdG2j0mrmdppr9UEUK3GqgRHSFSo8SI0VrKUncAxostzkcwu90gHOChanM4PaT8 GTZu/XBUDc2UNlOqRKpQJ+P3gbxXV/yUfOT1dfwN6I8EDnorpJ9ZP2uTAHiTwg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1598272369; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Qr6lUHBkLuLxAPZNmigB/IH+DYgyFTNeFwwb/3iSrGU=; b=SvhkcAV3b9DAe/L8n9ay7Sewgu+Z90tVOc5pxatliy7JT9kFlC2JIzVvEZY4GbOBMnBC9g Dnxts6GdoyqYGMAA== From: Sebastian Andrzej Siewior To: Lokesh Gidra Cc: Kees Cook , Jonathan Corbet , Peter Xu , Andrea Arcangeli , Andrew Morton , Alexander Viro , Stephen Smalley , Eric Biggers , Daniel Colascione , "Joel Fernandes (Google)" , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, kaleshsingh@google.com, calin@google.com, surenb@google.com, nnk@google.com, jeffv@google.com, kernel-team@android.com, Mike Rapoport , Shaohua Li , Jerome Glisse , Mauro Carvalho Chehab , Johannes Weiner , Mel Gorman , Nitin Gupta , Vlastimil Babka , Iurii Zaikin , Luis Chamberlain , Daniel Colascione Subject: Re: [PATCH v2 1/2] Add UFFD_USER_MODE_ONLY Message-ID: <20200824123247.finquufqpr6i7umb@linutronix.de> References: <20200822014018.913868-1-lokeshgidra@google.com> <20200822014018.913868-2-lokeshgidra@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20200822014018.913868-2-lokeshgidra@google.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020-08-21 18:40:17 [-0700], Lokesh Gidra wrote: > --- a/fs/userfaultfd.c > +++ b/fs/userfaultfd.c > @@ -1966,6 +1969,7 @@ static void init_once_userfaultfd_ctx(void *mem) > > SYSCALL_DEFINE1(userfaultfd, int, flags) > { > + static const int uffd_flags = UFFD_USER_MODE_ONLY; > struct userfaultfd_ctx *ctx; > int fd; Why? Sebastian