From nobody Fri Jun 12 11:08:41 2026 Received: from mail-wm1-f52.google.com (mail-wm1-f52.google.com [209.85.128.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B39C6481AA3 for ; Fri, 15 May 2026 13:51:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778853119; cv=none; b=P/TpIIrWThwVWIUqpi9UEduoNakYgcjeFF4VOJkCcs7gdPC3/LGxV4epQd5LdyorNpTdslViRtkEkNOdDjwDrChQZyORxVuqkX/k6krbPBLNfJnNcCPkb4dFZmh2fy66dMD3uEbZWMf3jRq9gy95K5v17rNdJsMcJMQkV7Y0cLg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778853119; c=relaxed/simple; bh=mwbCUn08CWMwL0woqy177gkj8PZXx4Uk/KthAashRy8=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=djA/THuow6eihVWvsnzAltG77HFARuPSXlOZdcsU/CZIvp0AGHJwKkVLsw7zuqI6aq8LvzxZfkpqBeCoDWi9pKdScs1m9iew5sctsCpgHLrlXXR6vVrQnSYQugEWMBxURAEfUS7kY05hJlUcnn45gO2xS+8pBaMRb9OFzT1hB4s= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com; spf=pass smtp.mailfrom=suse.com; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b=frA/4vE7; arc=none smtp.client-ip=209.85.128.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b="frA/4vE7" Received: by mail-wm1-f52.google.com with SMTP id 5b1f17b1804b1-48d146705b4so108744465e9.3 for ; Fri, 15 May 2026 06:51:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1778853114; x=1779457914; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=OmJGUnALjoD0KZePhh+NZjTK3Hla1q67wmp2q20EKW8=; b=frA/4vE7ssPD+QcC4Tcl+xLZt2FpelSuKYFowxo51rSoM4XuJ/Q3z7jmLPusNU6bjK eMpAaN23JWjqy7jaoHyYtaHorGgJAcSrMqzCmWPFg+PwvjjoOj8F6aqHm4iGYdtbaW8h /O5lgszeW58qhpiWvdFuHMfDcaqFEyDuqoaU1hFNgUGyCx/vu0WqNP5hw3Zf1TRecngq I3TrYPsUS8FFq5sm5dT0o0bp/az6oEax8Tn2ktsKMfK8LpxxvsPJUcaUy9dWhfbM1fPr DBGs/81vh5n2mkIETeDfu+hAcJV3agQWkgnKrMiFFPSHWWlNgvh+d16Hn/7J5P/ugayu xa1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778853114; x=1779457914; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=OmJGUnALjoD0KZePhh+NZjTK3Hla1q67wmp2q20EKW8=; b=EvOdvJLdKW2D73EdMpv81bPjqxMlDOuFAiQU0WiQ8QxxhYuiY2iezjqnvzLTbgRiZN HAgtmsztD8cLJSLSIM/mxoLnDXKtHNEKsZo0WZxxO37wjjrE/WzfdpvYCNtBGna+0P4O 5V6NSoEWcSfA25VXxkDbS0mWLUv3Tv1COMBMQ845ktlIo3vSNRPvKGfS1oNgxj3a4kK+ cDuzzcWEijudWOvFlB2JX5U4gnzV+aPiJaevMPmPkoqly5N2fKB9ysjfUpHa2SG8B+ZY ewAbzLSRddX55v7H2PXNc46qqu93spEFmWnRK8vqGfX8IVJUZod4iHMX4YPVvml3Lezy Mjpg== X-Gm-Message-State: AOJu0Yzm0KxnautqTpCTW0aSxx8SQiebZmV2BrDsFKMrMM+UFUEIUyd8 ITrFXCRYvHFYnZ1VNS/gIAYkqx3JE051btVZavCyPcNb4CwR6IOjf61UtAp8ynTjuDvDdj69uzL Cq3JyOaE= X-Gm-Gg: Acq92OGUGhpMRC+6MUZzM+koWh7Gs2besKJE8AQxJ0dd937NisLt7Vtp7QnsaBOWv/C IzbDZCXGL5ZwFuN7vcrb7ZV5mhJRzDvbFkyXOL6iOOBLpbR9SEHk9RzwNyEwH5+J/mRrziW76dS +6raYwNjBM4KQCMHeQE9+jiawP1Nz000m234NM3/Lu/OC5aNGM+TSMIaBI1SR71zncfJwtUi3mS unPZKKkQotFBheHl07p+nGyyAF/HC2KoSxzrcm+90MkUwNyvzPNl7eOqTPqOgEPg8ZhhR4DY23d /YO0sgCItrv26xGpBKldTsRZqKejzAXuHeOK4BgAtuQH5M8sJmvi5AF4kV0DoUB1pHc+/J2KlKS 3A/mX//VMJM/DAObA1K+jb1k9WuK+Z64YmAKXPe8dstipb/AGr/6EgEqrzsBV/rFt4yv0F0FOF0 bVU8ZZtnYjRqcULi17lxkSxe1kGX8nVD/Fw3ISCfVkL3L8QOzuNY3lskrFwA== X-Received: by 2002:a05:600c:34c4:b0:48a:89d9:a419 with SMTP id 5b1f17b1804b1-48fe60ecdafmr58940795e9.11.1778853113974; Fri, 15 May 2026 06:51:53 -0700 (PDT) Received: from localhost.localdomain ([2a00:6d43:105:c401:e307:1a37:2e76:ce91]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-48fdafc6741sm79592675e9.2.2026.05.15.06.51.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 May 2026 06:51:53 -0700 (PDT) From: Marco Crivellari To: linux-kernel@vger.kernel.org, netdev@vger.kernel.org Cc: Tejun Heo , Lai Jiangshan , Frederic Weisbecker , Sebastian Andrzej Siewior , Marco Crivellari , Michal Hocko , Simon Horman , Eric Dumazet , "David S . Miller" , Jakub Kicinski , Paolo Abeni , David Ahern , Ido Schimmel , Simon Horman Subject: [PATCH v2 net-next 1/2] ipmr: Replace use of system_unbound_wq with system_dfl_wq Date: Fri, 15 May 2026 15:51:36 +0200 Message-ID: <20260515135143.259669-2-marco.crivellari@suse.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260515135143.259669-1-marco.crivellari@suse.com> References: <20260515135143.259669-1-marco.crivellari@suse.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" 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. Cc: David Ahern Cc: Ido Schimmel Cc: Simon Horman Link: https://lore.kernel.org/all/20250221112003.1dSuoGyc@linutronix.de/ Suggested-by: Tejun Heo Signed-off-by: Marco Crivellari Reviewed-by: Ido Schimmel --- net/ipv4/ipmr_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/ipv4/ipmr_base.c b/net/ipv4/ipmr_base.c index 3930d612c3de..867b24beded1 100644 --- a/net/ipv4/ipmr_base.c +++ b/net/ipv4/ipmr_base.c @@ -39,7 +39,7 @@ static void __mr_free_table(struct work_struct *work) =20 void mr_table_free(struct mr_table *mrt) { - queue_rcu_work(system_unbound_wq, &mrt->work); + queue_rcu_work(system_dfl_wq, &mrt->work); } =20 struct mr_table * --=20 2.54.0 From nobody Fri Jun 12 11:08:41 2026 Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A95EA481FC0 for ; Fri, 15 May 2026 13:51:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778853119; cv=none; b=d+lKXUYdkFHOdLHTE1kITBqffV2UsYBIidKK6n/TDHdoRCEldKxF/s4TBT0xZoedySEzhIm2MEgUZ06nHfH8j/j3Yq7ka/qdzqs9bsLSY9P4epxqXK0BAs+OAix/v7Lbu8pjBOXoB6oyY6XiBVM8+IfYkAVn1568FUcGeenh88Y= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778853119; c=relaxed/simple; bh=1BUYyH6FJjq+uusotHC0RGXtPrhUwifyqTlT3V5ZIPE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=SxpGJPpkEOzqGvd/pbOuif8KhF+MjKBzxsZdmePrCIS9dZhr/Nbezafxay4jCUKVyYAntA3NiIvL1wJqFdDEmt5cvmSbAgHgRASkpy/4MwOPcmnuKunCI/klUWhQHNMiQHVfwNtM0Ou/qD40F4io4stmDFw1J5QPdxw/YaUjbdY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com; spf=pass smtp.mailfrom=suse.com; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b=crNLsmaw; arc=none smtp.client-ip=209.85.128.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b="crNLsmaw" Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-4891b0786beso60103905e9.1 for ; Fri, 15 May 2026 06:51:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1778853115; x=1779457915; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=VA+bG9JdAKJ8uzHR2B1IeGdcCKEHHSGhLn7eeSbzPvg=; b=crNLsmawSy5I0G7CrPgHYnHFdvt+hulqPo5UoyW92rWd76+QKownrE2B3DUYWlO1JL 2/22skQB/KbImVFeu6hVTX9ex3e52K3JsaRa5wmBsb0k/u6nr7M3G9T6OHFtwilq65sW xwON24M9D5Ue3nFkwPQ0EaenIl9CDIOWvOme1bsTWeWi3cJMa2KErOp72g6lj3ASjczz tN2C7Cb3VGlaAz5yc2hQRGrjvEszxAa2qzS4983uqL5JYl0iZLxPKpvHDI4qGnnpF013 1Y2qbng4JPUbuq2TYwUpPeD2xLWni6ZfPsnmTz11aZ/gIdO9NUhV7G7Qop9kYNUMCcpy nhYA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778853115; x=1779457915; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=VA+bG9JdAKJ8uzHR2B1IeGdcCKEHHSGhLn7eeSbzPvg=; b=CgkgoVmourvdZV4vjCh0gs8wibsWjaZPfl6HedWt6/ejvSt1bkws7bLn4M21LMLvF+ 9xpgM5jFlwXUSWzV8I6C6sK/4tKq33Ri6kmNwgTJTyAWRvsmrpKGQGOKXNLxdF/AC0ob 3vZGB+dHZ2XaFvBv3oxJvuO5VMoRZqXawGb3YkuheV+Z0lfFuGUzDLRWfPCUgq2ZaYZf 6Z8LIkKiGOq+tPMLxXlb+zbfc6rUj4qVFhuYlag8zU0aGMrV4y/lAUTJYjCM+lD595gk X4M3VXS6A4Q15xCpJlJwpZ3iX3dRh2joyqm4OnV0RUzFBL5PE+xk+eFmgAAKe8fTZhgH QOhA== X-Gm-Message-State: AOJu0YzILHMwTJj2QmfLBF1u73+PT6WhYy3hyhBy4NywkXVv5163vfCF e+3AeB1PDyPfgfjC6VUy51B6nM/6AjLnSLcKuPI+PwrERe1saqcZCeREWxgYAcM654Jc2csnvOs lbOxPLVg= X-Gm-Gg: Acq92OFM0q/lTer/3gSCm2FXrtwSGUgRmtJZl2z+tvDDrxL44v/T0Hfbd+Z28V0uVes I+zLFTTyBQWRX3vRUbIL1anahWyJMQ1GG4BuXU90vWBWafiS8wIes/E59RZ6xY8tkrivnShub2d ZKhncM5MexAbez6PG+0ud7aZOXSB7CGfGgi/WFwTLmYZXbeGAokE5LjHtQ+rK85V0jJVxfnzAto IIBnBAyICXDMNfwge/YxZOIIORSqpodNV+moO2GFlnSX6ODvbE7m6JdkEwmMYR4w4RnsjgL/oA3 xqNnrh/HgMIN/esE5llSvQfWVJ9b/dJZYp2II82J+xfTsOBO3AL8uFvDCWcD2D4Ax1edLuRyEOW 72JuaO5F7aZDOaRKBHrCUu37EZMrg5fLouS0jJsLJykVQVeUJg7EAgVxyJtzOTgjHZKP0hI8dRO 5B8WqyPyx+O73gS7byiNtidnoyu4jh5zZSWT8Kua76x3N/VH8= X-Received: by 2002:a05:600c:4fc9:b0:489:1c1f:35df with SMTP id 5b1f17b1804b1-48fe60e58ecmr54916975e9.10.1778853115149; Fri, 15 May 2026 06:51:55 -0700 (PDT) Received: from localhost.localdomain ([2a00:6d43:105:c401:e307:1a37:2e76:ce91]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-48fdafc6741sm79592675e9.2.2026.05.15.06.51.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 May 2026 06:51:54 -0700 (PDT) From: Marco Crivellari To: linux-kernel@vger.kernel.org, netdev@vger.kernel.org Cc: Tejun Heo , Lai Jiangshan , Frederic Weisbecker , Sebastian Andrzej Siewior , Marco Crivellari , Michal Hocko , Simon Horman , Eric Dumazet , "David S . Miller" , Jakub Kicinski , Paolo Abeni , Julian Anastasov , Pablo Neira Ayuso , Florian Westphal , Phil Sutter , lvs-devel@vger.kernel.org, netfilter-devel@vger.kernel.org, coreteam@netfilter.org Subject: [PATCH v2 net-next 2/2] ipvs: Replace use of system_unbound_wq with system_dfl_long_wq Date: Fri, 15 May 2026 15:51:37 +0200 Message-ID: <20260515135143.259669-3-marco.crivellari@suse.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260515135143.259669-1-marco.crivellari@suse.com> References: <20260515135143.259669-1-marco.crivellari@suse.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" 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. This specific work is considered long, so enqueue it using system_dfl_long_wq instead of system_dfl_wq. Cc: Julian Anastasov Cc: Pablo Neira Ayuso Cc: Florian Westphal Cc: Phil Sutter Cc: lvs-devel@vger.kernel.org Cc: netfilter-devel@vger.kernel.org Cc: coreteam@netfilter.org Link: https://lore.kernel.org/all/20250221112003.1dSuoGyc@linutronix.de/ Suggested-by: Tejun Heo Signed-off-by: Marco Crivellari --- net/netfilter/ipvs/ip_vs_conn.c | 4 ++-- net/netfilter/ipvs/ip_vs_ctl.c | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/net/netfilter/ipvs/ip_vs_conn.c b/net/netfilter/ipvs/ip_vs_con= n.c index 9ea6b4fa78bf..4a5c6762489c 100644 --- a/net/netfilter/ipvs/ip_vs_conn.c +++ b/net/netfilter/ipvs/ip_vs_conn.c @@ -285,7 +285,7 @@ static inline int ip_vs_conn_hash(struct ip_vs_conn *cp) /* Schedule resizing if load increases */ if (atomic_read(&ipvs->conn_count) > t->u_thresh && !test_and_set_bit(IP_VS_WORK_CONN_RESIZE, &ipvs->work_flags)) - mod_delayed_work(system_unbound_wq, &ipvs->conn_resize_work, 0); + mod_delayed_work(system_dfl_long_wq, &ipvs->conn_resize_work, 0); =20 return ret; } @@ -916,7 +916,7 @@ static void conn_resize_work_handler(struct work_struct= *work) =20 out: /* Monitor if we need to shrink table */ - queue_delayed_work(system_unbound_wq, &ipvs->conn_resize_work, + queue_delayed_work(system_dfl_long_wq, &ipvs->conn_resize_work, more_work ? 1 : 2 * HZ); } =20 diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_ctl.c index c7c7f6a7a9f6..49cbc7cfe770 100644 --- a/net/netfilter/ipvs/ip_vs_ctl.c +++ b/net/netfilter/ipvs/ip_vs_ctl.c @@ -800,7 +800,7 @@ static void svc_resize_work_handler(struct work_struct = *work) if (!READ_ONCE(ipvs->enable) || !more_work || test_bit(IP_VS_WORK_SVC_NORESIZE, &ipvs->work_flags)) return; - queue_delayed_work(system_unbound_wq, &ipvs->svc_resize_work, 1); + queue_delayed_work(system_dfl_long_wq, &ipvs->svc_resize_work, 1); } =20 static inline void @@ -1833,7 +1833,7 @@ ip_vs_add_service(struct netns_ipvs *ipvs, struct ip_= vs_service_user_kern *u, /* Schedule resize work */ if (t && ip_vs_get_num_services(ipvs) > t->u_thresh && !test_and_set_bit(IP_VS_WORK_SVC_RESIZE, &ipvs->work_flags)) - queue_delayed_work(system_unbound_wq, &ipvs->svc_resize_work, + queue_delayed_work(system_dfl_long_wq, &ipvs->svc_resize_work, 1); =20 *svc_p =3D svc; @@ -2078,7 +2078,7 @@ static int ip_vs_del_service(struct ip_vs_service *sv= c) } else if (ns <=3D t->l_thresh && !test_and_set_bit(IP_VS_WORK_SVC_RESIZE, &ipvs->work_flags)) { - queue_delayed_work(system_unbound_wq, &ipvs->svc_resize_work, + queue_delayed_work(system_dfl_long_wq, &ipvs->svc_resize_work, 1); } return 0; @@ -2511,7 +2511,7 @@ static int ipvs_proc_conn_lfactor(const struct ctl_ta= ble *table, int write, } else { WRITE_ONCE(*valp, val); if (rcu_access_pointer(ipvs->conn_tab)) - mod_delayed_work(system_unbound_wq, + mod_delayed_work(system_dfl_long_wq, &ipvs->conn_resize_work, 0); } } @@ -2543,7 +2543,7 @@ static int ipvs_proc_svc_lfactor(const struct ctl_tab= le *table, int write, READ_ONCE(ipvs->enable) && !test_bit(IP_VS_WORK_SVC_NORESIZE, &ipvs->work_flags)) - mod_delayed_work(system_unbound_wq, + mod_delayed_work(system_dfl_long_wq, &ipvs->svc_resize_work, 0); mutex_unlock(&ipvs->service_mutex); } --=20 2.54.0