#include <linux/if_tunnel.h>
#include <linux/if_vlan.h>
#include <linux/in.h>
-#include <linux/if_vlan.h>
-#include <linux/in.h>
#include <linux/in_route.h>
#include <linux/inetdevice.h>
#include <linux/jhash.h>
int tunnel_hlen,
__be32 seq, __be16 gre64_flag)
{
- struct net *net = ovs_dp_get_net(vport->dp);
struct rtable *rt;
int min_headroom;
__be16 df;
__be32 saddr;
int err;
- forward_ip_summed(skb, true);
-
/* Route lookup */
saddr = OVS_CB(skb)->tun_key->ipv4_src;
rt = find_route(ovs_dp_get_net(vport->dp),
OVS_CB(skb)->tun_key->ipv4_dst,
IPPROTO_GRE,
OVS_CB(skb)->tun_key->ipv4_tos,
- skb_get_mark(skb));
+ skb->mark);
if (IS_ERR(rt)) {
err = PTR_ERR(rt);
goto error;
goto err_free_rt;
}
- if (unlikely(vlan_deaccel_tag(skb))) {
- err = -ENOMEM;
- goto err_free_rt;
+ if (vlan_tx_tag_present(skb)) {
+ if (unlikely(!__vlan_put_tag(skb,
+ skb->vlan_proto,
+ vlan_tx_tag_get(skb)))) {
+ err = -ENOMEM;
+ goto err_free_rt;
+ }
+ vlan_set_tci(skb, 0);
}
/* Push Tunnel header. */
skb->local_df = 1;
- return iptunnel_xmit(net, rt, skb, saddr,
+ return iptunnel_xmit(rt, skb, saddr,
OVS_CB(skb)->tun_key->ipv4_dst, IPPROTO_GRE,
OVS_CB(skb)->tun_key->ipv4_tos,
OVS_CB(skb)->tun_key->ipv4_ttl, df);