linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/7][RFC] Introduce fallocate query support mode
@ 2017-09-18 15:52 Lukas Czerner
  2017-09-18 15:52 ` [PATCH 1/7] vfs: " Lukas Czerner
                   ` (6 more replies)
  0 siblings, 7 replies; 26+ messages in thread
From: Lukas Czerner @ 2017-09-18 15:52 UTC (permalink / raw)
  To: linux-fsdevel

Hello,

this is a proposal, followed by implementation, of new fallocate flag I decided
to call "query support" (FALLOC_FL_QUERY_SUPPORT).

Currently there is not way to tell which subset of fallocate operations are
supported by any given file system, so users have to rely on "just knowing"
or trying if it works or not.

This patchset introduces the new FALLOC_FL_QUERY_SUPPORT fallocate mode
implements it in couple of file systems and takes advantage of this new flag in
loop driver where we can finally test specifically for punch hole (and zero
range) rather than just relying on mere existence of fallocate callback.

When FALLOC_FL_QUERY_SUPPORT mode is specified with offset and length set to
zero it returns bitmask with all fallocate mode flags supported for a given
file. Because of this I also had to introduce additional flag for the original
fallocate mode (preallocation: mode = 0).

I expect that in many file systems the implementation will be straightforward
and once we can agree on this I plan to implement this for other file systems
with fallocate support.

In ext4 (and this may be true for other file systems as well) supported modes
can differ from file to file depending on the features (like extents and
encryption). Because of that I decided to make it return all the modes supported
by the particular file, not file system. This might complicate implementation
for some file systems, however I think this will be beneficial.

Thoughts ?

Thanks!
-Lukas

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

end of thread, other threads:[~2017-09-22  8:40 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-18 15:52 [PATCH 0/7][RFC] Introduce fallocate query support mode Lukas Czerner
2017-09-18 15:52 ` [PATCH 1/7] vfs: " Lukas Czerner
2017-09-18 15:52 ` [PATCH 2/7] ext4: Implement " Lukas Czerner
2017-09-18 15:52 ` [PATCH 3/7] ext4: Remove unnecessary S_ISREG checks in fallocate operations Lukas Czerner
2017-09-18 15:52 ` [PATCH 4/7] xfs: Implement fallocate query support mode Lukas Czerner
2017-09-18 17:56   ` Christoph Hellwig
2017-09-19  3:28     ` OGAWA Hirofumi
2017-09-19  8:15     ` Lukas Czerner
2017-09-19 14:13       ` Christoph Hellwig
2017-09-18 20:48   ` Darrick J. Wong
2017-09-18 21:55     ` Andreas Dilger
2017-09-19 14:55       ` Theodore Ts'o
2017-09-19 15:33         ` Lukas Czerner
2017-09-19 15:55         ` Christoph Hellwig
2017-09-19 19:17           ` Florian Weimer
2017-09-19 20:37             ` Christoph Hellwig
2017-09-19 23:17               ` Theodore Ts'o
2017-09-21 13:17                 ` pathconf syscall for linux Lukas Czerner
2017-09-21 13:49                   ` Florian Weimer
2017-09-22  8:38                     ` Lukas Czerner
2017-09-21 13:54                 ` [PATCH 4/7] xfs: Implement fallocate query support mode Florian Weimer
2017-09-22  8:40                   ` Lukas Czerner
2017-09-19  8:20     ` Lukas Czerner
2017-09-18 15:52 ` [PATCH 5/7] fat: " Lukas Czerner
2017-09-18 15:52 ` [PATCH 6/7] gfs2: " Lukas Czerner
2017-09-18 15:52 ` [PATCH 7/7] loop: Check for puch hole and zero range support specifically Lukas Czerner

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).