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=-5.6 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING, SPF_HELO_NONE,SPF_PASS 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 55193C34031 for ; Tue, 18 Feb 2020 04:01:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 26787206EF for ; Tue, 18 Feb 2020 04:01:52 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="V3PJiyBo" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726299AbgBRD72 (ORCPT ); Mon, 17 Feb 2020 22:59:28 -0500 Received: from mail-lf1-f65.google.com ([209.85.167.65]:38951 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726257AbgBRD71 (ORCPT ); Mon, 17 Feb 2020 22:59:27 -0500 Received: by mail-lf1-f65.google.com with SMTP id t23so13405776lfk.6 for ; Mon, 17 Feb 2020 19:59:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=LYNOedp5wMrP0IW+gzyF6blmcFzT2PovuB4hmH3kGKQ=; b=V3PJiyBoVL2i5p30BlAXTkxAxZqLFFWaZJilC7w3y7idiZXJubLT3KluMGNkOBuMF7 AUiAvgjsqm39dlayPng3hQ2uf8nC34jjcmhoxI9PDnEA9mNK4I70k6PIQAnya+3qZlkD wbcvyBvYnPOIaGrx7Oj8p+AVjcddTlZV9oazO2n/Lq9LQ0F0flonfVYpn2mmPm6HYILB i1+n+gvOvZt+MuPzRU2KtLy+qJVLLHMlmpjMe2cEw39dxhh4ucotU9OtST7/gErOWIk5 +fAOxw0m3RFFL7xiP4zN2qmsHQiJeOikfekvilXrdEUAd4wNAYhuuR8+NdaNGvoJTH9E /Aww== 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=LYNOedp5wMrP0IW+gzyF6blmcFzT2PovuB4hmH3kGKQ=; b=T8xtfd9gXVNuY1N8Hj9hCuGOQQuTwy5j1UviVaCQGGC0LiS5433cgVi7bJUgiU3hh0 KsLq4pGldfX/lekk2RIQG+BokH/7cnClN2yxPjbEqh8xF5yNYxFK2PlQCnVN5dOEyEj+ UAqi8srq13VEVv/gT+rGznx9bhSU328OX/cs63bT5WKVCMQyYTQDm3B/nuIpq+cKw5nO tHgkKbks8TOrtq5qitmrM8V2MnLI0yipE5R5ykZYgyFW/5rs244Qhx9RsBNmTXY66rwQ nlKuQtrDXPs4Ut8vMzgS+BVYIrpMJpcy8Hn6ZGcGOu6RNQrDqcHt9vvl7fDOemQ7Xzjf GW3Q== X-Gm-Message-State: APjAAAWKNMEWMRtcIL6t5QqPtBj4Pje+7unItOEfiO627epCuINcWKNv 7yLnyBawDBW4917wJcVszUQXNNwPEcraBRmkke25cilrjtE= X-Google-Smtp-Source: APXvYqzVnWobrCVkpHNitkiG+Y6rB+7ON2gu3Rc1nxbC4gW9PquITmuADPvGJ3x/bpNvYzjrje0Gkit9nXSJoo8bD5g= X-Received: by 2002:ac2:592e:: with SMTP id v14mr9554813lfi.73.1581998364215; Mon, 17 Feb 2020 19:59:24 -0800 (PST) MIME-Version: 1.0 References: <20190620022008.19172-1-peterx@redhat.com> In-Reply-To: <20190620022008.19172-1-peterx@redhat.com> From: Bobby Powers Date: Mon, 17 Feb 2020 19:59:12 -0800 Message-ID: Subject: Re: [PATCH v5 00/25] userfaultfd: write protection support To: Peter Xu Cc: linux-mm@kvack.org, Kernel development list , David Hildenbrand , Hugh Dickins , Maya Gokhale , Jerome Glisse , Pavel Emelyanov , Johannes Weiner , Martin Cracauer , Denis Plotnikov , Shaohua Li , Andrea Arcangeli , Mike Kravetz , Marty McFadden , Mike Rapoport , Mel Gorman , "Kirill A . Shutemov" , "Dr . David Alan Gilbert" 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 Wed, Jun 19, 2019 at 7:20 PM Peter Xu wrote: > This series implements initial write protection support for > userfaultfd. Currently both shmem and hugetlbfs are not supported > yet, but only anonymous memory. This is the 4nd version of it. > > The latest code can also be found at: > > https://github.com/xzpeter/linux/tree/uffd-wp-merged Hi Peter - I ported the branch you had above on top of v5.4.20 (what I happened to be running locally), and fixed one issue that was causing crashes for me: https://github.com/bpowers/linux/commit/61086b5a0fa4aeb494e86d999926551a4323b84f I wrote a small test program here: https://github.com/plasma-umass/Mesh/blob/master/src/test/userfaultfd-kernel-copy.cc and write protection support for userfaultfd (with eventual shmem support) would be _hugely_ helpful for a userspace memory allocator I'm working on. Is there anything I can do to help get this considered for mainline? We have some time before the 5.7 merge window opens up. Tested-by: Bobby Powers 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=-5.6 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING, SPF_HELO_NONE,SPF_PASS 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 B4F75C34031 for ; Tue, 18 Feb 2020 03:59:27 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 6A8C9206EF for ; Tue, 18 Feb 2020 03:59:27 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="V3PJiyBo" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6A8C9206EF Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E1EB06B0007; Mon, 17 Feb 2020 22:59:26 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id DA73D6B0008; Mon, 17 Feb 2020 22:59:26 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C6F276B000A; Mon, 17 Feb 2020 22:59:26 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0036.hostedemail.com [216.40.44.36]) by kanga.kvack.org (Postfix) with ESMTP id A84FE6B0007 for ; Mon, 17 Feb 2020 22:59:26 -0500 (EST) Received: from smtpin17.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 40008180AD807 for ; Tue, 18 Feb 2020 03:59:26 +0000 (UTC) X-FDA: 76501893132.17.rate89_353db64467700 X-HE-Tag: rate89_353db64467700 X-Filterd-Recvd-Size: 4260 Received: from mail-lf1-f67.google.com (mail-lf1-f67.google.com [209.85.167.67]) by imf01.hostedemail.com (Postfix) with ESMTP for ; Tue, 18 Feb 2020 03:59:25 +0000 (UTC) Received: by mail-lf1-f67.google.com with SMTP id 203so13373465lfa.12 for ; Mon, 17 Feb 2020 19:59:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=LYNOedp5wMrP0IW+gzyF6blmcFzT2PovuB4hmH3kGKQ=; b=V3PJiyBoVL2i5p30BlAXTkxAxZqLFFWaZJilC7w3y7idiZXJubLT3KluMGNkOBuMF7 AUiAvgjsqm39dlayPng3hQ2uf8nC34jjcmhoxI9PDnEA9mNK4I70k6PIQAnya+3qZlkD wbcvyBvYnPOIaGrx7Oj8p+AVjcddTlZV9oazO2n/Lq9LQ0F0flonfVYpn2mmPm6HYILB i1+n+gvOvZt+MuPzRU2KtLy+qJVLLHMlmpjMe2cEw39dxhh4ucotU9OtST7/gErOWIk5 +fAOxw0m3RFFL7xiP4zN2qmsHQiJeOikfekvilXrdEUAd4wNAYhuuR8+NdaNGvoJTH9E /Aww== 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=LYNOedp5wMrP0IW+gzyF6blmcFzT2PovuB4hmH3kGKQ=; b=dDUR/g+tHjOpifMx/qNucFDmG1OGbSlItyT1KEuOmT0FiLxRbmtLLB9eFnY0y09wkX UtVL8xaukoZoXz3Ax0VVp0nONWqaEWegGMhlCYjI1Mc1q3MKEdRNry5Cwpt112W8A47V JBd/dPz9FSgox9I0q41PKS/lat+5YmEvsU+NHKAcTpCRAD0/FsebedYnhowCe/5xsXtu R7YozbxYiD15nvSsb7HtoRj0NDMXOJMe7Zx2d+wmnwuG2FBZM6n1BgpQWvRhCD/0ZGD1 IEn1eS+pI511Sd5uxIWnIYp7+O+vHWQZHPZyuYwK1ZJdYtcCiN+IuJ7Ax9nvf+ya5rbV nIdQ== X-Gm-Message-State: APjAAAW7GEEa+OwTgiq7/EPysynz71eDR7UudB4SAGmva7AkapN0peSy JT0dUw0ZA3XAjF2FK1NXHxxPQhkF845jt6+NYg8= X-Google-Smtp-Source: APXvYqzVnWobrCVkpHNitkiG+Y6rB+7ON2gu3Rc1nxbC4gW9PquITmuADPvGJ3x/bpNvYzjrje0Gkit9nXSJoo8bD5g= X-Received: by 2002:ac2:592e:: with SMTP id v14mr9554813lfi.73.1581998364215; Mon, 17 Feb 2020 19:59:24 -0800 (PST) MIME-Version: 1.0 References: <20190620022008.19172-1-peterx@redhat.com> In-Reply-To: <20190620022008.19172-1-peterx@redhat.com> From: Bobby Powers Date: Mon, 17 Feb 2020 19:59:12 -0800 Message-ID: Subject: Re: [PATCH v5 00/25] userfaultfd: write protection support To: Peter Xu Cc: linux-mm@kvack.org, Kernel development list , David Hildenbrand , Hugh Dickins , Maya Gokhale , Jerome Glisse , Pavel Emelyanov , Johannes Weiner , Martin Cracauer , Denis Plotnikov , Shaohua Li , Andrea Arcangeli , Mike Kravetz , Marty McFadden , Mike Rapoport , Mel Gorman , "Kirill A . Shutemov" , "Dr . David Alan Gilbert" Content-Type: text/plain; charset="UTF-8" X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Jun 19, 2019 at 7:20 PM Peter Xu wrote: > This series implements initial write protection support for > userfaultfd. Currently both shmem and hugetlbfs are not supported > yet, but only anonymous memory. This is the 4nd version of it. > > The latest code can also be found at: > > https://github.com/xzpeter/linux/tree/uffd-wp-merged Hi Peter - I ported the branch you had above on top of v5.4.20 (what I happened to be running locally), and fixed one issue that was causing crashes for me: https://github.com/bpowers/linux/commit/61086b5a0fa4aeb494e86d999926551a4323b84f I wrote a small test program here: https://github.com/plasma-umass/Mesh/blob/master/src/test/userfaultfd-kernel-copy.cc and write protection support for userfaultfd (with eventual shmem support) would be _hugely_ helpful for a userspace memory allocator I'm working on. Is there anything I can do to help get this considered for mainline? We have some time before the 5.7 merge window opens up. Tested-by: Bobby Powers