mirror of https://gitee.com/openkylin/linux.git
btrfs: remove unused parameter from submit_extent_page
This used to hold number of maximum pages to allocate, but this is now limited by BIO_MAX_PAGES. The local are now unused and removed as well. Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
f1e3026192
commit
c2df8bb43f
|
@ -2759,7 +2759,6 @@ static int submit_extent_page(int op, int op_flags, struct extent_io_tree *tree,
|
|||
size_t size, unsigned long offset,
|
||||
struct block_device *bdev,
|
||||
struct bio **bio_ret,
|
||||
unsigned long max_pages,
|
||||
bio_end_io_t end_io_func,
|
||||
int mirror_num,
|
||||
unsigned long prev_bio_flags,
|
||||
|
@ -2925,7 +2924,6 @@ static int __do_readpage(struct extent_io_tree *tree,
|
|||
}
|
||||
}
|
||||
while (cur <= end) {
|
||||
unsigned long pnr = (last_byte >> PAGE_SHIFT) + 1;
|
||||
bool force_bio_submit = false;
|
||||
|
||||
if (cur >= last_byte) {
|
||||
|
@ -3060,10 +3058,9 @@ static int __do_readpage(struct extent_io_tree *tree,
|
|||
continue;
|
||||
}
|
||||
|
||||
pnr -= page->index;
|
||||
ret = submit_extent_page(REQ_OP_READ, read_flags, tree, NULL,
|
||||
page, sector, disk_io_size, pg_offset,
|
||||
bdev, bio, pnr,
|
||||
bdev, bio,
|
||||
end_bio_extent_readpage, mirror_num,
|
||||
*bio_flags,
|
||||
this_bio_flag,
|
||||
|
@ -3366,7 +3363,6 @@ static noinline_for_stack int __extent_writepage_io(struct inode *inode,
|
|||
|
||||
while (cur <= end) {
|
||||
u64 em_end;
|
||||
unsigned long max_nr;
|
||||
|
||||
if (cur >= i_size) {
|
||||
if (tree->ops && tree->ops->writepage_end_io_hook)
|
||||
|
@ -3423,8 +3419,6 @@ static noinline_for_stack int __extent_writepage_io(struct inode *inode,
|
|||
continue;
|
||||
}
|
||||
|
||||
max_nr = (i_size >> PAGE_SHIFT) + 1;
|
||||
|
||||
set_range_writeback(tree, cur, cur + iosize - 1);
|
||||
if (!PageWriteback(page)) {
|
||||
btrfs_err(BTRFS_I(inode)->root->fs_info,
|
||||
|
@ -3434,7 +3428,7 @@ static noinline_for_stack int __extent_writepage_io(struct inode *inode,
|
|||
|
||||
ret = submit_extent_page(REQ_OP_WRITE, write_flags, tree, wbc,
|
||||
page, sector, iosize, pg_offset,
|
||||
bdev, &epd->bio, max_nr,
|
||||
bdev, &epd->bio,
|
||||
end_bio_extent_writepage,
|
||||
0, 0, 0, false);
|
||||
if (ret) {
|
||||
|
@ -3751,7 +3745,7 @@ static noinline_for_stack int write_one_eb(struct extent_buffer *eb,
|
|||
set_page_writeback(p);
|
||||
ret = submit_extent_page(REQ_OP_WRITE, write_flags, tree, wbc,
|
||||
p, offset >> 9, PAGE_SIZE, 0, bdev,
|
||||
&epd->bio, -1,
|
||||
&epd->bio,
|
||||
end_bio_extent_buffer_writepage,
|
||||
0, epd->bio_flags, bio_flags, false);
|
||||
epd->bio_flags = bio_flags;
|
||||
|
|
Loading…
Reference in New Issue