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.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no 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 AF61CC433E0 for ; Tue, 12 Jan 2021 21:50:12 +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 55DB12078E for ; Tue, 12 Jan 2021 21:50:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 55DB12078E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org 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-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=1fbUArvj6HzOIf4AC162keUHlYm50Jy+nQLgm7H+WPI=; b=IroU2K4znd/UvGrd2UW1B9lWI YqDaO+iUd2NPQSShc51zFMZXkapbSzGbRlC8HMQf7cO6b+oNzZP19TMhZveRKvGRLN2nVdskBavki WeFEBXYVIpm3A1nLreJTFsgtlRhlAe+wbRFIdqTKI0Edj1CCVRBQTB2/Pb8UqMMCVHF3e+mvWo0iX 18RLuGTq1cN/M00WTMlhL5GzvTKegzcih4SlF9/Q3P8JSgODodv6EeXV//2JW2O4ndeguF10AuI5j p5M8qTvNRqVzsS4DV4Z+LtcRBA4kn/oyTenbyCBiawcrgx4worab6ysp3LFN1V+zH5eHVUz7Y4Q/I 8GO4Hhbuw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kzRWL-00005S-PZ; Tue, 12 Jan 2021 21:48:09 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kzRWI-0008Vc-44 for linux-arm-kernel@lists.infradead.org; Tue, 12 Jan 2021 21:48:07 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id 1DBF42313C; Tue, 12 Jan 2021 21:48:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1610488085; bh=xEYKassPQC4sKkuJ/2fsneFhalU4oSuuI5/rscjtbAE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=icrdld4c54puBOpoMHt9NPZtfqeCBNMviZxMC5FDARPEr9/3jX8GtCDAHsbVBHpxu NB0eNSp/vmkU8PDKa4tkMDYjcVKZ1NybKKK9bfIEwIJIiS2za7N9YaVVSmYDrDDlKl Yois18ZHdKDcmOpujXX4l9WUOxmdNbrBKSD6TfGqSV1mPuvHMkcTINIjtHNqoONxyM zuzGwkrXpGMDjaJBy0XEDfW1GDs79rD4pH7Ygps03ur03fsPjSDRytFmzWpewqdLfc LPbbVt2UQuN3vyhC2nzEH5hQ++y4Eq05d5Ct6komeN41vBqMsNO5W/unjq7rLSzA5W o7W9L+GLIS6VQ== Date: Tue, 12 Jan 2021 21:47:59 +0000 From: Will Deacon To: Linus Torvalds Subject: Re: [PATCH v2 0/3] Create 'old' ptes for faultaround mappings on arm64 with hardware access flag Message-ID: <20210112214759.GC10434@willie-the-truck> References: <20210108171517.5290-1-will@kernel.org> <20210111142402.6euyktmcnpemanf7@box> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210112_164806_280887_F116F5F3 X-CRM114-Status: GOOD ( 18.07 ) 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: Jan Kara , Minchan Kim , Catalin Marinas , Hugh Dickins , Linux Kernel Mailing List , Linux-MM , Vinayak Menon , "Kirill A . Shutemov" , "Kirill A. Shutemov" , Andrew Morton , Android Kernel Team , Linux ARM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Jan 11, 2021 at 11:25:37AM -0800, Linus Torvalds wrote: > On Mon, Jan 11, 2021 at 6:24 AM Kirill A. Shutemov wrote: > > > > I wonder if it would be acceptable to pass down to faultaround a copy > > of vmf, so it mess with it without risking to corrupt the original one? > > I'd almost prefer to split vmf into two parts: the 'this is the fault > info' part and the 'this is the fault handling state' part. > > So the first one would be filled in by the actual page faulter (or > GUP) - and then be 'const' during the lookup, while the second one > would be set up by handle_mm_fault() and would contain that "this is > the current state of my fault state machine" and contain things like > that ->pte thing. > > And then if somebody actually needs to pass in "modified fault state" > (ie that whole "I'm doing fault-around, so I'll use multiple > addresses") they'd never modify the address in the fault info, they'd > just pass the address as an explicit argument (like most cases already > do - the "change addr or flags in vmf" is actually already _fairly_ > rare). Alright then, I'll take another crack at this for v3 and see how far I get. Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel