aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext2/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext2/inode.c')
-rw-r--r--fs/ext2/inode.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/fs/ext2/inode.c b/fs/ext2/inode.c
index 348805cd4109..2f4dfbcd7696 100644
--- a/fs/ext2/inode.c
+++ b/fs/ext2/inode.c
@@ -765,14 +765,6 @@ ext2_readpages(struct file *file, struct address_space *mapping,
765 return mpage_readpages(mapping, pages, nr_pages, ext2_get_block); 765 return mpage_readpages(mapping, pages, nr_pages, ext2_get_block);
766} 766}
767 767
768int __ext2_write_begin(struct file *file, struct address_space *mapping,
769 loff_t pos, unsigned len, unsigned flags,
770 struct page **pagep, void **fsdata)
771{
772 return block_write_begin_newtrunc(file, mapping, pos, len, flags,
773 pagep, fsdata, ext2_get_block);
774}
775
776static int 768static int
777ext2_write_begin(struct file *file, struct address_space *mapping, 769ext2_write_begin(struct file *file, struct address_space *mapping,
778 loff_t pos, unsigned len, unsigned flags, 770 loff_t pos, unsigned len, unsigned flags,
@@ -781,7 +773,8 @@ ext2_write_begin(struct file *file, struct address_space *mapping,
781 int ret; 773 int ret;
782 774
783 *pagep = NULL; 775 *pagep = NULL;
784 ret = __ext2_write_begin(file, mapping, pos, len, flags, pagep, fsdata); 776 ret = block_write_begin_newtrunc(file, mapping, pos, len, flags,
777 pagep, fsdata, ext2_get_block);
785 if (ret < 0) 778 if (ret < 0)
786 ext2_write_failed(mapping, pos + len); 779 ext2_write_failed(mapping, pos + len);
787 return ret; 780 return ret;