From: Alasdair G Kergon Date: Tue, 12 Jul 2005 22:53:02 +0000 (-0700) Subject: [PATCH] device-mapper multipath: Flush workqueue when destroying X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a044d016896d2717694003f00d31a98194077511;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [PATCH] device-mapper multipath: Flush workqueue when destroying The multipath destructor must flush its workqueue. Otherwise items that reference the destroyed object could remain. From: "goggin, edward" Signed-off-by: Lars Marowsky-Bree Signed-off-by: Alasdair G Kergon Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/md/dm-mpath.c b/drivers/md/dm-mpath.c index 84cdb700a24..fa72f015320 100644 --- a/drivers/md/dm-mpath.c +++ b/drivers/md/dm-mpath.c @@ -752,6 +752,8 @@ static int multipath_ctr(struct dm_target *ti, unsigned int argc, static void multipath_dtr(struct dm_target *ti) { struct multipath *m = (struct multipath *) ti->private; + + flush_workqueue(kmultipathd); free_multipath(m); }