mirror of
https://github.com/torvalds/linux.git
synced 2025-12-07 20:06:24 +00:00
fs: replace use of system_wq with system_percpu_wq
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 to all the fs subsystem. The old wq will be kept for a few release cylces. Suggested-by: Tejun Heo <tj@kernel.org> Signed-off-by: Marco Crivellari <marco.crivellari@suse.com> Link: https://lore.kernel.org/20250916082906.77439-3-marco.crivellari@suse.com Signed-off-by: Christian Brauner <brauner@kernel.org>
This commit is contained in:
committed by
Christian Brauner
parent
7a4f92d39f
commit
4ef64db060
@@ -335,7 +335,7 @@ static int param_set_nfs_timeout(const char *val, const struct kernel_param *kp)
|
||||
num *= HZ;
|
||||
*((int *)kp->arg) = num;
|
||||
if (!list_empty(&nfs_automount_list))
|
||||
mod_delayed_work(system_wq, &nfs_automount_task, num);
|
||||
mod_delayed_work(system_percpu_wq, &nfs_automount_task, num);
|
||||
} else {
|
||||
*((int *)kp->arg) = -1*HZ;
|
||||
cancel_delayed_work(&nfs_automount_task);
|
||||
|
||||
Reference in New Issue
Block a user