[PATCH net-next v2 2/9] net: splice: Drop unused @flags
From: Michal Luczaj <hidden>
Date: 2025-06-26 08:34:18
Also in:
linux-rdma, linux-s390, lkml
Subsystem:
networking [general], networking [tcp], networking [tls], networking [unix sockets], the rest · Maintainers:
"David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Neal Cardwell, John Fastabend, Sabrina Dubroca, Kuniyuki Iwashima, Linus Torvalds
Since commit 79fddc4efd5d ("new helper: add_to_pipe()") which removed
`spd->flags` check in splice_to_pipe(), skb_splice_bits() does not use the
@flags argument.
Remove it and adapt callers. No functional change intended.
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: Michal Luczaj <redacted>
---
include/linux/skbuff.h | 3 +--
net/core/skbuff.c | 3 +--
net/ipv4/tcp.c | 2 +-
net/kcm/kcmsock.c | 2 +-
net/tls/tls_sw.c | 2 +-
net/unix/af_unix.c | 2 +-
6 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 4f6dcb37bae8ada524a1e8f8de44c259cfac695b..5b6f460c69b277124e788cfa0599486522e62c9c 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h@@ -4157,8 +4157,7 @@ int skb_store_bits(struct sk_buff *skb, int offset, const void *from, int len); __wsum skb_copy_and_csum_bits(const struct sk_buff *skb, int offset, u8 *to, int len); int skb_splice_bits(struct sk_buff *skb, struct sock *sk, unsigned int offset, - struct pipe_inode_info *pipe, unsigned int len, - unsigned int flags); + struct pipe_inode_info *pipe, unsigned int len); int skb_send_sock_locked(struct sock *sk, struct sk_buff *skb, int offset, int len); int skb_send_sock_locked_with_flags(struct sock *sk, struct sk_buff *skb,
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index ae0f1aae3c91d914020c64e0703732b9c6cd8511..02ead44a82bb71d30d294a6931943d07cf7c7177 100644
--- a/net/core/skbuff.c
+++ b/net/core/skbuff.c@@ -3181,8 +3181,7 @@ static bool __skb_splice_bits(struct sk_buff *skb, struct pipe_inode_info *pipe, * the fragments, and the frag list. */ int skb_splice_bits(struct sk_buff *skb, struct sock *sk, unsigned int offset, - struct pipe_inode_info *pipe, unsigned int tlen, - unsigned int flags) + struct pipe_inode_info *pipe, unsigned int tlen) { struct partial_page partial[MAX_SKB_FRAGS]; struct page *pages[MAX_SKB_FRAGS];
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
index 8a3c99246d2ed32ba45849b56830bf128e265763..46997793d87ab40dcd1e1dd041e4641e287e1b7e 100644
--- a/net/ipv4/tcp.c
+++ b/net/ipv4/tcp.c@@ -766,7 +766,7 @@ static int tcp_splice_data_recv(read_descriptor_t *rd_desc, struct sk_buff *skb, int ret; ret = skb_splice_bits(skb, skb->sk, offset, tss->pipe, - min(rd_desc->count, len), tss->flags); + min(rd_desc->count, len)); if (ret > 0) rd_desc->count -= ret; return ret;
diff --git a/net/kcm/kcmsock.c b/net/kcm/kcmsock.c
index 24aec295a51cf737912f1aefe81556bd9f23331e..8140c9c9cc2cb7aa71eaceab8a019d882bc454aa 100644
--- a/net/kcm/kcmsock.c
+++ b/net/kcm/kcmsock.c@@ -1043,7 +1043,7 @@ static ssize_t kcm_splice_read(struct socket *sock, loff_t *ppos, if (len > stm->full_len) len = stm->full_len; - copied = skb_splice_bits(skb, sk, stm->offset, pipe, len, flags); + copied = skb_splice_bits(skb, sk, stm->offset, pipe, len); if (copied < 0) { err = copied; goto err_out;
diff --git a/net/tls/tls_sw.c b/net/tls/tls_sw.c
index fc88e34b7f33fefed8aa3c26e1f6eed07cd20853..5bca6cfce749aa9fd64da764b2a0d6a4c936efac 100644
--- a/net/tls/tls_sw.c
+++ b/net/tls/tls_sw.c@@ -2266,7 +2266,7 @@ ssize_t tls_sw_splice_read(struct socket *sock, loff_t *ppos, } chunk = min_t(unsigned int, rxm->full_len, len); - copied = skb_splice_bits(skb, sk, rxm->offset, pipe, chunk, flags); + copied = skb_splice_bits(skb, sk, rxm->offset, pipe, chunk); if (copied < 0) goto splice_requeue;
diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c
index 1e320f89168d1cd4b5e8fa56565cce9f008ab857..235319a045a1238cf27791dfefa9e61b4a593551 100644
--- a/net/unix/af_unix.c
+++ b/net/unix/af_unix.c@@ -3070,7 +3070,7 @@ static int unix_stream_splice_actor(struct sk_buff *skb, { return skb_splice_bits(skb, state->socket->sk, UNIXCB(skb).consumed + skip, - state->pipe, chunk, state->splice_flags); + state->pipe, chunk); } static ssize_t unix_stream_splice_read(struct socket *sock, loff_t *ppos,
--
2.49.0