Skip to content

Commit 2807b3e

Browse files
mmhalNipaLocal
authored andcommitted
net: splice: Drop unused @flags
Since commit 79fddc4 ("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 <mhal@rbox.co> Signed-off-by: NipaLocal <nipa@local>
1 parent 0b1e542 commit 2807b3e

File tree

6 files changed

+6
-8
lines changed

6 files changed

+6
-8
lines changed

include/linux/skbuff.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4157,8 +4157,7 @@ int skb_store_bits(struct sk_buff *skb, int offset, const void *from, int len);
41574157
__wsum skb_copy_and_csum_bits(const struct sk_buff *skb, int offset, u8 *to,
41584158
int len);
41594159
int skb_splice_bits(struct sk_buff *skb, struct sock *sk, unsigned int offset,
4160-
struct pipe_inode_info *pipe, unsigned int len,
4161-
unsigned int flags);
4160+
struct pipe_inode_info *pipe, unsigned int len);
41624161
int skb_send_sock_locked(struct sock *sk, struct sk_buff *skb, int offset,
41634162
int len);
41644163
int skb_send_sock_locked_with_flags(struct sock *sk, struct sk_buff *skb,

net/core/skbuff.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3181,8 +3181,7 @@ static bool __skb_splice_bits(struct sk_buff *skb, struct pipe_inode_info *pipe,
31813181
* the fragments, and the frag list.
31823182
*/
31833183
int skb_splice_bits(struct sk_buff *skb, struct sock *sk, unsigned int offset,
3184-
struct pipe_inode_info *pipe, unsigned int tlen,
3185-
unsigned int flags)
3184+
struct pipe_inode_info *pipe, unsigned int tlen)
31863185
{
31873186
struct partial_page partial[MAX_SKB_FRAGS];
31883187
struct page *pages[MAX_SKB_FRAGS];

net/ipv4/tcp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -766,7 +766,7 @@ static int tcp_splice_data_recv(read_descriptor_t *rd_desc, struct sk_buff *skb,
766766
int ret;
767767

768768
ret = skb_splice_bits(skb, skb->sk, offset, tss->pipe,
769-
min(rd_desc->count, len), tss->flags);
769+
min(rd_desc->count, len));
770770
if (ret > 0)
771771
rd_desc->count -= ret;
772772
return ret;

net/kcm/kcmsock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1043,7 +1043,7 @@ static ssize_t kcm_splice_read(struct socket *sock, loff_t *ppos,
10431043
if (len > stm->full_len)
10441044
len = stm->full_len;
10451045

1046-
copied = skb_splice_bits(skb, sk, stm->offset, pipe, len, flags);
1046+
copied = skb_splice_bits(skb, sk, stm->offset, pipe, len);
10471047
if (copied < 0) {
10481048
err = copied;
10491049
goto err_out;

net/tls/tls_sw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2279,7 +2279,7 @@ ssize_t tls_sw_splice_read(struct socket *sock, loff_t *ppos,
22792279
}
22802280

22812281
chunk = min_t(unsigned int, rxm->full_len, len);
2282-
copied = skb_splice_bits(skb, sk, rxm->offset, pipe, chunk, flags);
2282+
copied = skb_splice_bits(skb, sk, rxm->offset, pipe, chunk);
22832283
if (copied < 0)
22842284
goto splice_requeue;
22852285

net/unix/af_unix.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3085,7 +3085,7 @@ static int unix_stream_splice_actor(struct sk_buff *skb,
30853085
{
30863086
return skb_splice_bits(skb, state->socket->sk,
30873087
UNIXCB(skb).consumed + skip,
3088-
state->pipe, chunk, state->splice_flags);
3088+
state->pipe, chunk);
30893089
}
30903090

30913091
static ssize_t unix_stream_splice_read(struct socket *sock, loff_t *ppos,

0 commit comments

Comments
 (0)