diff options
author | Christoph Hellwig <hch@lst.de> | 2010-06-04 05:29:57 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2010-08-09 16:47:32 -0400 |
commit | 6e1db88d536adcbbfe562b2d4b7d6425784fff12 (patch) | |
tree | 8cfcb5a6190722db6249b2e4978f39247975abcf /include/linux | |
parent | f4e420dc423148fba637af1ab618fa8896dfb2d6 (diff) |
introduce __block_write_begin
Split up the block_write_begin implementation - __block_write_begin is a new
trivial wrapper for block_prepare_write that always takes an already
allocated page and can be either called from block_write_begin or filesystem
code that already has a page allocated. Remove the handling of already
allocated pages from block_write_begin after switching all callers that
do it to __block_write_begin.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/buffer_head.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/buffer_head.h b/include/linux/buffer_head.h index 7638647f0424..accc9f81bb63 100644 --- a/include/linux/buffer_head.h +++ b/include/linux/buffer_head.h | |||
@@ -209,6 +209,8 @@ int block_write_begin_newtrunc(struct file *, struct address_space *, | |||
209 | int block_write_begin(struct file *, struct address_space *, | 209 | int block_write_begin(struct file *, struct address_space *, |
210 | loff_t, unsigned, unsigned, | 210 | loff_t, unsigned, unsigned, |
211 | struct page **, void **, get_block_t*); | 211 | struct page **, void **, get_block_t*); |
212 | int __block_write_begin(struct page *page, loff_t pos, unsigned len, | ||
213 | get_block_t *get_block); | ||
212 | int block_write_end(struct file *, struct address_space *, | 214 | int block_write_end(struct file *, struct address_space *, |
213 | loff_t, unsigned, unsigned, | 215 | loff_t, unsigned, unsigned, |
214 | struct page *, void *); | 216 | struct page *, void *); |