summaryrefslogtreecommitdiff
path: root/kernel/workqueue.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2026-04-23 09:34:28 +0200
committerTakashi Iwai <tiwai@suse.de>2026-04-23 09:34:28 +0200
commit2699bc6d062735f9fc430fe6dcf05b82ae8b2ab9 (patch)
tree24c9dd31e86dc2ff46e4a5defe6fa3e740acd38f /kernel/workqueue.c
parenta9224f26b754b5034719248891ff3c2ea0d11144 (diff)
parent24fcdc81dd7e1560e57eff75b618e5b00054b714 (diff)
Merge tag 'asoc-fix-v7.1-merge-window' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v7.1 A fairly small collection of fixes, device IDs and quirks that came in during the merge window, the most remarkable of which is one for SDCA boolean firmware flags which is remarkable mainly because it is partially in regmap.
Diffstat (limited to 'kernel/workqueue.c')
-rw-r--r--kernel/workqueue.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index eda756556341..c6ea96d5b716 100644
--- a/kernel/workqueue.c
+++ b/kernel/workqueue.c
@@ -1849,8 +1849,20 @@ static void unplug_oldest_pwq(struct workqueue_struct *wq)
raw_spin_lock_irq(&pwq->pool->lock);
if (pwq->plugged) {
pwq->plugged = false;
- if (pwq_activate_first_inactive(pwq, true))
+ if (pwq_activate_first_inactive(pwq, true)) {
+ /*
+ * While plugged, queueing skips activation which
+ * includes bumping the nr_active count and adding the
+ * pwq to nna->pending_pwqs if the count can't be
+ * obtained. We need to restore both for the pwq being
+ * unplugged. The first call activates the first
+ * inactive work item and the second, if there are more
+ * inactive, puts the pwq on pending_pwqs.
+ */
+ pwq_activate_first_inactive(pwq, false);
+
kick_pool(pwq->pool);
+ }
}
raw_spin_unlock_irq(&pwq->pool->lock);
}