From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751582AbdHEJuR (ORCPT ); Sat, 5 Aug 2017 05:50:17 -0400 Received: from verein.lst.de ([213.95.11.211]:33731 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751250AbdHEJuP (ORCPT ); Sat, 5 Aug 2017 05:50:15 -0400 Date: Sat, 5 Aug 2017 11:50:13 +0200 From: Christoph Hellwig To: Dan Williams Cc: "Darrick J. Wong" , Jan Kara , "linux-nvdimm@lists.01.org" , Dave Chinner , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, Jeff Moyer , Alexander Viro , Andy Lutomirski , linux-fsdevel , Ross Zwisler , Christoph Hellwig , Linux API Subject: Re: [PATCH v2 0/5] fs, xfs: block map immutable files for dax, dma-to-storage, and swap Message-ID: <20170805095013.GC14930@lst.de> References: <150181368442.32119.13336247800141074356.stgit@dwillia2-desk3.amr.corp.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 03, 2017 at 07:38:11PM -0700, Dan Williams wrote: > [ adding linux-api to the cover letter for notification, will send the > full set to linux-api for v3 ] Just don't send this crap ever again. All the so called use cases in the earlier thread were incorrect and highly dangerous. Promising that the block map is stable is not a useful userspace API, as it the block map is a complete internal implementation detail. We've been through this a few times but let me repeat it: The only sensible API gurantee is one that is observable and usable. so Jan's synchronous page fault flag in one form or another makes perfect sense as it is a clear receipe for the user: you don't have to call msync to persist your mmap writes. This API is not, it guarantees that the block map does not change, but the application has absolutely no point of even knowing about the block map.