Message ID | 05ff4f71283e84be8ab1b312864168d89535239f.1351113536.git.rprabhu@wnohang.net (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Thu, Oct 25, 2012 at 02:56:04AM +0530, raghu.prabhu13@gmail.com wrote: > From: Raghavendra D Prabhu <rprabhu@wnohang.net> > > >From 51daa88ebd8e0d437289f589af29d4b39379ea76, page_sync_readahead coalesces > async readahead into its readahead window, so another checking for that again is > not required. > > Version 2: Fixed the incorrect indentation. > > Signed-off-by: Raghavendra D Prabhu <rprabhu@wnohang.net> > --- > fs/btrfs/relocation.c | 4 +--- > mm/filemap.c | 3 +-- > 2 files changed, 2 insertions(+), 5 deletions(-) Reviewed-by: Fengguang Wu <fengguang.wu@intel.com> Thanks! -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c index 776f0aa..8cfa1ab 100644 --- a/fs/btrfs/relocation.c +++ b/fs/btrfs/relocation.c @@ -2996,9 +2996,7 @@ static int relocate_file_extent_cluster(struct inode *inode, ret = -ENOMEM; goto out; } - } - - if (PageReadahead(page)) { + } else if (PageReadahead(page)) { page_cache_async_readahead(inode->i_mapping, ra, NULL, page, index, last_index + 1 - index); diff --git a/mm/filemap.c b/mm/filemap.c index 83efee7..aa440f16 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -1113,8 +1113,7 @@ find_page: page = find_get_page(mapping, index); if (unlikely(page == NULL)) goto no_cached_page; - } - if (PageReadahead(page)) { + } else if (PageReadahead(page)) { page_cache_async_readahead(mapping, ra, filp, page, index, last_index - index);