* [dm-devel] [dm] Planning to WARN_ON() when flush_scheduled_work() is used.
@ 2023-02-11 6:19 Tetsuo Handa
2023-02-14 18:34 ` [dm-devel] " Mike Snitzer
0 siblings, 1 reply; 2+ messages in thread
From: Tetsuo Handa @ 2023-02-11 6:19 UTC (permalink / raw)
To: Alasdair Kergon, Mike Snitzer; +Cc: dm-devel
Hello.
Like commit c4f135d64382 ("workqueue: Wrap flush_workqueue() using a macro")
says, flush_scheduled_work() is dangerous and will be forbidden. But I haven't
heard from you after https://lkml.kernel.org/r/YtF45oMcHMKXjIyy@redhat.com .
https://lkml.kernel.org/r/49925af7-78a8-a3dd-bce6-cfc02e1a9236@I-love.SAKURA.ne.jp
https://lkml.kernel.org/r/e170edc2-e5b9-4c8b-4ed3-7e2d7a2850dc@I-love.SAKURA.ne.jp
Please do clarify which work items does this flush_scheduled_work() need to wait.
Regards.
--
dm-devel mailing list
dm-devel@redhat.com
https://listman.redhat.com/mailman/listinfo/dm-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [dm-devel] Planning to WARN_ON() when flush_scheduled_work() is used.
2023-02-11 6:19 [dm-devel] [dm] Planning to WARN_ON() when flush_scheduled_work() is used Tetsuo Handa
@ 2023-02-14 18:34 ` Mike Snitzer
0 siblings, 0 replies; 2+ messages in thread
From: Mike Snitzer @ 2023-02-14 18:34 UTC (permalink / raw)
To: Tetsuo Handa, mpatocka; +Cc: dm-devel, Alasdair Kergon
On Sat, Feb 11 2023 at 1:19P -0500,
Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> wrote:
> Hello.
>
> Like commit c4f135d64382 ("workqueue: Wrap flush_workqueue() using a macro")
> says, flush_scheduled_work() is dangerous and will be forbidden. But I haven't
> heard from you after https://lkml.kernel.org/r/YtF45oMcHMKXjIyy@redhat.com .
>
> https://lkml.kernel.org/r/49925af7-78a8-a3dd-bce6-cfc02e1a9236@I-love.SAKURA.ne.jp
> https://lkml.kernel.org/r/e170edc2-e5b9-4c8b-4ed3-7e2d7a2850dc@I-love.SAKURA.ne.jp
>
> Please do clarify which work items does this flush_scheduled_work() need to wait.
>
> Regards.
>
WARN_ON() seems excessive, why not WARN_ON_ONCE()?
But that aside, sorry for not looking closely and responding with
findings sooner.
BUT, I did just have a quick look at drivers/md/dm.c and its use of
flush_schduled_work(): a quick 'git blame drivers/md/dm.c' told me it
was only introduced for the benefit of DM's deferred device removal
feature (commit 2c140a246dc0b "dm: allow remove to be deferred").
Given that, I've staged these 2 commits for 6.3 inclusion:
https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-6.3&id=68fb709113077f1f367d8a55deb01d2d6bf23b0f
https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-6.3&id=cd4afc85b39c1b9dd63715c591829f67b07c86a8
Thanks,
Mike
--
dm-devel mailing list
dm-devel@redhat.com
https://listman.redhat.com/mailman/listinfo/dm-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-02-14 18:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-11 6:19 [dm-devel] [dm] Planning to WARN_ON() when flush_scheduled_work() is used Tetsuo Handa
2023-02-14 18:34 ` [dm-devel] " Mike Snitzer
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.