blob: fc73e667b50e4e79d506fa536b9635ac39e787c9 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#ifndef _NET_IP6_TUNNEL_H
2#define _NET_IP6_TUNNEL_H
3
4#include <linux/ipv6.h>
5#include <linux/netdevice.h>
6#include <linux/ip6_tunnel.h>
7
8/* capable of sending packets */
9#define IP6_TNL_F_CAP_XMIT 0x10000
10/* capable of receiving packets */
11#define IP6_TNL_F_CAP_RCV 0x20000
12
Linus Torvalds1da177e2005-04-16 15:20:36 -070013/* IPv6 tunnel */
14
15struct ip6_tnl {
Eric Dumazet6f0bcf12010-10-24 21:33:16 +000016 struct ip6_tnl __rcu *next; /* next tunnel in list */
Linus Torvalds1da177e2005-04-16 15:20:36 -070017 struct net_device *dev; /* virtual device associated with tunnel */
Joe Perchesf4ab2f722007-12-20 13:56:32 -080018 struct ip6_tnl_parm parms; /* tunnel configuration parameters */
Linus Torvalds1da177e2005-04-16 15:20:36 -070019 struct flowi fl; /* flowi template for xmit */
20 struct dst_entry *dst_cache; /* cached dst */
21 u32 dst_cookie;
22};
23
24/* Tunnel encapsulation limit destination sub-option */
25
26struct ipv6_tlv_tnl_enc_lim {
27 __u8 type; /* type-code for option */
28 __u8 length; /* option length */
29 __u8 encap_limit; /* tunnel encapsulation limit */
Eric Dumazetbc105022010-06-03 03:21:52 -070030} __packed;
Linus Torvalds1da177e2005-04-16 15:20:36 -070031
32#endif