[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALCETrX0n0-JxJbisrVnM6QME3uToW_x26xN3Z-t0-1yDvWn4Q@mail.gmail.com>
Date: Wed, 21 Jun 2017 21:07:57 -0700
From: Andy Lutomirski <luto@...nel.org>
To: Dave Chinner <david@...morbit.com>
Cc: Andy Lutomirski <luto@...nel.org>,
Dan Williams <dan.j.williams@...el.com>,
Ross Zwisler <ross.zwisler@...ux.intel.com>,
"Rudoff, Andy" <andy.rudoff@...el.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Jan Kara <jack@...e.cz>,
linux-nvdimm <linux-nvdimm@...ts.01.org>,
Linux API <linux-api@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
Jeff Moyer <jmoyer@...hat.com>,
Linux FS Devel <linux-fsdevel@...r.kernel.org>,
Christoph Hellwig <hch@....de>
Subject: Re: [RFC PATCH 2/2] mm, fs: daxfile, an interface for
byte-addressable updates to pmem
On Wed, Jun 21, 2017 at 5:02 PM, Dave Chinner <david@...morbit.com> wrote:
>
> You seem to be calling the "fdatasync on every page fault" the
It's the opposite of fdatasync(). It needs to sync whatever metadata
is needed to find the data. The data doesn't need to be synced.
> "lightweight" option. That's the brute-force-with-big-hammer
> solution - it's most definitely not lightweight as every page fault
> has extra overhead to call ->fsync(). Sure, the API is simple, but
> the runtime overhead is significant.
It's lightweight in terms of its impact on the filesystem. It doesn't
need any persistent setup -- you can just use it.
> Even if you are considering the complexity of the APIs, it's hardly
> a "heavyweight" when it only requires a single call to fallocate()
> before mmap() to set up the immutable extents on the file...
So what would the exact semantics be? In particular, how can it fail?
If I do the fallocate(), is it absolutely promised that the extent
map won't get out of sync between what mmap sees and what's on disk?
Do user programs need to worry about colliding with each other when
one does fallocate() to DAXify a file and the other does fallocate()
to unDAXify a file? Does this particular fallocate() call still keep
its effect after a reboot?
These issues are why I think it would be nicer to have an API that
makes a particular mapping or fd be unconditionally *correct* and then
to provide something else that makes it avoid latency spikes.
Is there an actual concrete proposal that's reviewable?
Powered by blists - more mailing lists