diff options
author | Andreas Gruenbacher <agruenba@redhat.com> | 2017-06-29 11:43:21 -0700 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2017-07-02 22:46:13 -0700 |
commit | 0ed3b0d45fd39142e418220f518c8959c1a5f596 (patch) | |
tree | 5c629e3654c2959be05fee0875952b419a5718a9 /include/linux/iomap.h | |
parent | 334fd34d76f237c0ee58dfc400d2c4e34d660544 (diff) | |
download | lwn-0ed3b0d45fd39142e418220f518c8959c1a5f596.tar.gz lwn-0ed3b0d45fd39142e418220f518c8959c1a5f596.zip |
vfs: Add iomap_seek_hole and iomap_seek_data helpers
Filesystems can use this for implementing lseek SEEK_HOLE / SEEK_DATA
support via iomap.
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
[hch: split functions, coding style cleanups]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'include/linux/iomap.h')
-rw-r--r-- | include/linux/iomap.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/iomap.h b/include/linux/iomap.h index f753e788da31..8a03f5dcd89b 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h @@ -83,6 +83,10 @@ int iomap_truncate_page(struct inode *inode, loff_t pos, bool *did_zero, int iomap_page_mkwrite(struct vm_fault *vmf, const struct iomap_ops *ops); int iomap_fiemap(struct inode *inode, struct fiemap_extent_info *fieinfo, loff_t start, loff_t len, const struct iomap_ops *ops); +loff_t iomap_seek_hole(struct inode *inode, loff_t offset, + const struct iomap_ops *ops); +loff_t iomap_seek_data(struct inode *inode, loff_t offset, + const struct iomap_ops *ops); /* * Flags for direct I/O ->end_io: |