Replace wq users and add WQ_PERCPU to alloc_workqueue() users
Subsystems (6)
v2 cover Replace wq users and add WQ_PERCPU to alloc_workqueue() users
Hi,
This series continues the effort to refactor the Workqueue API. No behavior changes are introduced by this series.
=== Recent changes to the WQ API ===
The following, address the recent changes in the Workqueue API:
- commit 128ea9f6ccfb ("workqueue: Add system_percpu_wq and system_dfl_wq")
- commit 930c2ea566af ("workqueue: Add new WQ_PERCPU flag")
The old workqueues will be removed in a future release cycle and unbound will become the implicit default.
=== Introduced Changes by this series ===
1) [P 1-2] Replace use of system_wq and system_unbound_wq
Workqueue users converted to the better named new workqueues:
system_wq -> system_percpu_wq
system_unbound_wq -> system_dfl_wq
This way the old obsolete workqueues (system_wq, system_unbound_wq) can be removed in the future.
2) [P 3] add WQ_PERCPU to remaining alloc_workqueue() users
With the introduction of the WQ_PERCPU flag (equivalent to !WQ_UNBOUND), any alloc_workqueue() caller that doesn’t explicitly specify WQ_UNBOUND must now use WQ_PERCPU.
WQ_UNBOUND will be removed in future.
For more information:
https://lore.kernel.org/all/[email protected]/
---
Changes in v2:
- commit logs upgraded with a better description
- rebased on 6.19-rc5
Marco Crivellari (3):
mm: Replace use of system_unbound_wq with system_dfl_wq
mm: Replace use of system_wq with system_percpu_wq
mm: add WQ_PERCPU to alloc_workqueue users
mm/backing-dev.c | 6 +++--- mm/kfence/core.c | 6 +++--- mm/memcontrol.c | 4 ++-- mm/slub.c | 4 +++- mm/vmstat.c | 3 ++- 5 files changed, 13 insertions(+), 10 deletions(-)
Signature · 1 line
2.52.0
PATCH v2 1/3 mm: Replace use of system_unbound_wq with system_dfl_wq
This patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new alloc_workqueue flag:
commit 128ea9f6ccfb ("workqueue: Add system_percpu_wq and system_dfl_wq") commit 930c2ea566af ("workqueue: Add new WQ_PERCPU flag")
The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq
system_unbound_wq -> system_dfl_wq
This way the old obsolete workqueues (system_wq, system_unbound_wq) can be removed in the future.
--- mm/backing-dev.c | 2 +- mm/kfence/core.c | 6 +++--- mm/memcontrol.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-)
mm/backing-dev.c +1 -1
@@ -939,7 +939,7 @@ void wb_memcg_offline(struct mem_cgroup *memcg) memcg_cgwb_list->next =NULL ;/* prevent new wb's */ spin_unlock_irq (&cgwb_lock); -queue_work (system_unbound_wq, &cleanup_offline_cgwbs_work); +queue_work (system_dfl_wq, &cleanup_offline_cgwbs_work); }/**
mm/kfence/core.c +3 -3
@@ -878,7 +878,7 @@ static void toggle_allocation_gate(struct work_struct *work)/* Disable static key and reset timer. */ static_branch_disable (&kfence_allocation_key);#endif -queue_delayed_work (system_unbound_wq, &kfence_timer, +queue_delayed_work (system_dfl_wq, &kfence_timer,msecs_to_jiffies (kfence_sample_interval)); }
@@ -928,7 +928,7 @@ static void kfence_init_enable(void)#endif WRITE_ONCE (kfence_enabled, true); -queue_delayed_work (system_unbound_wq, &kfence_timer,0 ); +queue_delayed_work (system_dfl_wq, &kfence_timer,0 ); pr_info("initialized - using %lu bytes for %d objects at 0x%p-0x%p\n", KFENCE_POOL_SIZE, CONFIG_KFENCE_NUM_OBJECTS, (void *)__kfence_pool,
@@ -1024,7 +1024,7 @@ static int kfence_enable_late(void)return kfence_init_late ();WRITE_ONCE (kfence_enabled, true); -queue_delayed_work (system_unbound_wq, &kfence_timer,0 ); +queue_delayed_work (system_dfl_wq, &kfence_timer,0 );pr_info ("re-enabled\n" );return 0 ; }
mm/memcontrol.c +2 -2
@@ -644,7 +644,7 @@ static void flush_memcg_stats_dwork(struct work_struct *w)* in latency-sensitive paths is as cheap as possible. */ __mem_cgroup_flush_stats (root_mem_cgroup, true); -queue_delayed_work (system_unbound_wq, &stats_flush_dwork,FLUSH_TIME ); +queue_delayed_work (system_dfl_wq, &stats_flush_dwork,FLUSH_TIME ); }unsigned long memcg_page_state (struct mem_cgroup *memcg,int idx)
@@ -3872,7 +3872,7 @@ static int mem_cgroup_css_online(struct cgroup_subsys_state *css) goto offline_kmem;if (unlikely (mem_cgroup_is_root (memcg)) && !mem_cgroup_disabled ()) -queue_delayed_work (system_unbound_wq, &stats_flush_dwork, +queue_delayed_work (system_dfl_wq, &stats_flush_dwork,FLUSH_TIME );lru_gen_online_memcg (memcg);
Signature · 1 line
2.52.0
Re: [PATCH v2 1/3] mm: Replace use of system_unbound_wq with system_dfl_wq
Quoted 16 lines · Marco Crivellari
This patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new
alloc_workqueueflag:commit
128ea9f6ccfb("workqueue: Addsystem_percpu_wqandsystem_dfl_wq") commit930c2ea566af("workqueue: Add newWQ_PERCPUflag")The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq system_unbound_wq -> system_dfl_wq
Quoted 6 lines
This way the old obsolete workqueues (
system_wq,system_unbound_wq) can be removed in the future.Suggested-by Tejun Heo <[email protected]>Signed-off-by Marco Crivellari <[email protected]>
Sebastian
Re: [PATCH v2 1/3] mm: Replace use of system_unbound_wq with system_dfl_wq
In reply to Marco CrivellariQuoted 16 lines · Marco Crivellari
This patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new
alloc_workqueueflag:commit
128ea9f6ccfb("workqueue: Addsystem_percpu_wqandsystem_dfl_wq") commit930c2ea566af("workqueue: Add newWQ_PERCPUflag")The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq system_unbound_wq -> system_dfl_wq
Quoted 6 lines
This way the old obsolete workqueues (
system_wq,system_unbound_wq) can be removed in the future.Suggested-by Tejun Heo <[email protected]>Signed-off-by Marco Crivellari <[email protected]>
Signature · 2 lines
Frederic Weisbecker SUSE Labs
PATCH v2 2/3 mm: Replace use of system_wq with system_percpu_wq
In reply to Marco CrivellariThis patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new alloc_workqueue flag:
commit 128ea9f6ccfb ("workqueue: Add system_percpu_wq and system_dfl_wq") commit 930c2ea566af ("workqueue: Add new WQ_PERCPU flag")
The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq
system_unbound_wq -> system_dfl_wq
This way the old obsolete workqueues (system_wq, system_unbound_wq) can be removed in the future.
--- mm/backing-dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
mm/backing-dev.c +1 -1
@@ -971,7 +971,7 @@ static int __init cgwb_init(void) {/* * There can be many concurrent release work items overwhelming -* system_wq. Put them in a separate wq and limit concurrency. +* system_percpu_wq. Put them in a separate wq and limit concurrency. * There's no point in executing many of these in parallel. */ cgwb_release_wq =alloc_workqueue ("cgwb_release" ,0 ,1 );
Signature · 1 line
2.52.0
Re: [PATCH v2 2/3] mm: Replace use of system_wq with system_percpu_wq
Quoted 16 lines · Marco Crivellari
This patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new
alloc_workqueueflag:commit
128ea9f6ccfb("workqueue: Addsystem_percpu_wqandsystem_dfl_wq") commit930c2ea566af("workqueue: Add newWQ_PERCPUflag")The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq system_unbound_wq -> system_dfl_wq
Quoted 6 lines
This way the old obsolete workqueues (
system_wq,system_unbound_wq) can be removed in the future.Suggested-by Tejun Heo <[email protected]>Signed-off-by Marco Crivellari <[email protected]>
Sebastian
Re: [PATCH v2 2/3] mm: Replace use of system_wq with system_percpu_wq
In reply to Marco CrivellariQuoted 16 lines · Marco Crivellari
This patch continues the effort to refactor workqueue APIs, which has begun with the changes introducing new workqueues and a new
alloc_workqueueflag:commit
128ea9f6ccfb("workqueue: Addsystem_percpu_wqandsystem_dfl_wq") commit930c2ea566af("workqueue: Add newWQ_PERCPUflag")The point of the refactoring is to eventually alter the default behavior of workqueues to become unbound by default so that their workload placement is optimized by the scheduler.
Before that to happen, workqueue users must be converted to the better named new workqueues with no intended behaviour changes:
system_wq -> system_percpu_wq system_unbound_wq -> system_dfl_wq
Quoted 6 lines
This way the old obsolete workqueues (
system_wq,system_unbound_wq) can be removed in the future.Suggested-by Tejun Heo <[email protected]>Signed-off-by Marco Crivellari <[email protected]>
Signature · 2 lines
Frederic Weisbecker SUSE Labs
PATCH v2 3/3 mm: add WQ_PERCPU to alloc_workqueue users
In reply to Marco CrivellariThis continues the effort to refactor workqueue APIs, which began with the introduction of new workqueues and a new alloc_workqueue flag in:
commit 128ea9f6ccfb ("workqueue: Add system_percpu_wq and system_dfl_wq") commit 930c2ea566af ("workqueue: Add new WQ_PERCPU flag")
The refactoring is going to alter the default behavior of alloc_workqueue() to be unbound by default.
With the introduction of the WQ_PERCPU flag (equivalent to !WQ_UNBOUND), any alloc_workqueue() caller that doesn’t explicitly specify WQ_UNBOUND must now use WQ_PERCPU. For more details see the Link tag below.
In order to keep alloc_workqueue() behavior identical, explicitly request WQ_PERCPU.
--- mm/backing-dev.c | 2 +- mm/slub.c | 4 +++- mm/vmstat.c | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-)
mm/backing-dev.c +1 -1
@@ -974,7 +974,7 @@ static int __init cgwb_init(void)* system_percpu_wq. Put them in a separate wq and limit concurrency. * There's no point in executing many of these in parallel. */ - cgwb_release_wq =alloc_workqueue ("cgwb_release" ,0 ,1 ); + cgwb_release_wq =alloc_workqueue ("cgwb_release" ,WQ_PERCPU ,1 );if (!cgwb_release_wq)return -ENOMEM ;
mm/slub.c +3 -1
@@ -8542,7 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { - flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY + flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 ); WARN_ON(!flushwq); }
mm/vmstat.c +2 -1
@@ -2274,7 +2274,8 @@ void __init init_mm_internals(void) {int ret__maybe_unused ; - mm_percpu_wq =alloc_workqueue ("mm_percpu_wq" ,WQ_MEM_RECLAIM ,0 ); + mm_percpu_wq =alloc_workqueue ("mm_percpu_wq" , +WQ_MEM_RECLAIM |WQ_PERCPU ,0 );#ifdef CONFIG_SMP ret = cpuhp_setup_state_nocalls(CPUHP_MM_VMSTAT_DEAD, "mm/vmstat:dead",
Signature · 1 line
2.52.0
Andrew Morton
maintainerRe: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
Quoted 19 lines · On Tue, 13 Jan 2026 12:46:30 +0100 Marco Crivellari…
This continues the effort to refactor workqueue APIs, which began with the introduction of new workqueues and a new
alloc_workqueueflag in:commit
128ea9f6ccfb("workqueue: Addsystem_percpu_wqandsystem_dfl_wq") commit930c2ea566af("workqueue: Add newWQ_PERCPUflag")The refactoring is going to alter the default behavior of
alloc_workqueue()to be unbound by default.With the introduction of the
WQ_PERCPUflag (equivalent to !WQ_UNBOUND), anyalloc_workqueue()caller that doesn’t explicitly specifyWQ_UNBOUNDmust now useWQ_PERCPU. For more details see the Link tag below.In order to keep
alloc_workqueue()behavior identical, explicitly requestWQ_PERCPU.
mm/slub.c void __init kmem_cache_init(void) · line 8550
Quoted 10 lines
mm/slub.c +3
-1@@ -8542,7 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { - flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY + flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 ); WARN_ON(!flushwq); }
oops. I did this:
mm/slub.c renamed from mm/slub.c~mm-add-wq_percpu-to-alloc_workqueue-users-fix +1 -0
@@ -8546,6 +8546,7 @@ void __init kmem_cache_init_late(void) flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU ,0 );WARN_ON (!flushwq); +#endif } struct kmem_cache *
_
kernel test robot
build botRe: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
In reply to Marco Crivellarikernel test robot noticed the following build errors:
Hi Marco,
kernel test robot noticed the following build errors:
[auto build test ERROR on akpm-mm/mm-everything]
[also build test ERROR on linus/master v6.19-rc5 next-20260113] [cannot apply to vbabka-slab/for-next]
[If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Marco-Crivellari/mm-Replace-use-of-system_unbound_wq-with-system_dfl_wq/20260113-195017 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything patch link: https://lore.kernel.org/r/20260113114630.152942-4-marco.crivellari%40suse.com patch subject: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users config: arm-randconfig-002-20260114 (https://download.01.org/0day-ci/archive/20260114/[email protected]/config) compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 9b8addffa70cee5b2acc5454712d9cf78ce45710) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260114/[email protected]/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
>> mm/slub.c:8545:2: error: unterminated conditional directive
8545 | #ifndef CONFIG_SLUB_TINY
| ^1 error generated.
vim +8545 mm/slub.c
8542
8543 void __init kmem_cache_init_late(void)
8544 {
> 8545 #ifndef CONFIG_SLUB_TINY
8546 flushwq = alloc_workqueue("slub_flushwq", WQ_MEM_RECLAIM | WQ_PERCPU,
8547 0);
8548 WARN_ON(!flushwq);
8549 }
8550
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
kernel test robot
build botRe: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
In reply to Marco Crivellarikernel test robot noticed the following build errors:
Hi Marco,
kernel test robot noticed the following build errors:
[auto build test ERROR on akpm-mm/mm-everything]
[also build test ERROR on linus/master v6.19-rc5 next-20260113] [cannot apply to vbabka-slab/for-next]
[If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Marco-Crivellari/mm-Replace-use-of-system_unbound_wq-with-system_dfl_wq/20260113-195017 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything patch link: https://lore.kernel.org/r/20260113114630.152942-4-marco.crivellari%40suse.com patch subject: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users config: riscv-randconfig-002-20260114 (https://download.01.org/0day-ci/archive/20260114/[email protected]/config) compiler: riscv64-linux-gcc (GCC) 9.5.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260114/[email protected]/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
>> mm/slub.c:8545: error: unterminated #ifndef
8545 | #ifndef CONFIG_SLUB_TINY
| vim +8545 mm/slub.c
8542
8543 void __init kmem_cache_init_late(void)
8544 {
> 8545 #ifndef CONFIG_SLUB_TINY
8546 flushwq = alloc_workqueue("slub_flushwq", WQ_MEM_RECLAIM | WQ_PERCPU,
8547 0);
8548 WARN_ON(!flushwq);
8549 }
8550
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
Re: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
In reply to Marco Crivellarimm/slub.c void __init kmem_cache_init(void) · line 8545
Quoted 8 lines · Marco Crivellari
mm/slub.c +1
-1@@ -8542,7 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { - flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY
This ifndef does not belong here.
mm/slub.c void __init kmem_cache_init(void) · line 8549
Quoted 4 lines
mm/slub.c +2
-0+ flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 );WARN_ON (!flushwq); }
Without the ifndef above I am happy with
Sebastian
Andrew Morton
maintainerRe: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
Quoted 12 lines · On Sat, 24 Jan 2026 23:21:35 +0100 Sebastian Andrzej Siewior…
mm/slub.c void __init kmem_cache_init(void) · line 8545
Quoted 8 lines · Marco Crivellari
mm/slub.c +1
-1@@ -8542,7 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { - flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY This ifndef does not belong here.
Quoted 4 lines
mm/slub.c void __init kmem_cache_init(void) · line 8549
Quoted 4 lines
mm/slub.c +2
-0+ flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 );WARN_ON (!flushwq); }
Yup, thanks, mm.git is carrying a -fix patch, which is actually wrong.
From: Andrew Morton <[email protected]>
Subject: mm-add-wq_percpu-to-alloc_workqueue-users-fix
Date: Tue Jan 13 05:59:13 PM PST 2026
fix mm/slub.c
---
mm/slub.c | 1 + 1 file changed, 1 insertion(+)
mm/slub.c renamed from mm/slub.c~mm-add-wq_percpu-to-alloc_workqueue-users-fix +1 -0
@@ -8546,6 +8546,7 @@ void __init kmem_cache_init_late(void) flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU ,0 );WARN_ON (!flushwq); +#endif } struct kmem_cache *
I'll add this:
mm/slub.c renamed from mm/slub.c~mm-add-wq_percpu-to-alloc_workqueue-users-fix-fix +0 -2
@@ -8542,11 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { -#ifndef CONFIG_SLUB_TINY flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU ,0 );WARN_ON (!flushwq); -#endif } struct kmem_cache *
_
Frederic Weisbecker
Reviewed-byRe: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
Quoted 53 lines · Andrew Morton
Quoted 12 lines · On Sat, 24 Jan 2026 23:21:35 +0100 Sebastian Andrzej Siewior…
mm/slub.c void __init kmem_cache_init(void) · line 8545
Quoted 8 lines · Marco Crivellari
mm/slub.c +1
-1@@ -8542,7 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { - flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY This ifndef does not belong here.
Quoted 4 lines
mm/slub.c void __init kmem_cache_init_late(void) · line 8550
Quoted 4 lines
mm/slub.c +2
-0+ flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 );WARN_ON (!flushwq); }Yup, thanks, mm.git is carrying a -fix patch, which is actually wrong.
From: Andrew Morton <[email protected]>
Subject: mm-add-wq_percpu-to-alloc_workqueue-users-fix
Date: Tue Jan 13 05:59:13 PM PST 2026fix
mm/slub.cCc Marco Crivellari <[email protected]>Signed-off-by Andrew Morton <[email protected]>---
mm/slub.c | 1 + 1 file changed, 1 insertion(+)mm/slub.c renamed from mm/slub.c~mm-add-wq_percpu-to-alloc_workqueue-users-fix +1
-0@@ -8546,6 +8546,7 @@ void __init kmem_cache_init_late(void) flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU ,0 );WARN_ON (!flushwq); +#endif } struct kmem_cache *I'll add this:
mm/slub.c void __init kmem_cache_init(void) · line 8549
Quoted 8 lines
mm/slub.c renamed from mm/slub.c~mm-add-wq_percpu-to-alloc_workqueue-users-fix-fix +0
-2@@ -8542,11 +8542,9 @@ void __init kmem_cache_init(void)void __init kmem_cache_init_late (void ) { -#ifndef CONFIG_SLUB_TINY flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU ,0 );WARN_ON (!flushwq); -#endif
With that as a fixup, looks good:
Signature · 2 lines
Frederic Weisbecker SUSE Labs
Re: [PATCH v2 3/3] mm: add WQ_PERCPU to alloc_workqueue users
In reply to Sebastian Andrzej SiewiorQuoted 8 lines · Sebastian Andrzej Siewior
[..]
mm/slub.c void __init kmem_cache_init(void) · line 8545
Quoted 4 lines
void
__initkmem_cache_init_late(void)
{mm/slub.c +1
-1- flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM ,0 ); +#ifndef CONFIG_SLUB_TINY This ifndef does not belong here.
Quoted 7 lines
mm/slub.c void __init kmem_cache_init(void) · line 8549
Quoted 4 lines
mm/slub.c +2
-0+ flushwq =alloc_workqueue ("slub_flushwq" ,WQ_MEM_RECLAIM |WQ_PERCPU , +0 );WARN_ON (!flushwq); }Without the ifndef above I am happy with
Reviewed-by Sebastian Andrzej Siewior <[email protected]>
Thanks, it seems like I messed up the thing when I rebased...
Signature · 3 lines
Marco Crivellari L3 Support Engineer