diff options
author | Qu Wenruo <wqu@suse.com> | 2022-04-01 13:23:26 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2022-05-16 17:03:15 +0200 |
commit | 6346f6bf16a0fd76f5f50077c469fa8e88724996 (patch) | |
tree | 3759482324c21ac7e6a832fdb4cb7c54fe55c0c7 /fs/btrfs/scrub.c | |
parent | btrfs: raid56: open code rbio_stripe_page_index() (diff) | |
download | linux-6346f6bf16a0fd76f5f50077c469fa8e88724996.tar.xz linux-6346f6bf16a0fd76f5f50077c469fa8e88724996.zip |
btrfs: raid56: make raid56_add_scrub_pages() subpage compatible
This requires one extra parameter @pgoff for the function.
In the current code base, scrub is still one page per sector, thus the
new parameter will always be 0.
It needs the extra subpage scrub optimization code to fully take
advantage.
Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to '')
-rw-r--r-- | fs/btrfs/scrub.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index b79a3221d7af..6ac711fa793c 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c @@ -2205,7 +2205,11 @@ static void scrub_missing_raid56_pages(struct scrub_block *sblock) for (i = 0; i < sblock->sector_count; i++) { struct scrub_sector *sector = sblock->sectors[i]; - raid56_add_scrub_pages(rbio, sector->page, sector->logical); + /* + * For now, our scrub is still one page per sector, so pgoff + * is always 0. + */ + raid56_add_scrub_pages(rbio, sector->page, 0, sector->logical); } btrfs_init_work(&sblock->work, scrub_missing_raid56_worker, NULL, NULL); |