diff options
author | Simon Horman <simon.horman@netronome.com> | 2016-06-09 12:03:34 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-06-09 21:23:37 +0300 |
commit | adba931fbc825efca7c821f0d76baed0a8dc9189 (patch) | |
tree | 185fe365282c126fc93d05f5ed3fc463fc86c9b6 /net/ipv6 | |
parent | b8d99ba06b2163b4e14ba458fe7f47dfb09f61d3 (diff) | |
download | linux-adba931fbc825efca7c821f0d76baed0a8dc9189.tar.xz |
sit: remove unnecessary protocol check in ipip6_tunnel_xmit()
ipip6_tunnel_xmit() is called immediately after checking that
skb->protocol is htons(ETH_P_IPV6) so there is no need
to check it a second time.
Found by inspection.
Signed-off-by: Simon Horman <simon.horman@netronome.com>
Reviewed-by: Dinan Gunawardena <dinan.gunawardena@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/sit.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/net/ipv6/sit.c b/net/ipv6/sit.c index 0a5a255277e5..d9f2bd6ef72d 100644 --- a/net/ipv6/sit.c +++ b/net/ipv6/sit.c @@ -825,9 +825,6 @@ static netdev_tx_t ipip6_tunnel_xmit(struct sk_buff *skb, u8 protocol = IPPROTO_IPV6; int t_hlen = tunnel->hlen + sizeof(struct iphdr); - if (skb->protocol != htons(ETH_P_IPV6)) - goto tx_error; - if (tos == 1) tos = ipv6_get_dsfield(iph6); |