aboutsummaryrefslogtreecommitdiffstats
path: root/fs/fat/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fat/inode.c')
-rw-r--r--fs/fat/inode.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/fs/fat/inode.c b/fs/fat/inode.c
index 897312616b0a..f502c6b8cb49 100644
--- a/fs/fat/inode.c
+++ b/fs/fat/inode.c
@@ -18,6 +18,7 @@
18#include <linux/seq_file.h> 18#include <linux/seq_file.h>
19#include <linux/msdos_fs.h> 19#include <linux/msdos_fs.h>
20#include <linux/pagemap.h> 20#include <linux/pagemap.h>
21#include <linux/mpage.h>
21#include <linux/buffer_head.h> 22#include <linux/buffer_head.h>
22#include <linux/mount.h> 23#include <linux/mount.h>
23#include <linux/vfs.h> 24#include <linux/vfs.h>
@@ -90,9 +91,21 @@ static int fat_writepage(struct page *page, struct writeback_control *wbc)
90 return block_write_full_page(page, fat_get_block, wbc); 91 return block_write_full_page(page, fat_get_block, wbc);
91} 92}
92 93
94static int fat_writepages(struct address_space *mapping,
95 struct writeback_control *wbc)
96{
97 return mpage_writepages(mapping, wbc, fat_get_block);
98}
99
93static int fat_readpage(struct file *file, struct page *page) 100static int fat_readpage(struct file *file, struct page *page)
94{ 101{
95 return block_read_full_page(page, fat_get_block); 102 return mpage_readpage(page, fat_get_block);
103}
104
105static int fat_readpages(struct file *file, struct address_space *mapping,
106 struct list_head *pages, unsigned nr_pages)
107{
108 return mpage_readpages(mapping, pages, nr_pages, fat_get_block);
96} 109}
97 110
98static int fat_prepare_write(struct file *file, struct page *page, 111static int fat_prepare_write(struct file *file, struct page *page,
@@ -122,7 +135,9 @@ static sector_t _fat_bmap(struct address_space *mapping, sector_t block)
122 135
123static struct address_space_operations fat_aops = { 136static struct address_space_operations fat_aops = {
124 .readpage = fat_readpage, 137 .readpage = fat_readpage,
138 .readpages = fat_readpages,
125 .writepage = fat_writepage, 139 .writepage = fat_writepage,
140 .writepages = fat_writepages,
126 .sync_page = block_sync_page, 141 .sync_page = block_sync_page,
127 .prepare_write = fat_prepare_write, 142 .prepare_write = fat_prepare_write,
128 .commit_write = fat_commit_write, 143 .commit_write = fat_commit_write,