lkml.org 
[lkml]   [2022]   [May]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] checkpatch: warn about flushing system-wide workqueues
Hello,

On Thu, May 05, 2022 at 10:42:19PM +0900, Tetsuo Handa wrote:
> Tejun, can we use this approach? If yes, when to apply?
>
> If we can include this patch into 5.18, can be applied as-is.
> If we can include this patch into 5.19, can be applied with checks for
> system_{long,unbound,highpri}_wq added because all flush_workqueue() users
> on system_*_wq are gone in next-20220505.
>
> Now that all flush_workqueue() users on system_*_wq are gone in next-20220505,
> next step is to remove all flush_scheduled_work() users. Therefore, instead of
> using /\bflush_workqueue\s*\(\s*system(_\w*)?_wq\s*\)/ in scripts/checkpatch.pl ,
> I think we can ask BUILD_BUG_ON() for blocking new system_*_wq users, and ask
> scripts/checkpatch.pl for blocking new system_wq users.

Given that we'll need runtime check anyway, why not resurrect the original
runtime warning but exempt flush_schedule_work() if that's the only thing
remaining right now (using a special flag or whatever)? If we're sure that
we aren't triggering it spuriously, we can ask Andrew to take the warning
patch into -mm so that it floats on top of everything else and gets pulled
into the trunk during the coming merge window.

Thanks.

--
tejun

\
 
 \ /
  Last update: 2022-05-05 19:34    [W:0.085 / U:0.148 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site