Files
linux-stable-mirror/kernel
Marco Crivellari c8272cfe36 workqueue: Add system_percpu_wq and system_dfl_wq
[ Upstream commit 128ea9f6cc ]

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 consistentcy cannot be addressed without refactoring the API.

system_wq is a per-CPU worqueue, yet nothing in its name tells about that
CPU affinity constraint, which is very often not required by users. Make it
clear by adding a system_percpu_wq.

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.

Suggested-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Marco Crivellari <marco.crivellari@suse.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Stable-dep-of: 870c2e7cd8 ("Input: synaptics_i2c - guard polling restart in resume")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2026-03-13 17:20:26 +01:00
..
2025-11-24 10:35:59 +01:00
2026-03-04 07:19:34 -05:00
2025-06-27 11:11:45 +01:00
2024-07-29 10:45:54 -07:00
2024-10-09 12:47:19 -07:00
2024-09-03 21:15:26 -07:00
2024-09-27 08:18:43 -07:00
2025-12-18 13:54:50 +01:00
2024-05-30 15:31:38 -07:00