diff options
Diffstat (limited to 'fs/hfsplus/inode.c')
-rw-r--r-- | fs/hfsplus/inode.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c index 6f7c662174db..37744cf3706a 100644 --- a/fs/hfsplus/inode.c +++ b/fs/hfsplus/inode.c | |||
@@ -27,10 +27,14 @@ static int hfsplus_writepage(struct page *page, struct writeback_control *wbc) | |||
27 | return block_write_full_page(page, hfsplus_get_block, wbc); | 27 | return block_write_full_page(page, hfsplus_get_block, wbc); |
28 | } | 28 | } |
29 | 29 | ||
30 | static int hfsplus_prepare_write(struct file *file, struct page *page, unsigned from, unsigned to) | 30 | static int hfsplus_write_begin(struct file *file, struct address_space *mapping, |
31 | loff_t pos, unsigned len, unsigned flags, | ||
32 | struct page **pagep, void **fsdata) | ||
31 | { | 33 | { |
32 | return cont_prepare_write(page, from, to, hfsplus_get_block, | 34 | *pagep = NULL; |
33 | &HFSPLUS_I(page->mapping->host).phys_size); | 35 | return cont_write_begin(file, mapping, pos, len, flags, pagep, fsdata, |
36 | hfsplus_get_block, | ||
37 | &HFSPLUS_I(mapping->host).phys_size); | ||
34 | } | 38 | } |
35 | 39 | ||
36 | static sector_t hfsplus_bmap(struct address_space *mapping, sector_t block) | 40 | static sector_t hfsplus_bmap(struct address_space *mapping, sector_t block) |
@@ -114,8 +118,8 @@ const struct address_space_operations hfsplus_btree_aops = { | |||
114 | .readpage = hfsplus_readpage, | 118 | .readpage = hfsplus_readpage, |
115 | .writepage = hfsplus_writepage, | 119 | .writepage = hfsplus_writepage, |
116 | .sync_page = block_sync_page, | 120 | .sync_page = block_sync_page, |
117 | .prepare_write = hfsplus_prepare_write, | 121 | .write_begin = hfsplus_write_begin, |
118 | .commit_write = generic_commit_write, | 122 | .write_end = generic_write_end, |
119 | .bmap = hfsplus_bmap, | 123 | .bmap = hfsplus_bmap, |
120 | .releasepage = hfsplus_releasepage, | 124 | .releasepage = hfsplus_releasepage, |
121 | }; | 125 | }; |
@@ -124,8 +128,8 @@ const struct address_space_operations hfsplus_aops = { | |||
124 | .readpage = hfsplus_readpage, | 128 | .readpage = hfsplus_readpage, |
125 | .writepage = hfsplus_writepage, | 129 | .writepage = hfsplus_writepage, |
126 | .sync_page = block_sync_page, | 130 | .sync_page = block_sync_page, |
127 | .prepare_write = hfsplus_prepare_write, | 131 | .write_begin = hfsplus_write_begin, |
128 | .commit_write = generic_commit_write, | 132 | .write_end = generic_write_end, |
129 | .bmap = hfsplus_bmap, | 133 | .bmap = hfsplus_bmap, |
130 | .direct_IO = hfsplus_direct_IO, | 134 | .direct_IO = hfsplus_direct_IO, |
131 | .writepages = hfsplus_writepages, | 135 | .writepages = hfsplus_writepages, |