- }
- skb = nskb;
-
- /* Reset SKB */
- nf_reset(skb);
- secpath_reset(skb);
- skb_dst_drop(skb);
- skb_clear_rxhash(skb);
-
- while (skb) {
- struct sk_buff *next_skb = skb->next;
- struct iphdr *iph;
- int frag_len;
-
- skb->next = NULL;
-
- if (vlan_tx_tag_present(skb)) {
- if (unlikely(!__vlan_put_tag(skb,
- skb->vlan_proto,
- vlan_tx_tag_get(skb))))
- goto next;
-
- vlan_set_tci(skb, 0);
- }
-
- frag_len = skb->len;
- skb_push(skb, tunnel_hlen);
- skb_reset_network_header(skb);
- skb_set_transport_header(skb, sizeof(struct iphdr));
-
- if (next_skb)
- skb_dst_set(skb, dst_clone(&rt_dst(rt)));
- else
- skb_dst_set(skb, &rt_dst(rt));
-
- /* Push Tunnel header. */
- build_header(vport, skb, tunnel_hlen);
-
- /* Push IP header. */
- iph = ip_hdr(skb);
- iph->version = 4;
- iph->ihl = sizeof(struct iphdr) >> 2;
- iph->protocol = ipproto;
- iph->daddr = OVS_CB(skb)->tun_key->ipv4_dst;
- iph->saddr = saddr;
- iph->tos = OVS_CB(skb)->tun_key->ipv4_tos;
- iph->ttl = OVS_CB(skb)->tun_key->ipv4_ttl;
- iph->frag_off = OVS_CB(skb)->tun_key->tun_flags &