4 #include <linux/if_tunnel.h>
7 /* Keep error state on tunnel for 30 sec */
8 #define IPTUNNEL_ERR_TIMEO (30*HZ)
10 /* 6rd prefix/relay information */
11 struct ip_tunnel_6rd_parm
13 struct in6_addr prefix
;
21 struct ip_tunnel
*next
;
22 struct net_device
*dev
;
24 int err_count
; /* Number of arrived ICMP errors */
25 unsigned long err_time
; /* Time when the last ICMP error arrived */
27 /* These four fields used only by GRE */
28 __u32 i_seqno
; /* The last seen seqno */
29 __u32 o_seqno
; /* The last output seqno */
30 int hlen
; /* Precalculated GRE header length */
33 struct ip_tunnel_parm parms
;
36 #ifdef CONFIG_IPV6_SIT_6RD
37 struct ip_tunnel_6rd_parm ip6rd
;
39 struct ip_tunnel_prl_entry
*prl
; /* potential router list */
40 unsigned int prl_count
; /* # of entries in PRL */
43 struct ip_tunnel_prl_entry
45 struct ip_tunnel_prl_entry
*next
;
50 #define IPTUNNEL_XMIT() do { \
52 int pkt_len = skb->len - skb_transport_offset(skb); \
54 skb->ip_summed = CHECKSUM_NONE; \
55 ip_select_ident(iph, &rt->u.dst, NULL); \
57 err = ip_local_out(skb); \
58 if (likely(net_xmit_eval(err) == 0)) { \
59 txq->tx_bytes += pkt_len; \
63 stats->tx_aborted_errors++; \