diff options
author | Eric Dumazet <edumazet@google.com> | 2021-07-21 11:06:14 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-07-21 18:02:11 +0200 |
commit | 739b2adf99e99f076601df412ec9aa92302c701f (patch) | |
tree | 98e3a4ebdd8aac029583b1070a61d659ca26f3d9 /net/ipv4/tcp_input.c | |
parent | net: wwan: iosm: Switch to use module_pci_driver() macro (diff) | |
download | linux-739b2adf99e99f076601df412ec9aa92302c701f.tar.xz linux-739b2adf99e99f076601df412ec9aa92302c701f.zip |
tcp: avoid indirect call in tcp_new_space()
For tcp sockets, sk->sk_write_space is most probably sk_stream_write_space().
Other sk->sk_write_space() calls in TCP are slow path and do not deserve
any change.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_input.c')
-rw-r--r-- | net/ipv4/tcp_input.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 149ceb5c94ff..bef2c8b64d83 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c @@ -5383,7 +5383,7 @@ static void tcp_new_space(struct sock *sk) tp->snd_cwnd_stamp = tcp_jiffies32; } - sk->sk_write_space(sk); + INDIRECT_CALL_1(sk->sk_write_space, sk_stream_write_space, sk); } static void tcp_check_space(struct sock *sk) |