]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
md: fix a race condition for flush request handling
authorShaohua Li <shli@fb.com>
Thu, 21 Sep 2017 16:55:28 +0000 (09:55 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Oct 2017 07:47:34 +0000 (09:47 +0200)
commit93f1f1b25b32e591c9c3b03e3e338d494cf21068
tree78bd1f6fd81f6c4bbddb9753c2332638496b2265
parentd3d86d580864a0b4430b3cd53e0487fc7a1c72c7
md: fix a race condition for flush request handling

commit 79bf31a3b2a7ca467cfec8ff97d359a77065d01f upstream.

md_submit_flush_data calls pers->make_request, which missed the suspend check.
Fix it with the new md_handle_request API.

Reported-by: Nate Dailey <nate.dailey@stratus.com>
Tested-by: Nate Dailey <nate.dailey@stratus.com>
Fix: cc27b0c78c79(md: fix deadlock between mddev_suspend() and md_write_start())
Reviewed-by: NeilBrown <neilb@suse.com>
Signed-off-by: Shaohua Li <shli@fb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/md/md.c