summaryrefslogtreecommitdiff
path: root/fs/ext4/inode.c
diff options
context:
space:
mode:
authorTheodore Ts'o <tytso@mit.edu>2015-04-08 07:00:32 +0300
committerTheodore Ts'o <tytso@mit.edu>2015-04-08 07:00:32 +0300
commitf64e02fe9bc6a359cab95632b33900094d225ae1 (patch)
treebbaa7c514a5b6d7371760ac3ad367586f4e983f0 /fs/ext4/inode.c
parente12fb97222fc41e8442896934f76d39ef99b590a (diff)
downloadlinux-f64e02fe9bc6a359cab95632b33900094d225ae1.tar.xz
ext4 crypto: add ext4_mpage_readpages()
This takes code from fs/mpage.c and optimizes it for ext4. Its primary reason is to allow us to more easily add encryption to ext4's read path in an efficient manner. Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r--fs/ext4/inode.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index ff0c111e52eb..cd3009152ae2 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -2820,7 +2820,7 @@ static int ext4_readpage(struct file *file, struct page *page)
ret = ext4_readpage_inline(inode, page);
if (ret == -EAGAIN)
- return mpage_readpage(page, ext4_get_block);
+ return ext4_mpage_readpages(page->mapping, NULL, page, 1);
return ret;
}
@@ -2835,7 +2835,7 @@ ext4_readpages(struct file *file, struct address_space *mapping,
if (ext4_has_inline_data(inode))
return 0;
- return mpage_readpages(mapping, pages, nr_pages, ext4_get_block);
+ return ext4_mpage_readpages(mapping, pages, NULL, nr_pages);
}
static void ext4_invalidatepage(struct page *page, unsigned int offset,