md/raid1-10: add a helper raid1_check_read_range()
authorYu Kuai <yukuai3@huawei.com>
Thu, 29 Feb 2024 09:57:08 +0000 (17:57 +0800)
committerSong Liu <song@kernel.org>
Fri, 1 Mar 2024 06:49:46 +0000 (22:49 -0800)
commitf29841ff3b272e1703454f93b96baf0fe0d9f31a
tree97d83737e17e8348f7619c3e3c24f9ca55a46fff
parent257ac239ffcfd097a9a0732bf5095fb00164f334
md/raid1-10: add a helper raid1_check_read_range()

The checking and handler of bad blocks appear many timers during
read_balance() in raid1 and raid10. This helper will be used in later
patches to simplify read_balance() a lot.

Co-developed-by: Paul Luse <paul.e.luse@linux.intel.com>
Signed-off-by: Paul Luse <paul.e.luse@linux.intel.com>
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Reviewed-by: Xiao Ni <xni@redhat.com>
Signed-off-by: Song Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20240229095714.926789-6-yukuai1@huaweicloud.com
drivers/md/raid1-10.c