From: Yu Kuai yukuai3@huawei.com
mainline inclusion from mainline-v6.7-rc1 commit 2e82248b70f48a98f3720cdaa8ea7a4e7f8bd760 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I8T02O
Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?i...
--------------------------------
Prepare to cleanup pers->prepare_suspend(), which is used to fix a deadlock in raid456 by returning error for io that is waiting for reshape to make progress in mddev_suspend().
This change will allow reshape to make progress while waiting for io to be done in mddev_suspend() in following patches.
Signed-off-by: Yu Kuai yukuai3@huawei.com Signed-off-by: Song Liu song@kernel.org Link: https://lore.kernel.org/r/20231010151958.145896-4-yukuai1@huaweicloud.com Signed-off-by: Li Nan linan122@huawei.com --- 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 331e0c1f6938..e155a8461898 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -9411,7 +9411,7 @@ void md_check_recovery(struct mddev *mddev) wake_up(&mddev->sb_wait); }
- if (is_md_suspended(mddev)) + if (READ_ONCE(mddev->suspended)) return;
if (mddev->bitmap)