[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250702-splice-drop-unused-v3-3-55f68b60d2b7@rbox.co>
Date: Wed, 02 Jul 2025 15:38:09 +0200
From: Michal Luczaj <mhal@...x.co>
To: "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
Ayush Sawal <ayush.sawal@...lsio.com>, Andrew Lunn <andrew+netdev@...n.ch>,
David Ahern <dsahern@...nel.org>, Neal Cardwell <ncardwell@...gle.com>,
Kuniyuki Iwashima <kuniyu@...gle.com>, Wenjia Zhang <wenjia@...ux.ibm.com>,
Jan Karcher <jaka@...ux.ibm.com>, "D. Wythe" <alibuda@...ux.alibaba.com>,
Tony Lu <tonylu@...ux.alibaba.com>, Wen Gu <guwen@...ux.alibaba.com>
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-rdma@...r.kernel.org, linux-s390@...r.kernel.org,
Michal Luczaj <mhal@...x.co>
Subject: [PATCH net-next v3 3/6] net: splice: Drop nr_pages_max
initialization
splice_pipe_desc::nr_pages_max was initialized unnecessarily in commit
41c73a0d44c9 ("net: speedup skb_splice_bits()"). spd_fill_page() compares
spd->nr_pages against a constant MAX_SKB_FRAGS, which makes setting
nr_pages_max redundant.
Remove the assignment. No functional change intended.
Reviewed-by: Simon Horman <horms@...nel.org>
Signed-off-by: Michal Luczaj <mhal@...x.co>
---
net/core/skbuff.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index a34fe37cf7a508c8380e35522d9cde266aa440f9..3041f7a3560d58270dffdf923825758f274c8511 100644
--- a/net/core/skbuff.c
+++ b/net/core/skbuff.c
@@ -3189,7 +3189,6 @@ int skb_splice_bits(struct sk_buff *skb, struct sock *sk, unsigned int offset,
struct splice_pipe_desc spd = {
.pages = pages,
.partial = partial,
- .nr_pages_max = MAX_SKB_FRAGS,
.ops = &nosteal_pipe_buf_ops,
.spd_release = sock_spd_release,
};
--
2.49.0
Powered by blists - more mailing lists