]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: raid56: avoid double for loop inside raid56_parity_scrub_stripe()
authorQu Wenruo <wqu@suse.com>
Wed, 8 Jun 2022 00:34:36 +0000 (08:34 +0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 25 Jul 2022 15:45:35 +0000 (17:45 +0200)
commit50f69851ba0a0c5a367710b1ec820226c3af8a06
tree6857afbf3a17c943b9675d6883acff6a9698cc06
parent70f0b6615e445e45f8dc28bbc6b32fa6d2cc6d39
btrfs: raid56: avoid double for loop inside raid56_parity_scrub_stripe()

Originally it's iterating all the sectors which has dbitmap sector for
the vertical stripe.

It can be easily converted to sector bytenr iteration with an test_bit()
call.

Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/raid56.c