Unverified Commit 44f39d7c authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!11174 md: restore 'noio_flag' for the last mddev_resume()

parents cf3b556d 5dc39c9e
Loading
Loading
Loading
Loading
+4 −2
Original line number Original line Diff line number Diff line
@@ -520,11 +520,13 @@ EXPORT_SYMBOL_GPL(mddev_suspend);


void mddev_resume(struct mddev *mddev)
void mddev_resume(struct mddev *mddev)
{
{
	/* entred the memalloc scope from mddev_suspend() */
	memalloc_noio_restore(mddev->noio_flag);
	lockdep_assert_held(&mddev->reconfig_mutex);
	lockdep_assert_held(&mddev->reconfig_mutex);
	if (--mddev->suspended)
	if (--mddev->suspended)
		return;
		return;

	/* entred the memalloc scope from mddev_suspend() */
	memalloc_noio_restore(mddev->noio_flag);

	wake_up(&mddev->sb_wait);
	wake_up(&mddev->sb_wait);
	mddev->pers->quiesce(mddev, 0);
	mddev->pers->quiesce(mddev, 0);