From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi0-f45.google.com ([209.85.218.45]:34901 "EHLO mail-oi0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753210AbdHXU04 (ORCPT ); Thu, 24 Aug 2017 16:26:56 -0400 Received: by mail-oi0-f45.google.com with SMTP id k77so5264685oib.2 for ; Thu, 24 Aug 2017 13:26:56 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20170824163925.GA28503@lst.de> References: <150353211413.5039.5228914877418362329.stgit@dwillia2-desk3.amr.corp.intel.com> <150353213655.5039.7662200155640827407.stgit@dwillia2-desk3.amr.corp.intel.com> <20170824161152.GB27591@lst.de> <20170824163925.GA28503@lst.de> From: Dan Williams Date: Thu, 24 Aug 2017 13:26:55 -0700 Message-ID: Subject: Re: [PATCH v6 4/5] fs, xfs: introduce MAP_DIRECT for creating block-map-atomic file ranges Content-Type: text/plain; charset="UTF-8" Sender: linux-xfs-owner@vger.kernel.org List-ID: List-Id: xfs To: Christoph Hellwig Cc: Andrew Morton , Jan Kara , "Darrick J. Wong" , Linux API , "linux-nvdimm@lists.01.org" , Dave Chinner , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, Linux MM , Jeff Moyer , Alexander Viro , Andy Lutomirski , linux-fsdevel , Ross Zwisler , xen-devel@lists.xen.org On Thu, Aug 24, 2017 at 9:39 AM, Christoph Hellwig wrote: > On Thu, Aug 24, 2017 at 09:31:17AM -0700, Dan Williams wrote: >> External agent is a DMA device, or a hypervisor like Xen. In the DMA >> case perhaps we can use the fcntl lease mechanism, I'll investigate. >> In the Xen case it actually would need to use fiemap() to discover the >> physical addresses that back the file to setup their M2P tables. >> Here's the discussion where we discovered that physical address >> dependency: >> >> https://lists.xen.org/archives/html/xen-devel/2017-04/msg00419.html > > fiemap does not work to discover physical addresses. If they want > to do anything involving physical address they will need a kernel > driver. True, it's broken with respect to multi-device filesystems and these patches do nothing to fix that problem. Ok, I'm fine to let that use case depend on a kernel driver and just focus on fixing the DMA case.