Re: [PATCH] random: replace use of system_unbound_wq with system_dfl_wq

From: Jason A. Donenfeld

Date: Thu Oct 30 2025 - 13:50:20 EST


On Thu, Oct 30, 2025 at 4:58 PM Marco Crivellari
<marco.crivellari@xxxxxxxx> wrote:
>
> Currently if a user enqueue a work item using schedule_delayed_work() the
> used wq is "system_wq" (per-cpu wq) while queue_delayed_work() use
> WORK_CPU_UNBOUND (used when a cpu is not specified). The same applies to
> schedule_work() that is using system_wq and queue_work(), that makes use
> again of WORK_CPU_UNBOUND.
>
> This lack of consistency cannot be addressed without refactoring the API.
>
> system_unbound_wq should be the default workqueue so as not to enforce
> locality constraints for random work whenever it's not required.
>
> Adding system_dfl_wq to encourage its use when unbound work should be used.
>
> The old system_unbound_wq will be kept for a few release cycles.
>
> Suggested-by: Tejun Heo <tj@xxxxxxxxxx>
> Signed-off-by: Marco Crivellari <marco.crivellari@xxxxxxxx>

I rewrote the copy&pasted commit message to be simpler and also
include a reference to 128ea9f6ccfb ("workqueue: Add system_percpu_wq
and system_dfl_wq"). And then I queued it up in the random tree.
Thanks for the patch.

Jason