Re: [PATCH 2/3] md: MD_RECOVERY_NEEDED is set for mddev->recovery

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Dec 09 2016, Shaohua Li wrote:

> Signed-off-by: Shaohua Li <shli@xxxxxx>
> ---
>  drivers/md/md.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/md/md.c b/drivers/md/md.c
> index 84dc891..5e66648 100644
> --- a/drivers/md/md.c
> +++ b/drivers/md/md.c
> @@ -6856,7 +6856,7 @@ static int md_ioctl(struct block_device *bdev, fmode_t mode,
>  		/* need to ensure recovery thread has run */
>  		wait_event_interruptible_timeout(mddev->sb_wait,
>  						 !test_bit(MD_RECOVERY_NEEDED,
> -							   &mddev->flags),
> +							   &mddev->recovery),
>  						 msecs_to_jiffies(5000));
>  	if (cmd == STOP_ARRAY || cmd == STOP_ARRAY_RO) {
>  		/* Need to flush page cache, and ensure no-one else opens
> -- 
> 2.9.3

That was careless!

It would be good to add

Fixes: 90f5f7ad4f38 ("md: Wait for md_check_recovery before attempting device removal.")

to this.

Reviewed-by: NeilBrown <neilb@xxxxxxxx>

Thanks,
NeilBrown

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux