diff options
| author | Maninder Singh <maninder1.s@samsung.com> | 2026-04-07 09:12:15 +0530 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-04-07 08:13:19 -1000 |
| commit | 034db4dd4449c556705e6b32bc07bd31df3889ba (patch) | |
| tree | 87036d6e0f732877c509dd3d07a16d4ef9f01c3b /kernel/workqueue.c | |
| parent | c6890f36fc49848c61d2113a3442eb1b59e0bc4b (diff) | |
workqueue: use NR_STD_WORKER_POOLS instead of hardcoded value
use NR_STD_WORKER_POOLS for irq_work_fns[] array definition.
NR_STD_WORKER_POOLS is also 2, but better to use MACRO.
Initialization loop for_each_bh_worker_pool() also uses same MACRO.
Signed-off-by: Maninder Singh <maninder1.s@samsung.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'kernel/workqueue.c')
| -rw-r--r-- | kernel/workqueue.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/workqueue.c b/kernel/workqueue.c index b1a28c51d4f2..900b864a30b0 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -7900,8 +7900,8 @@ void __init workqueue_init_early(void) { struct wq_pod_type *pt = &wq_pod_types[WQ_AFFN_SYSTEM]; int std_nice[NR_STD_WORKER_POOLS] = { 0, HIGHPRI_NICE_LEVEL }; - void (*irq_work_fns[2])(struct irq_work *) = { bh_pool_kick_normal, - bh_pool_kick_highpri }; + void (*irq_work_fns[NR_STD_WORKER_POOLS])(struct irq_work *) = + { bh_pool_kick_normal, bh_pool_kick_highpri }; int i, cpu; BUILD_BUG_ON(__alignof__(struct pool_workqueue) < __alignof__(long long)); |
