linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Write atomicity guarantees
@ 2014-04-24 17:39 Matthew Wilcox
  2014-04-24 18:03 ` Chris Mason
  0 siblings, 1 reply; 7+ messages in thread
From: Matthew Wilcox @ 2014-04-24 17:39 UTC (permalink / raw)
  To: Martin K. Petersen, Theodore Ts'o, Dave Chinner, Chris Mason
  Cc: linux-fsdevel


NVMe allows the drive to tell the host what atomicity guarantees it
provides for a write command.  At the moment, I don't think Linux has
a way for the driver to pass that information up to the filesystem.

The value that is most interesting to report is Atomic Write Unit Power
Fail ("if you send a write no larger than this, the drive guarantees to
write all of it or none of it"), minimum value 1 sector. [1]

There's a proposal before the NVMe workgroup to add a boundary size/offset
to modify AWUPF ("except if you cross this boundary, then AWUPF is not
guaranteed").  Think RAID stripe crossing.

So, three questions.  Is there somewhere already to pass boundary
information up to the filesystem?  Can filesystems make use of a larger
atomic write unit than a single sector?  And, if the device is internally
a RAID device, is knowing the boundary size/offset useful?


[1] There is also Atomic Write Unit Normal ("if you send two writes,
neither of which is larger than this, subsequent reads will get either
one or the other, not a mixture of both"), which I don't think we care
about because the page cache prevents us from sending two writes which
overlap with each other.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-04-24 19:27 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-24 17:39 Write atomicity guarantees Matthew Wilcox
2014-04-24 18:03 ` Chris Mason
2014-04-24 18:23   ` Dan Williams
2014-04-24 18:50     ` Chris Mason
2014-04-24 19:27       ` Dave Chinner
     [not found]   ` <CAN7X1U=yjcxW16C8H9G5WWEOj1S5Wh0O26WpE5QrC38biRShtw@mail.gmail.com>
2014-04-24 18:25     ` Matthew Wilcox
2014-04-24 18:44       ` Chris Mason

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).