diff options
author | Matthew Wilcox <willy@infradead.org> | 2023-03-24 21:01:23 +0300 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2023-04-06 20:39:52 +0300 |
commit | c0be8e6f081b3e966e21f52679b2f809b7df10b8 (patch) | |
tree | e7b1ca0f4ccb7fd13cdf0bb9f84f0464db348e6f /fs/ext4/inode.c | |
parent | 0b5a254395dc6db5c38d89e606c0298ed4c9e984 (diff) | |
download | linux-c0be8e6f081b3e966e21f52679b2f809b7df10b8.tar.xz |
ext4: Convert ext4_mpage_readpages() to work on folios
This definitely doesn't include support for large folios; there
are all kinds of assumptions about the number of buffers attached
to a folio. But it does remove several calls to compound_head().
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Link: https://lore.kernel.org/r/20230324180129.1220691-24-willy@infradead.org
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r-- | fs/ext4/inode.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index 9e8afac5c82e..17a6607bcaf2 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -3154,17 +3154,16 @@ out: static int ext4_read_folio(struct file *file, struct folio *folio) { - struct page *page = &folio->page; int ret = -EAGAIN; - struct inode *inode = page->mapping->host; + struct inode *inode = folio->mapping->host; - trace_ext4_readpage(page); + trace_ext4_readpage(&folio->page); if (ext4_has_inline_data(inode)) ret = ext4_readpage_inline(inode, folio); if (ret == -EAGAIN) - return ext4_mpage_readpages(inode, NULL, page); + return ext4_mpage_readpages(inode, NULL, folio); return ret; } |