diff options
author | Jiri Benc <jbenc@redhat.com> | 2016-02-18 11:22:52 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-02-18 20:34:54 +0100 |
commit | 7f290c94352e59b1d720055fce760a69a63bd0a1 (patch) | |
tree | f6c595f28145dc17d4dd983c0e0d64c19e1ebbfd /drivers/net/geneve.c | |
parent | vxlan: move vxlan device lookup before iptunnel_pull_header (diff) | |
download | linux-7f290c94352e59b1d720055fce760a69a63bd0a1.tar.xz linux-7f290c94352e59b1d720055fce760a69a63bd0a1.zip |
iptunnel: scrub packet in iptunnel_pull_header
Part of skb_scrub_packet was open coded in iptunnel_pull_header. Let it call
skb_scrub_packet directly instead.
Signed-off-by: Jiri Benc <jbenc@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/geneve.c')
-rw-r--r-- | drivers/net/geneve.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/geneve.c b/drivers/net/geneve.c index 4ceccf871b3f..dfbe3ca687f7 100644 --- a/drivers/net/geneve.c +++ b/drivers/net/geneve.c @@ -237,7 +237,6 @@ static void geneve_rx(struct geneve_dev *geneve, struct geneve_sock *gs, } skb_reset_mac_header(skb); - skb_scrub_packet(skb, !net_eq(geneve->net, dev_net(geneve->dev))); skb->protocol = eth_type_trans(skb, geneve->dev); skb_postpull_rcsum(skb, eth_hdr(skb), ETH_HLEN); @@ -356,7 +355,8 @@ static int geneve_udp_encap_recv(struct sock *sk, struct sk_buff *skb) opts_len = geneveh->opt_len * 4; if (iptunnel_pull_header(skb, GENEVE_BASE_HLEN + opts_len, - htons(ETH_P_TEB))) + htons(ETH_P_TEB), + !net_eq(geneve->net, dev_net(geneve->dev)))) goto drop; geneve_rx(geneve, gs, skb); |