diff options
author | Nikolay Borisov <nborisov@suse.com> | 2020-09-14 12:37:11 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2020-10-07 13:13:21 +0300 |
commit | fd513000eb279347df1f5a7ce720ae66b4ac3b1b (patch) | |
tree | a8e0e57a058660cb1df631a09e26eadbab9b712e /fs/btrfs | |
parent | 6f15af6060057babf03d3b0dce2b0d7a9258620c (diff) | |
download | linux-fd513000eb279347df1f5a7ce720ae66b4ac3b1b.tar.xz |
btrfs: sink mirror_num argument in __do_readpage
It's always set to 0 by the 2 callers so move it inside __do_readpage.
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/extent_io.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 1c959d66195c..1ef857c0d784 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -3142,9 +3142,8 @@ __get_extent_map(struct inode *inode, struct page *page, size_t pg_offset, * return 0 on success, otherwise return error */ static int __do_readpage(struct page *page, struct extent_map **em_cached, - struct bio **bio, int mirror_num, - unsigned long *bio_flags, unsigned int read_flags, - u64 *prev_em_start) + struct bio **bio, unsigned long *bio_flags, + unsigned int read_flags, u64 *prev_em_start) { struct inode *inode = page->mapping->host; u64 start = page_offset(page); @@ -3322,7 +3321,7 @@ static int __do_readpage(struct page *page, struct extent_map **em_cached, ret = submit_extent_page(REQ_OP_READ | read_flags, NULL, page, offset, disk_io_size, pg_offset, bio, - end_bio_extent_readpage, mirror_num, + end_bio_extent_readpage, 0, *bio_flags, this_bio_flag, force_bio_submit); @@ -3359,7 +3358,7 @@ static inline void contiguous_readpages(struct page *pages[], int nr_pages, btrfs_lock_and_flush_ordered_range(inode, start, end, NULL); for (index = 0; index < nr_pages; index++) { - __do_readpage(pages[index], em_cached, bio, 0, bio_flags, + __do_readpage(pages[index], em_cached, bio, bio_flags, REQ_RAHEAD, prev_em_start); put_page(pages[index]); } @@ -3375,7 +3374,7 @@ int extent_read_full_page(struct page *page, struct bio **bio, btrfs_lock_and_flush_ordered_range(inode, start, end, NULL); - ret = __do_readpage(page, NULL, bio, 0, bio_flags, 0, NULL); + ret = __do_readpage(page, NULL, bio, bio_flags, 0, NULL); return ret; } |