ubi: Fix race condition between ubi volume creation and udev
authorClay McClure <clay@daemons.net>
Fri, 22 Sep 2017 02:01:34 +0000 (19:01 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 18 Mar 2018 10:15:43 +0000 (11:15 +0100)
commitf5b58c98186f280dd9f5bd1cbad0de786e16bae7
tree14a58cba5e6bb2bae3466513e43ec5f2f0a465fe
parentccab18a66fbe5987eb4ed31dc6814c21413bea38
ubi: Fix race condition between ubi volume creation and udev

commit a51a0c8d213594bc094cb8e54aad0cb6d7f7b9a6 upstream.

Similar to commit 714fb87e8bc0 ("ubi: Fix race condition between ubi
device creation and udev"), we should make the volume active before
registering it.

Signed-off-by: Clay McClure <clay@daemons.net>
Cc: <stable@vger.kernel.org>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mtd/ubi/vmt.c