md/raid5: Check all disks in a stripe_head for reshape progress
authorLogan Gunthorpe <logang@deltatee.com>
Thu, 16 Jun 2022 19:19:42 +0000 (13:19 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 2 Aug 2022 23:14:42 +0000 (17:14 -0600)
commit486f605586075a42ff2bbc35fb0376215b2fb908
treecb4c96276381957cbef49a63a81dd1689e883932
parent4ad1d9849ffa8738b5e9b3f8bda5f17d3b31dfcd
md/raid5: Check all disks in a stripe_head for reshape progress

When testing if a previous stripe has had reshape expand past it, use
the earliest or latest logical sector in all the disks for that stripe
head. This will allow adding multiple disks at a time in a subesquent
patch.

To do this cleaner, refactor the check into a helper function called
stripe_ahead_of_reshape().

Signed-off-by: Logan Gunthorpe <logang@deltatee.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Song Liu <song@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/md/raid5.c