Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5891259ybi; Wed, 12 Jun 2019 10:11:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqx4N1dzp7V04Dd1r9nxKXCEVbWO2XMzWBigg3Y1Nbc9XwczSsnvw7Np+DZZ+g3mtWijISr6 X-Received: by 2002:a17:90a:2008:: with SMTP id n8mr265394pjc.4.1560359504417; Wed, 12 Jun 2019 10:11:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560359504; cv=none; d=google.com; s=arc-20160816; b=yHMfrlmsRF+5BSMsLVJXofoQbI0ZGD0QFG9E1ZI5/CRc0VNxzYI179+TFlTW8z2xRf /v6nZqITvqR/+PYrMrHHuQR4maSuYT5pVQju1kYZvjqj3K0rvWjc2oHxqS+i5hnYw7RU eAxfc8yHrod3m7r3fvvCAEvkoZtYZ9lz1a5+OuDXymSSq2DNwJsURAFQtb3zeN98xK7u xQOmzyWAPq4f4BQ7k1yNyTOMH/gmd0c/BkTVB7xQpm5TyDf/LuD3Q6kqywHZqFCw7C7C XS0crP/gej+PUPw+dkgGZeraDYlwUGH73T1N83bMddSdXyBoj7D8i8iBGK5ClcYoteFd 1tLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=IvZbRoqVy0I4pzvEu6n62Bm2PCJYWpH1flcTQkqaVao=; b=urY5silYy63rYzHpAOmrliTBxwuFJbkpb453euudOQK5/N+9DvfPuonp/M0lc2Vg/A U36kyhYaPqO48ZqOTV5Ltn/5OHNZNQ6F1xzTGJ/w7hy6lx+nMAZ6arCZj/iFoz1v0jSh mITv/Rk3uRLrDHKRBwAt4muUWx5bm98o9i/FD9RozkoCvpJ9ll5rzIE5oXXFUmsMWTaF nLDlkNh8S6oFuf93iGCOFVtQDiwpUTf0/2omD5DC07oFIH4x7AyTVm2Xstf13s7inJJg I9sGBJSt/OR9oFZ6prf3QstqWWFC5UJAPPCpu0gjX7POjCpIxIE0PYBDl/fNThaDXCfY hefg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-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 q14si203650pls.327.2019.06.12.10.11.29; Wed, 12 Jun 2019 10:11:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405097AbfFLMJM (ORCPT + 99 others); Wed, 12 Jun 2019 08:09:12 -0400 Received: from mx2.suse.de ([195.135.220.15]:44682 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2405581AbfFLMJM (ORCPT ); Wed, 12 Jun 2019 08:09:12 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 83424AE27; Wed, 12 Jun 2019 12:09:09 +0000 (UTC) Received: by quack2.suse.cz (Postfix, from userid 1000) id A86331E4328; Wed, 12 Jun 2019 14:09:07 +0200 (CEST) Date: Wed, 12 Jun 2019 14:09:07 +0200 From: Jan Kara To: Jason Gunthorpe Cc: Jan Kara , Ira Weiny , Dan Williams , Theodore Ts'o , Jeff Layton , Dave Chinner , Matthew Wilcox , linux-xfs@vger.kernel.org, Andrew Morton , John Hubbard , =?iso-8859-1?B?Suly9G1l?= Glisse , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-nvdimm@lists.01.org, linux-ext4@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH RFC 00/10] RDMA/FS DAX truncate proposal Message-ID: <20190612120907.GC14578@quack2.suse.cz> References: <20190606014544.8339-1-ira.weiny@intel.com> <20190606104203.GF7433@quack2.suse.cz> <20190606195114.GA30714@ziepe.ca> <20190606222228.GB11698@iweiny-DESK2.sc.intel.com> <20190607103636.GA12765@quack2.suse.cz> <20190607121729.GA14802@ziepe.ca> <20190607145213.GB14559@iweiny-DESK2.sc.intel.com> <20190612102917.GB14578@quack2.suse.cz> <20190612114721.GB3876@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190612114721.GB3876@ziepe.ca> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Wed 12-06-19 08:47:21, Jason Gunthorpe wrote: > On Wed, Jun 12, 2019 at 12:29:17PM +0200, Jan Kara wrote: > > > > > The main objection to the current ODP & DAX solution is that very > > > > little HW can actually implement it, having the alternative still > > > > require HW support doesn't seem like progress. > > > > > > > > I think we will eventually start seein some HW be able to do this > > > > invalidation, but it won't be universal, and I'd rather leave it > > > > optional, for recovery from truely catastrophic errors (ie my DAX is > > > > on fire, I need to unplug it). > > > > > > Agreed. I think software wise there is not much some of the devices can do > > > with such an "invalidate". > > > > So out of curiosity: What does RDMA driver do when userspace just closes > > the file pointing to RDMA object? It has to handle that somehow by aborting > > everything that's going on... And I wanted similar behavior here. > > It aborts *everything* connected to that file descriptor. Destroying > everything avoids creating inconsistencies that destroying a subset > would create. > > What has been talked about for lease break is not destroying anything > but very selectively saying that one memory region linked to the GUP > is no longer functional. OK, so what I had in mind was that if RDMA app doesn't play by the rules and closes the file with existing pins (and thus layout lease) we would force it to abort everything. Yes, it is disruptive but then the app didn't obey the rule that it has to maintain file lease while holding pins. Thus such situation should never happen unless the app is malicious / buggy. Honza -- Jan Kara SUSE Labs, CR