md/raid1: move the exceed_read_errors condition out of fix_read_error
authorChristoph Hellwig <hch@lst.de>
Fri, 29 May 2026 05:43:00 +0000 (07:43 +0200)
committerYu Kuai <yukuai@fygo.io>
Sun, 31 May 2026 11:09:19 +0000 (19:09 +0800)
commit6e3b0b91334d1dfaa20ca55eac835f5945a3b7c8
tree37e4ed146bc4b95c90465df57c073c92db9d3101
parentfcba8031327ddac251671fdc1be5399786b8dda7
md/raid1: move the exceed_read_errors condition out of fix_read_error

This condition much better fits into the only caller, limiting
fix_read_error to actually fix up data devices after a read error.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Link: https://patch.msgid.link/20260529054308.2720300-3-hch@lst.de
Signed-off-by: Yu Kuai <yukuai@fygo.io>
drivers/md/raid1.c