@@ -2180,16 +2180,11 @@ int block_write_end(struct file *file, struct address_space *mapping,
}
EXPORT_SYMBOL(block_write_end);
-int generic_write_end(struct file *file, struct address_space *mapping,
- loff_t pos, unsigned len, unsigned copied,
- struct page *page, void *fsdata)
+int inode_extend_page(struct inode *inode, loff_t pos,
+ unsigned copied, struct page *page)
{
- struct inode *inode = mapping->host;
loff_t old_size = inode->i_size;
int i_size_changed = 0;
-
- copied = block_write_end(file, mapping, pos, len, copied, page, fsdata);
-
/*
* No need to use i_size_read() here, the i_size
* cannot change under us because we hold i_mutex.
@@ -2218,6 +2213,17 @@ int generic_write_end(struct file *file, struct address_space *mapping,
return copied;
}
+EXPORT_SYMBOL(inode_extend_page);
+
+int generic_write_end(struct file *file, struct address_space *mapping,
+ loff_t pos, unsigned len, unsigned copied,
+ struct page *page, void *fsdata)
+{
+ struct inode *inode = mapping->host;
+ copied = block_write_end(file, mapping, pos, len, copied, page, fsdata);
+ return inode_extend_page(inode, pos, copied, page);
+
+}
EXPORT_SYMBOL(generic_write_end);
/*
@@ -229,6 +229,7 @@ int __block_write_begin(struct page *page, loff_t pos, unsigned len,
int block_write_end(struct file *, struct address_space *,
loff_t, unsigned, unsigned,
struct page *, void *);
+int inode_extend_page(struct inode *, loff_t, unsigned, struct page*);
int generic_write_end(struct file *, struct address_space *,
loff_t, unsigned, unsigned,
struct page *, void *);