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)
committerSong Liu <song@kernel.org>
Sun, 3 Jul 2022 14:55:42 +0000 (07:55 -0700)
commit76816a91b3d24670e5f0e8b5ab49aa6f9c497147
treed25a3599f91d2da80f0223249cc19076ae45f915
parentb16d91f9b7ea286cff87173a3c4284a61f12f096
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>
drivers/md/raid5.c