diff options
author | Jakub Kicinski <kuba@kernel.org> | 2022-11-03 21:38:42 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2022-11-03 23:21:54 +0300 |
commit | fbeb229a6622523c092a13c02bd0e15f69240dde (patch) | |
tree | a48bf5ff455cedae6555ef071e0d8bdb29487824 /include/net/sock.h | |
parent | d9095f92950bd16745b9ec24ebebc12d14b3a3e8 (diff) | |
parent | 9521c9d6a53df9c44a5f5ddbc229ceaf3cf79ef6 (diff) | |
download | linux-fbeb229a6622523c092a13c02bd0e15f69240dde.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
No conflicts.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/net/sock.h')
-rw-r--r-- | include/net/sock.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/net/sock.h b/include/net/sock.h index 928bb601fd8f..dc802640e5a0 100644 --- a/include/net/sock.h +++ b/include/net/sock.h @@ -1889,6 +1889,13 @@ void sock_kfree_s(struct sock *sk, void *mem, int size); void sock_kzfree_s(struct sock *sk, void *mem, int size); void sk_send_sigurg(struct sock *sk); +static inline void sock_replace_proto(struct sock *sk, struct proto *proto) +{ + if (sk->sk_socket) + clear_bit(SOCK_SUPPORT_ZC, &sk->sk_socket->flags); + WRITE_ONCE(sk->sk_prot, proto); +} + struct sockcm_cookie { u64 transmit_time; u32 mark; |