diff options
author | Eric Dumazet <edumazet@google.com> | 2020-11-09 15:13:49 -0800 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-11-10 17:57:14 -0800 |
commit | 7b58e63e744cbcdeafe0a52423014fd9c9f7e346 (patch) | |
tree | 9f9b4e2c1bc9dac9e1053805d90e1baf5ce09339 /net/ipv6 | |
parent | d6bb2d1e86903d3fbf895752ac2c0c2465534579 (diff) | |
download | linux-7b58e63e744cbcdeafe0a52423014fd9c9f7e346.tar.bz2 |
inet: udp{4|6}_lib_lookup_skb() skb argument is const
The skb is needed only to fetch the keys for the lookup.
Both functions are used from GRO stack, we do not want
accidental modification of the skb.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Alexander Lobakin <alobakin@pm.me>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/udp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c index 559611bef0e6..e152f8000db4 100644 --- a/net/ipv6/udp.c +++ b/net/ipv6/udp.c @@ -276,7 +276,7 @@ static struct sock *__udp6_lib_lookup_skb(struct sk_buff *skb, inet6_sdif(skb), udptable, skb); } -struct sock *udp6_lib_lookup_skb(struct sk_buff *skb, +struct sock *udp6_lib_lookup_skb(const struct sk_buff *skb, __be16 sport, __be16 dport) { const struct ipv6hdr *iph = ipv6_hdr(skb); |