aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/aops.h
diff options
context:
space:
mode:
authorMark Fasheh <mark.fasheh@oracle.com>2007-02-16 14:46:50 -0500
committerMark Fasheh <mark.fasheh@oracle.com>2007-04-26 18:02:20 -0400
commit60b11392f1a09433740bda3048202213daa27736 (patch)
treea8687fcb0ce62b130b732d663b54a984564d28b2 /fs/ocfs2/aops.h
parent25baf2da1473d9dcde1a4c7b0ab26e7d67d9bf62 (diff)
ocfs2: zero tail of sparse files on truncate
Since we don't zero on extend anymore, truncate needs to be fixed up to zero the part of a file between i_size and and end of it's cluster. Otherwise a subsequent extend could expose bad data. This introduced a new helper, which can be used in ocfs2_write(). Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Diffstat (limited to 'fs/ocfs2/aops.h')
-rw-r--r--fs/ocfs2/aops.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/fs/ocfs2/aops.h b/fs/ocfs2/aops.h
index eeb2c42483e8..7d94071f0ab7 100644
--- a/fs/ocfs2/aops.h
+++ b/fs/ocfs2/aops.h
@@ -30,6 +30,18 @@ handle_t *ocfs2_start_walk_page_trans(struct inode *inode,
30 unsigned from, 30 unsigned from,
31 unsigned to); 31 unsigned to);
32 32
33int ocfs2_map_page_blocks(struct page *page, u64 *p_blkno,
34 struct inode *inode, unsigned int from,
35 unsigned int to, int new);
36
37int walk_page_buffers( handle_t *handle,
38 struct buffer_head *head,
39 unsigned from,
40 unsigned to,
41 int *partial,
42 int (*fn)( handle_t *handle,
43 struct buffer_head *bh));
44
33struct ocfs2_write_ctxt; 45struct ocfs2_write_ctxt;
34typedef int (ocfs2_page_writer)(struct inode *, struct ocfs2_write_ctxt *, 46typedef int (ocfs2_page_writer)(struct inode *, struct ocfs2_write_ctxt *,
35 u64 *, unsigned int *, unsigned int *); 47 u64 *, unsigned int *, unsigned int *);