summaryrefslogtreecommitdiff
path: root/fs/gfs2/bmap.h
diff options
context:
space:
mode:
authorBrian Foster <bfoster@redhat.com>2013-05-17 09:30:32 -0400
committerMiklos Szeredi <mszeredi@suse.cz>2013-05-20 16:58:57 +0200
commit3634a6327815d39dd93e5c44a602daae91c66297 (patch)
treefa8a52812af954f8604ad105263594d9d43c9c46 /fs/gfs2/bmap.h
parentde82b923012ff8790bcfff381eb3ca9069d00f49 (diff)
fuse: truncate pagecache range on hole punch
fuse supports hole punch via the fallocate() FALLOC_FL_PUNCH_HOLE interface. When a hole punch is passed through, the page cache is not cleared and thus allows reading stale data from the cache. This is easily demonstrable (using FOPEN_KEEP_CACHE) by reading a smallish random data file into cache, punching a hole and creating a copy of the file. Drop caches or remount and observe that the original file no longer matches the file copied after the hole punch. The original file contains a zeroed range and the latter file contains stale data. Protect against writepage requests in progress and punch out the associated page cache range after a successful client fs hole punch. Signed-off-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Diffstat (limited to 'fs/gfs2/bmap.h')
0 files changed, 0 insertions, 0 deletions