diff options
author | Jiri Kosina <jkosina@suse.com> | 2025-03-26 13:50:46 +0100 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.com> | 2025-03-26 13:50:46 +0100 |
commit | 770493524e9f623826765eb97c64d699f4752e4f (patch) | |
tree | 304c718009aa32834511d45497adb8acba496088 /kernel/workqueue.c | |
parent | e4f7cc8c36e7cab391683db682402ab2f185bf92 (diff) | |
parent | fe0fb58325e519008e2606a5aa2cff7ad23e212d (diff) |
Merge branch 'for-6.15/intel-ish' into for-linus
- intel-ish Kbuild cleanup (Jiri Kosina)
Diffstat (limited to 'kernel/workqueue.c')
-rw-r--r-- | kernel/workqueue.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 3c2c45313c886..bfe030b443e27 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -2254,8 +2254,10 @@ static void __queue_work(int cpu, struct workqueue_struct *wq, * queues a new work item to a wq after destroy_workqueue(wq). */ if (unlikely(wq->flags & (__WQ_DESTROYING | __WQ_DRAINING) && - WARN_ON_ONCE(!is_chained_work(wq)))) + WARN_ONCE(!is_chained_work(wq), "workqueue: cannot queue %ps on wq %s\n", + work->func, wq->name))) { return; + } rcu_read_lock(); retry: /* pwq which will be used unless @work is executing elsewhere */ @@ -3517,12 +3519,6 @@ repeat: } /* - * Put the reference grabbed by send_mayday(). @pool won't - * go away while we're still attached to it. - */ - put_pwq(pwq); - - /* * Leave this pool. Notify regular workers; otherwise, we end up * with 0 concurrency and stalling the execution. */ @@ -3532,6 +3528,12 @@ repeat: worker_detach_from_pool(rescuer); + /* + * Put the reference grabbed by send_mayday(). @pool might + * go away any time after it. + */ + put_pwq_unlocked(pwq); + raw_spin_lock_irq(&wq_mayday_lock); } |