Skip to content
Snippets Groups Projects
Commit adba931f authored by Simon Horman's avatar Simon Horman Committed by David S. Miller
Browse files

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: default avatarSimon Horman <simon.horman@netronome.com>
Reviewed-by: default avatarDinan Gunawardena <dinan.gunawardena@netronome.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b8d99ba0
No related branches found
No related tags found
No related merge requests found
......@@ -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);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment