diff options
author | Christoph Hellwig <hch@lst.de> | 2018-06-19 15:10:56 -0700 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2018-06-19 15:10:56 -0700 |
commit | 63899c6f8851c32214b19390254fa1ae90b582df (patch) | |
tree | 4bd0539b5d6ae1bf9d1a9735c2b8a6dff262edd3 /fs/iomap.c | |
parent | 19e0c58f6552638c86395f0717210326fdf14fd2 (diff) |
iomap: add a page_done callback
This will be used by gfs2 to attach data to transactions for the journaled
data mode. But the concept is generic enough that we might be able to
use it for other purposes like encryption/integrity post-processing in the
future.
Based on a patch from Andreas Gruenbacher.
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 'fs/iomap.c')
-rw-r--r-- | fs/iomap.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/iomap.c b/fs/iomap.c index 4aecd7c5dbd8..a1f71e64ea49 100644 --- a/fs/iomap.c +++ b/fs/iomap.c @@ -201,6 +201,9 @@ iomap_write_end(struct inode *inode, loff_t pos, unsigned len, copied, page, NULL); } + if (iomap->page_done) + iomap->page_done(inode, pos, copied, page, iomap); + if (ret < len) iomap_write_failed(inode, pos, len); return ret; |