From mboxrd@z Thu Jan 1 00:00:00 1970 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 19C8948034D; Thu, 2 Jul 2026 12:20:41 +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=1782994843; cv=none; b=lIePguHGvsOlxlMYy9E4jlrFygeqTBEvAzYHcOSgnRSeeGHsD7pUBTAUD2SLkxd/NbUe37GmosTJx0JwunLxN2426xqThusxOzb9Mg4qhlTVP1bHvf1oF5xyRtYtafbriwmcUyU9KvVZDcW590c8ToIpaKDpqBurspgTT1qD7Ng= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782994843; c=relaxed/simple; bh=0ThWpvu+u8I46Mlfxxm4A0z2go2lo6ujJH2oBZMMg1A=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=MFLtbDTHt/AYEOU8Hy4CukkMREoh8yU5YKS2YBWO7Uhf2LMbckAawRnDx5TuHbbq43UxEq0WKjfPBJDwnMTcSfQZNIrwAvhDI/Zy+yd3mYr0Vr+eVB15pwmcYPAttUKtGw3HOOouBIuq63VPV+gv2hTdBCBJvQJ/OTZYjuOuqtc= 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=GoG+OPoh; 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="GoG+OPoh" 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=TGx5VY3ERjSYqAcxjm9X6+Nhm8noUM4A9BBQEFNdiks=; b=GoG+OPohKUpPLUknNEJ7XwaOS5 zWo61M5xRABT9vM0HAX5Uv1qatZ4FpkrXuMKC0zn9cMULnkP6pLuhNjnxI6VRS/sM1QHWC3Jmb1Nv Im+TRzwEdqFHiJFDLbRfhyNPhjpfpKowTjUPr4XWidFxwwRRAcLv/h+dWZ/1nzZFyhfJyHVQWeVGo itWVfRiy7Q5p5VSgrfyh5jMbVGpMKAdgj2RbfpURsSJs/mv94nVbX4RaWc4VtLSRnbifQYponewrq /Y+pP1ny67GT5AHSK9cy8VC3lVgMrzwt/yYm6gvsbOZ5xs75dzeLaq85nArlqmWiN8XEnxt1gBjvm r+nuRj+w==; 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 1wfGPG-008cQZ-0q; Thu, 02 Jul 2026 12:20:38 +0000 From: Breno Leitao Date: Thu, 02 Jul 2026 05:19:47 -0700 Subject: [PATCH net-next v2 3/8] netconsole: move refill_skbs_work_handler() from netpoll Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20260702-netconsole_move_more-v2-3-1ebedd921dcb@debian.org> References: <20260702-netconsole_move_more-v2-0-1ebedd921dcb@debian.org> In-Reply-To: <20260702-netconsole_move_more-v2-0-1ebedd921dcb@debian.org> To: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman , Andrew Lunn Cc: netdev@vger.kernel.org, asantostc@gmail.com, gustavold@gmail.com, linux-kernel@vger.kernel.org, Breno Leitao , kernel-team@meta.com X-Mailer: b4 0.14.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=2424; i=leitao@debian.org; h=from:subject:message-id; bh=0ThWpvu+u8I46Mlfxxm4A0z2go2lo6ujJH2oBZMMg1A=; b=owEBbQKS/ZANAwAIATWjk5/8eHdtAcsmYgBqRleFHszTowoPKQ23s/LnOfPFQfh1Q7UOjTxG5 XXk9nGpbtiJAjMEAAEIAB0WIQSshTmm6PRnAspKQ5s1o5Of/Hh3bQUCakZXhQAKCRA1o5Of/Hh3 bUGmD/9219sc+OCElsiyQrS5DsnnBpVaerR1fGEw/WjQHH95xnz4IHAswP3DE4QAyxVecGmmQ0P TKfDb6xX8DRGDbzyvVYinfBJqu8d7L4tqizcIxTv3IrvziDC54oBYFVPRuiKaWpuIr/YYrRV4yB 3vY9fEtiRVly9XK9I7Y3BOzl4TvRcSSJ8zWNS6iXJvLJSseyRXLVoy/xTvG4tiZCHwRIHtOPyRF BHLKXFKuQ3kH5O4tjqMB96sO5eB9jCkfzTxQm2hIghpV4D/06PAB0ohiasY7Zy+Du/AVer5Jzyd gfEA2mu6Dqdlp/JhPL/o/uFN7S2geflUMvdz+5teObQbF474YAw5WzvYKQIUQRYELgwdFCpw7M4 efSbDv5mShAl9bjg0nHH5ZqkNO9wVWNX8vuQsc7NRelM1//TNJ7WziBEDjXES1KMxhY2Cqle3vZ M4DT4taC4meu1J+Dql55DsPw9Iwcdz0We8S4/X8FuAVl2rW3bPxa/UzuIOrjjSoPNWA6Q/+1x3W BhgQxEiBI/CQaWVxSROTd/R1F9CTimKbp/PCo/xLC7+yKtb2qA24iAcyiAigAH5u2PFQ8SZC9y2 uuFrl/bH2i36RwR8vUxU39H2QyMGJpiiwcoFiwlXJVPM4SrbOHtD2oxbclMmzj2+UniVgrtzscD sviMXK7ICPDebMg== X-Developer-Key: i=leitao@debian.org; a=openpgp; fpr=AC8539A6E8F46702CA4A439B35A3939FFC78776D X-Debian-User: leitao The work handler is wired via INIT_WORK() in netconsole_skb_pool_init() and has no other callers since the previous patch took the skb pool lifecycle out of __netpoll_setup(). Move the function body into drivers/net/netconsole.c as a file-static helper, drop EXPORT_SYMBOL_GPL() and remove the prototype from . Pure code motion: the body is unchanged and still calls the exported refill_skbs() in net/core/netpoll.c. Signed-off-by: Breno Leitao --- drivers/net/netconsole.c | 8 ++++++++ include/linux/netpoll.h | 1 - net/core/netpoll.c | 9 --------- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c index 78a4f27322fe2..59b1f7d6f103a 100644 --- a/drivers/net/netconsole.c +++ b/drivers/net/netconsole.c @@ -292,6 +292,14 @@ static void netcons_release_dev(struct netconsole_target *nt) memset(&nt->np.dev_name, 0, IFNAMSIZ); } +static void refill_skbs_work_handler(struct work_struct *work) +{ + struct netpoll *np = + container_of(work, struct netpoll, refill_wq); + + refill_skbs(np); +} + /* Initialise the per-target skb pool that find_skb() falls back to and * seed it. Pair with netconsole_skb_pool_flush() at the matching * netpoll teardown. diff --git a/include/linux/netpoll.h b/include/linux/netpoll.h index a7b96e1792207..51e5863d8e678 100644 --- a/include/linux/netpoll.h +++ b/include/linux/netpoll.h @@ -91,7 +91,6 @@ void do_netpoll_cleanup(struct netpoll *np); netdev_tx_t netpoll_send_skb(struct netpoll *np, struct sk_buff *skb); void netpoll_zap_completion_queue(void); void refill_skbs(struct netpoll *np); -void refill_skbs_work_handler(struct work_struct *work); void skb_pool_flush(struct netpoll *np); #ifdef CONFIG_NETPOLL diff --git a/net/core/netpoll.c b/net/core/netpoll.c index fd21e69c8214e..7088cf0df43ce 100644 --- a/net/core/netpoll.c +++ b/net/core/netpoll.c @@ -362,15 +362,6 @@ void skb_pool_flush(struct netpoll *np) } EXPORT_SYMBOL_GPL(skb_pool_flush); -void refill_skbs_work_handler(struct work_struct *work) -{ - struct netpoll *np = - container_of(work, struct netpoll, refill_wq); - - refill_skbs(np); -} -EXPORT_SYMBOL_GPL(refill_skbs_work_handler); - int __netpoll_setup(struct netpoll *np, struct net_device *ndev) { struct netpoll_info *npinfo; -- 2.53.0-Meta