From nobody Fri Sep 25 16:04:04 2026 Received: from stravinsky.debian.org (stravinsky.debian.org [82.195.75.108]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6DF804A0905 for ; Thu, 10 Sep 2026 14:55:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=82.195.75.108 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789052141; cv=none; b=StRoDjqra578hk7ae7C8UOghRtHGx8fCxzpdcspG6A61LBuh/sY0I81zyPpkppDkvUANOZIzkaX0swRMIhZSvoWyMvOmftA3XMuDysCHWF0pHQ/G6ZwwANAW29E2jeW/NL4YxzxlmDeeLA8Nqi0aNTH4MplgtstUwXCXV8fmoEw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789052141; c=relaxed/simple; bh=iUmX7xwBOdLuORHq56tUAF4FC5C6OctphCzxQIwPX6Y=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=dAVgmnEb2/qKb/ucG8G/uwKDI9GtsrZDv5tCAJvdvL2LVfkUeTW1C1RzlWzqFwusTCSLai835xI3SwNjIdRfhzy8vCvg/DXq1baepWqNePGH+qK5AjqeaFLwzAwdRRCjuP1HiZiGdaE5M5KPg1b325z+2xTDtgMBE3tFLvCgdq0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=debian.org; spf=pass smtp.mailfrom=debian.org; dkim=pass (2048-bit key) header.d=debian.org header.i=@debian.org header.b=easagslF; arc=none smtp.client-ip=82.195.75.108 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=debian.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=debian.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=debian.org header.i=@debian.org header.b="easagslF" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debian.org; s=smtpauto.stravinsky; h=X-Debian-User:Cc:To:In-Reply-To:References: Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description; bh=oz6RGj/PQEpqn4o/qi03F2U5MZb51VPgoSqrIPYTw44=; b=easagslFcwbfCU6Oe719P2qPgk nBhiUbWKDum2atxrhZrgcUniTH3Xz+W3Ph9YjIjERjkwDdg8UuuaM2p2wN+6+mndrz0DAr0YlsjxF 7Nh4vkkPqt2aZ6vPk3DQReXa53DtRSnI8ILZBOHdqLhzKwfWQQowtofFGE8udQZjPOu8srm3W6umG DbsG3TtBdIzRkIE613UG00YRSyxQzyRCcKfiIzK+RXpR+jB0LpXN1hGRZHAuwL0ObQBbSSzczdzOF wTR2K/UOlDuG5HQFVEnnlWblPuveglBQimAr826qOMM+ehA0Dr1w0nrCMWK8WEwo2NHOJyRuK3OvK HxI5BONg==; Received: from authenticated-user by stravinsky.debian.org with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.96) (envelope-from ) id 1x4gBa-000aXr-14; Thu, 10 Sep 2026 14:55:34 +0000 From: Breno Leitao Date: Thu, 10 Sep 2026 07:54:12 -0700 Subject: [PATCH wq/for-7.4 1/2] workqueue: give percpu workqueues their own max_active Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260910-realsplit_last_v2-v1-1-464d64b71b29@debian.org> References: <20260910-realsplit_last_v2-v1-0-464d64b71b29@debian.org> In-Reply-To: <20260910-realsplit_last_v2-v1-0-464d64b71b29@debian.org> To: Tejun Heo , Lai Jiangshan Cc: marco.crivellari@suse.com, linux-kernel@vger.kernel.org, Breno Leitao , kernel-team@meta.com X-Mailer: b4 0.16-dev-f8e9d X-Developer-Signature: v=1; a=openpgp-sha256; l=4430; i=leitao@debian.org; h=from:subject:message-id; bh=iUmX7xwBOdLuORHq56tUAF4FC5C6OctphCzxQIwPX6Y=; b=owEBbQKS/ZANAwAIATWjk5/8eHdtAcsmYgBqosTfA1nAcaC/elwWgiLJRZuqaQOIEhxXA2O49 Z0ZHjzArJiJAjMEAAEIAB0WIQSshTmm6PRnAspKQ5s1o5Of/Hh3bQUCaqLE3wAKCRA1o5Of/Hh3 bQQ4D/9peq3+3X8dk/AbcsGpMJGnQuROIMxcs2XXknJduu3KmhnJtl0oSQV3Z0DgejnNLmC+w2I dIkoTSC8vh19iPKTVGV9EzTCIXTMqvgxIZHzpegN6t+mWry6y7vEr7LTCSJMTz2j2L16kl+vdaV zAVu7Atp1OnW8HGaW5pBM8zSd+PgiyTBEeuSHaP6HHHM8vTpDMGCGqxVKCcX16xgCaOQm4PxKcH +yeYq6fZwDWIL5YibTv7qiwF5hCcc7D0MjCzK2gwg+BP3H2yonETLhSJAeeb1wAU7Hk8SFhFZ9z S5GQ1UlvK7QPOd/bZPG4EpbgIS9r6/mPCFMQu0uqWXLh8YMGpx0pGYWSsiiD9NRfsO4A1zv/4l4 adObvEMGq76Z45I/Yt75POM68tKIrbXH6N2LxOTBdNMkoDwSSzfGjJyFjQA2/5jZ0xYb1Q90D4e meb6LmosxrBfrLyLtGucpp1Rl7utIanK7T9x2aa2g5cmqpmnYXUKfjrXPT866heDhiGkjx2gSD9 QpbvKxxcdYSohqypQt13ea0ZnRdZ3YghTRMYDKqmC7upjwBCpqmKcI7glfWIa2mEdx1DYGzjjt1 lz0XsZ1zXTUaZ9ZtAaacci48xk0omYqw4de3gN1pbVBtr1N7zzmKKlxP4NkIQ53fpupuo/J7JlY Sky98npTv7TR85g== X-Developer-Key: i=leitao@debian.org; a=openpgp; fpr=AC8539A6E8F46702CA4A439B35A3939FFC78776D X-Debian-User: leitao wq->max_active means two different things, depending on how the workqueue is backed. On a concurrency managed per-cpu pool it caps pwq->nr_active, so it is a per-cpu limit. On an unbound pool it feeds wq_node_nr_active() and is shared by the whole workqueue. Tejun once said [1]: It kinda sucks that max_active's meaning is different across the boundary tho. Maybe percpu max_active should be separate into its own field, idk. Add wq->percpu_max_active for the first meaning and leave max_active as the system wide one. wq_adjust_max_active() updates whichever of the two applies, and min_active stays with max_active as only the unbound side uses it. Suggested-by: Tejun Heo Link: https://lore.kernel.org/all/amESSqf0TMmzhFGz@slm.duckdns.org/ [1] Signed-off-by: Breno Leitao --- kernel/workqueue.c | 44 +++++++++++++++++++++++++++----------------- 1 file changed, 27 insertions(+), 17 deletions(-) diff --git a/kernel/workqueue.c b/kernel/workqueue.c index f868011e291f4b..8232a60e107cf7 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -389,6 +389,7 @@ struct workqueue_struct { =20 /* See alloc_workqueue() function comment for info on min/max_active */ int max_active; /* WO: max active works */ + int percpu_max_active; /* WO: max active works per cpu */ int min_active; /* WO: min active works */ int saved_max_active; /* WQ: saved max_active */ int saved_min_active; /* WQ: saved min_active */ @@ -1855,10 +1856,10 @@ static bool pwq_tryinc_nr_active(struct pool_workqu= eue *pwq, bool fill) =20 /* * A concurrency-managed per-cpu pool accounts nr_active per pwq, so - * pwq->nr_active against wq->max_active is sufficient. + * pwq->nr_active against wq->percpu_max_active is sufficient. */ if (is_percpu_pool(pool)) { - obtained =3D pwq->nr_active < READ_ONCE(wq->max_active); + obtained =3D pwq->nr_active < READ_ONCE(wq->percpu_max_active); goto out; } =20 @@ -6016,9 +6017,9 @@ static int init_rescuer(struct workqueue_struct *wq) * wq_adjust_max_active - update a wq's max_active to the current setting * @wq: target workqueue * - * If @wq isn't freezing, set @wq->max_active to the saved_max_active and - * activate inactive work items accordingly. If @wq is freezing, clear - * @wq->max_active to zero. + * If @wq isn't freezing, set the limit that applies to @wq's backing to t= he + * saved_max_active and activate inactive work items accordingly. If @wq is + * freezing, clear it to zero. */ static void wq_adjust_max_active(struct workqueue_struct *wq) { @@ -6035,20 +6036,25 @@ static void wq_adjust_max_active(struct workqueue_s= truct *wq) new_min =3D wq->saved_min_active; } =20 - if (wq->max_active =3D=3D new_max && wq->min_active =3D=3D new_min) - return; - /* - * Update @wq->max/min_active and then kick inactive work items if more - * active work items are allowed. This doesn't break work item ordering + * Update the limit and then kick inactive work items if more active + * work items are allowed. This doesn't break work item ordering * because new work items are always queued behind existing inactive * work items if there are any. */ - WRITE_ONCE(wq->max_active, new_max); - WRITE_ONCE(wq->min_active, new_min); + if (wq->flags & WQ_UNBOUND) { + if (wq->max_active =3D=3D new_max && wq->min_active =3D=3D new_min) + return; =20 - if (wq->flags & WQ_UNBOUND) + WRITE_ONCE(wq->max_active, new_max); + WRITE_ONCE(wq->min_active, new_min); wq_update_node_max_active(wq, -1); + } else { + if (wq->percpu_max_active =3D=3D new_max) + return; + + WRITE_ONCE(wq->percpu_max_active, new_max); + } =20 if (new_max =3D=3D 0) return; @@ -6145,10 +6151,14 @@ static struct workqueue_struct *__alloc_workqueue(c= onst char *fmt, =20 /* init wq */ wq->flags =3D flags; - wq->max_active =3D max_active; - wq->min_active =3D min(max_active, WQ_DFL_MIN_ACTIVE); - wq->saved_max_active =3D wq->max_active; - wq->saved_min_active =3D wq->min_active; + if (flags & WQ_UNBOUND) { + wq->max_active =3D max_active; + wq->min_active =3D min(max_active, WQ_DFL_MIN_ACTIVE); + wq->saved_min_active =3D wq->min_active; + } else { + wq->percpu_max_active =3D max_active; + } + wq->saved_max_active =3D max_active; mutex_init(&wq->mutex); atomic_set(&wq->nr_pwqs_to_flush, 0); INIT_LIST_HEAD(&wq->pwqs); --=20 2.53.0-Meta From nobody Fri Sep 25 16:04:04 2026 Received: from stravinsky.debian.org (stravinsky.debian.org [82.195.75.108]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 00FA64A2A61 for ; Thu, 10 Sep 2026 14:55:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=82.195.75.108 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789052144; cv=none; b=TrEplPJbAadUCTslB7KTJAu73vBw5ouZuioGhkute+Rsxc9Idssthl1Pwzyb3XaiWqyFQsf0ya+7v6PpKTv8hQuVCbBj4mF+j3CNyZtRdBmaGj63SJUFBsBu4zIIlqBxcZYr8xdSkkOynUt+5uqFl+OqiIoaCENA0nbulFZe2Iw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789052144; c=relaxed/simple; bh=D4QDZJ/BhJGnafANKKKHld4iAuwS8mDIcGUUG7IlTII=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VqA4p1An8+pkSy3zoYq12TpyVLzgsodY9ELZhJcurGu5hNl2Y43qgdVVlCIbYMTAeSlXFRaJu3qPmHov4zPe0PdZ0Ll9SsLR6E8WgcKVxBTfyMVDmCIOeNQgecfVc+BryQkd2iirEr+DNC7c8ifRzEk4zWg6YSoQo5+uO6pN+Vw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=debian.org; spf=pass smtp.mailfrom=debian.org; dkim=pass (2048-bit key) header.d=debian.org header.i=@debian.org header.b=p9sj8iuU; arc=none smtp.client-ip=82.195.75.108 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=debian.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=debian.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=debian.org header.i=@debian.org header.b="p9sj8iuU" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debian.org; s=smtpauto.stravinsky; h=X-Debian-User:Cc:To:In-Reply-To:References: Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description; bh=xUDfzTwxG11mZ+J3dXeQ6zMdoSjL7YUgi8RSjzuPL1I=; b=p9sj8iuUbHGRJsN3msTkEH14+u E+OWu7WWJvfngw9KdEc+DvQPZXsYosNyNB4OhgZXCUDXK4rqbLj84c8snpe6edoWBLCEZrSQYhgxM LOaNE1vvFHbvMxvoFh5IR7XXb1P0rhQDztU9CV35fvU6F32QSBXdTyfx8CEVuxIHn2epL7nSJil4U 53cP6nENWILQrzZJoSkEdXzX0POJGGO1ZjL2uFe6/1V0HPkpuiEN8glfqKKjXbV9bOJLw1tkW2AgC H28uje127JoUSZcS6CWrBbXE1BxT1BmDiL9YBhVOqeRqPGII0Taaw2MtM6HGG1y6iyP8gdjM8uNmt cfwVpL0w==; Received: from authenticated-user by stravinsky.debian.org with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.96) (envelope-from ) id 1x4gBd-000aYU-2v; Thu, 10 Sep 2026 14:55:38 +0000 From: Breno Leitao Date: Thu, 10 Sep 2026 07:54:13 -0700 Subject: [PATCH wq/for-7.4 2/2] workqueue: derive the standard attrs from the workqueue flags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260910-realsplit_last_v2-v1-2-464d64b71b29@debian.org> References: <20260910-realsplit_last_v2-v1-0-464d64b71b29@debian.org> In-Reply-To: <20260910-realsplit_last_v2-v1-0-464d64b71b29@debian.org> To: Tejun Heo , Lai Jiangshan Cc: marco.crivellari@suse.com, linux-kernel@vger.kernel.org, Breno Leitao , kernel-team@meta.com X-Mailer: b4 0.16-dev-f8e9d X-Developer-Signature: v=1; a=openpgp-sha256; l=5186; i=leitao@debian.org; h=from:subject:message-id; bh=D4QDZJ/BhJGnafANKKKHld4iAuwS8mDIcGUUG7IlTII=; b=owEBbQKS/ZANAwAIATWjk5/8eHdtAcsmYgBqosTff1wbPG7ov6uGLqOe2Yzx0hBZnIghB9wto 9L7rgpOHiqJAjMEAAEIAB0WIQSshTmm6PRnAspKQ5s1o5Of/Hh3bQUCaqLE3wAKCRA1o5Of/Hh3 bTZVD/9OFLdgOmAh45vnblIeMGtN2dqpNLtLow3nE8C4io1Oq72lkKNFPBQKX/5wbMor/8lCh6t imAs4n8+gAlK1rwmd42pG54hSkSBjogr4RbyhvQsZ3ituRvCyZH0Ha0rJdbStDXpF54wyXIFd07 EEKhr2vmxcZrI61admEgU9RF0YficNvAKWAqmSWoZj+2XzQME5BE7oRh0taRnw/zvCqAwraBTUS Whf1JSP+ldw59t1QdXV0ESItNurycnGVl6u2DiTDcx5fl04gMNR4bsSruJeNWLebug8lPLzglDt b4dnuFzG5gl4811Gx0FR+ZkDkr3wlc+dzPczBsDxmNWjMgnh/IrSOalX1riUEykn38rJv38H6TH sVIkXd+i2aTvSu+8KmPdYfnekiVXKP/aaTMLpiNxJzy6pMrUcqg8hQG49NOJsDg60Qig5vH5/Tw tHH7+p9wRpL008xY1tHowSyCA7SqymucvDpcqdGKRE/4I9fce7K/vtQ+hQbuHHKdS87NMliRgi8 YCAiZmbjxoeBkt+Nm+e6NRup4IiKB2gEpSKpKSMrir/mwzrh9fuIBA7J6iA3dOJEK0qADmAEH89 bodsgD6jfST4sdIudHOKs50lhfvYtmY4cS5lkrycH31Kb4ZnNxGCR7vxRhTSIWkDDXf0+Bf8cYB PSf6OKRpIYJhbrg== X-Developer-Key: i=leitao@debian.org; a=openpgp; fpr=AC8539A6E8F46702CA4A439B35A3939FFC78776D X-Debian-User: leitao alloc_and_link_pwqs() picks one of three static attrs arrays indexed by WQ_HIGHPRI, and branches to a separate apply_workqueue_attrs_locked() call for percpu, ordered and unbound workqueues. The arrays differ only in the nice level and the ordered bit, which the flags already say. Build the attrs from the flags instead. alloc_wq_std_attrs() sets nice for WQ_HIGHPRI and ordered for __WQ_ORDERED, which collapses the three branches into one call and drops the three arrays along with their workqueue_init_early() loop. The ordering WARN now sits behind its own __WQ_ORDERED test rather than the unbound branch. __WQ_ORDERED is internal and every macro that sets it pairs it with WQ_UNBOUND, so the WARN covers the same workqueues as before. The attrs are allocated per creation now. apply_wqattrs_prepare() already allocates one on the same path, including in workqueue_init_early(), so that is not a new constraint, and it only copies what it is given, so the caller can free them once apply_workqueue_attrs_locked() returns. Signed-off-by: Breno Leitao --- kernel/workqueue.c | 76 +++++++++++++++++++++++---------------------------= ---- 1 file changed, 32 insertions(+), 44 deletions(-) diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 8232a60e107cf7..39187f424c34e7 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -533,15 +533,6 @@ static DEFINE_IDR(worker_pool_idr); /* PR: idr of all = pools */ /* PL: hash of all unbound pools keyed by pool->attrs */ static DEFINE_HASHTABLE(unbound_pool_hash, UNBOUND_POOL_HASH_ORDER); =20 -/* I: attributes used when instantiating standard unbound pools on demand = */ -static struct workqueue_attrs *unbound_std_wq_attrs[NR_STD_WORKER_POOLS]; - -/* I: attributes used when instantiating ordered pools on demand */ -static struct workqueue_attrs *ordered_wq_attrs[NR_STD_WORKER_POOLS]; - -/* I: attributes of percpu workqueues, which are backed by the static pool= s */ -static struct workqueue_attrs *percpu_std_wq_attrs[NR_STD_WORKER_POOLS]; - /* * I: kthread_worker to release pwq's. pwq release needs to be bounced to a * process context while holding a pool lock. Bounce to a dedicated kthread @@ -5920,9 +5911,27 @@ static void unbound_wq_update_pwq(struct workqueue_s= truct *wq, int cpu) put_pwq_unlocked(old_pwq); } =20 +/* the attrs @wq asked for, as spelled by its flags */ +static struct workqueue_attrs *alloc_wq_std_attrs(struct workqueue_struct = *wq) +{ + struct workqueue_attrs *attrs; + + attrs =3D alloc_workqueue_attrs(); + if (!attrs) + return NULL; + + if (wq->flags & WQ_HIGHPRI) + attrs->nice =3D HIGHPRI_NICE_LEVEL; + + if (wq->flags & __WQ_ORDERED) + attrs->ordered =3D true; + + return attrs; +} + static int alloc_and_link_pwqs(struct workqueue_struct *wq) { - bool highpri =3D wq->flags & WQ_HIGHPRI; + struct workqueue_attrs *attrs; int ret; =20 lockdep_assert_held(&wq_pool_mutex); @@ -5931,23 +5940,24 @@ static int alloc_and_link_pwqs(struct workqueue_str= uct *wq) if (!wq->cpu_pwq) goto enomem; =20 - if (!(wq->flags & WQ_UNBOUND)) { - ret =3D apply_workqueue_attrs_locked(wq, percpu_std_wq_attrs[highpri]); - } else if (wq->flags & __WQ_ORDERED) { - struct pool_workqueue *dfl_pwq; + attrs =3D alloc_wq_std_attrs(wq); + if (!attrs) + goto enomem; + + ret =3D apply_workqueue_attrs_locked(wq, attrs); + free_workqueue_attrs(attrs); + if (ret) + goto enomem; + + if (wq->flags & __WQ_ORDERED) { + struct pool_workqueue *dfl_pwq =3D rcu_access_pointer(wq->dfl_pwq); =20 - ret =3D apply_workqueue_attrs_locked(wq, ordered_wq_attrs[highpri]); /* there should only be single pwq for ordering guarantee */ - dfl_pwq =3D rcu_access_pointer(wq->dfl_pwq); - WARN(!ret && (wq->pwqs.next !=3D &dfl_pwq->pwqs_node || - wq->pwqs.prev !=3D &dfl_pwq->pwqs_node), + WARN(wq->pwqs.next !=3D &dfl_pwq->pwqs_node || + wq->pwqs.prev !=3D &dfl_pwq->pwqs_node, "ordering guarantee broken for workqueue %s\n", wq->name); - } else { - ret =3D apply_workqueue_attrs_locked(wq, unbound_std_wq_attrs[highpri]); } =20 - if (ret) - goto enomem; return 0; =20 enomem: @@ -8378,28 +8388,6 @@ void __init workqueue_init_early(void) init_cpu_worker_pool(pool, cpu, std_nice[i++]); } =20 - /* create default unbound, ordered and percpu wq attrs */ - for (i =3D 0; i < NR_STD_WORKER_POOLS; i++) { - struct workqueue_attrs *attrs; - - BUG_ON(!(attrs =3D alloc_workqueue_attrs())); - attrs->nice =3D std_nice[i]; - unbound_std_wq_attrs[i] =3D attrs; - - /* - * An ordered wq should have only one pwq as ordering is - * guaranteed by max_active which is enforced by pwqs. - */ - BUG_ON(!(attrs =3D alloc_workqueue_attrs())); - attrs->nice =3D std_nice[i]; - attrs->ordered =3D true; - ordered_wq_attrs[i] =3D attrs; - - BUG_ON(!(attrs =3D alloc_workqueue_attrs())); - attrs->nice =3D std_nice[i]; - percpu_std_wq_attrs[i] =3D attrs; - } - system_wq =3D alloc_workqueue("events", WQ_PERCPU | __WQ_DEPRECATED, 0); system_percpu_wq =3D alloc_workqueue("events", WQ_PERCPU, 0); system_highpri_wq =3D alloc_workqueue("events_highpri", --=20 2.53.0-Meta