diff options
-rw-r--r-- | fs/btrfs/scrub.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index 6f913604799d..d64f557ea91e 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c | |||
@@ -3493,7 +3493,6 @@ out: | |||
3493 | 3493 | ||
3494 | static noinline_for_stack int scrub_chunk(struct scrub_ctx *sctx, | 3494 | static noinline_for_stack int scrub_chunk(struct scrub_ctx *sctx, |
3495 | struct btrfs_device *scrub_dev, | 3495 | struct btrfs_device *scrub_dev, |
3496 | u64 chunk_tree, u64 chunk_objectid, | ||
3497 | u64 chunk_offset, u64 length, | 3496 | u64 chunk_offset, u64 length, |
3498 | u64 dev_offset, int is_dev_replace) | 3497 | u64 dev_offset, int is_dev_replace) |
3499 | { | 3498 | { |
@@ -3544,8 +3543,6 @@ int scrub_enumerate_chunks(struct scrub_ctx *sctx, | |||
3544 | struct btrfs_root *root = sctx->dev_root; | 3543 | struct btrfs_root *root = sctx->dev_root; |
3545 | struct btrfs_fs_info *fs_info = root->fs_info; | 3544 | struct btrfs_fs_info *fs_info = root->fs_info; |
3546 | u64 length; | 3545 | u64 length; |
3547 | u64 chunk_tree; | ||
3548 | u64 chunk_objectid; | ||
3549 | u64 chunk_offset; | 3546 | u64 chunk_offset; |
3550 | int ret = 0; | 3547 | int ret = 0; |
3551 | int slot; | 3548 | int slot; |
@@ -3609,8 +3606,6 @@ int scrub_enumerate_chunks(struct scrub_ctx *sctx, | |||
3609 | if (found_key.offset + length <= start) | 3606 | if (found_key.offset + length <= start) |
3610 | goto skip; | 3607 | goto skip; |
3611 | 3608 | ||
3612 | chunk_tree = btrfs_dev_extent_chunk_tree(l, dev_extent); | ||
3613 | chunk_objectid = btrfs_dev_extent_chunk_objectid(l, dev_extent); | ||
3614 | chunk_offset = btrfs_dev_extent_chunk_offset(l, dev_extent); | 3609 | chunk_offset = btrfs_dev_extent_chunk_offset(l, dev_extent); |
3615 | 3610 | ||
3616 | /* | 3611 | /* |
@@ -3643,9 +3638,8 @@ int scrub_enumerate_chunks(struct scrub_ctx *sctx, | |||
3643 | dev_replace->cursor_right = found_key.offset + length; | 3638 | dev_replace->cursor_right = found_key.offset + length; |
3644 | dev_replace->cursor_left = found_key.offset; | 3639 | dev_replace->cursor_left = found_key.offset; |
3645 | dev_replace->item_needs_writeback = 1; | 3640 | dev_replace->item_needs_writeback = 1; |
3646 | ret = scrub_chunk(sctx, scrub_dev, chunk_tree, chunk_objectid, | 3641 | ret = scrub_chunk(sctx, scrub_dev, chunk_offset, length, |
3647 | chunk_offset, length, found_key.offset, | 3642 | found_key.offset, is_dev_replace); |
3648 | is_dev_replace); | ||
3649 | 3643 | ||
3650 | /* | 3644 | /* |
3651 | * flush, submit all pending read and write bios, afterwards | 3645 | * flush, submit all pending read and write bios, afterwards |