#define pr_fmt(fmt) …
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/skbuff.h>
#include <linux/netdevice.h>
#include <linux/in.h>
#include <linux/if_arp.h>
#include <linux/init.h>
#include <linux/in6.h>
#include <linux/inetdevice.h>
#include <linux/netfilter_ipv4.h>
#include <linux/etherdevice.h>
#include <linux/if_ether.h>
#include <linux/if_vlan.h>
#include <linux/static_key.h>
#include <net/ip.h>
#include <net/icmp.h>
#include <net/protocol.h>
#include <net/ip_tunnels.h>
#include <net/ip6_tunnel.h>
#include <net/ip6_checksum.h>
#include <net/arp.h>
#include <net/checksum.h>
#include <net/dsfield.h>
#include <net/inet_ecn.h>
#include <net/xfrm.h>
#include <net/net_namespace.h>
#include <net/netns/generic.h>
#include <net/rtnetlink.h>
#include <net/dst_metadata.h>
#include <net/geneve.h>
#include <net/vxlan.h>
#include <net/erspan.h>
const struct ip_tunnel_encap_ops __rcu *
iptun_encaps[MAX_IPTUN_ENCAP_OPS] __read_mostly;
EXPORT_SYMBOL(…);
const struct ip6_tnl_encap_ops __rcu *
ip6tun_encaps[MAX_IPTUN_ENCAP_OPS] __read_mostly;
EXPORT_SYMBOL(…);
void iptunnel_xmit(struct sock *sk, struct rtable *rt, struct sk_buff *skb,
__be32 src, __be32 dst, __u8 proto,
__u8 tos, __u8 ttl, __be16 df, bool xnet)
{ … }
EXPORT_SYMBOL_GPL(…);
int __iptunnel_pull_header(struct sk_buff *skb, int hdr_len,
__be16 inner_proto, bool raw_proto, bool xnet)
{ … }
EXPORT_SYMBOL_GPL(…);
struct metadata_dst *iptunnel_metadata_reply(struct metadata_dst *md,
gfp_t flags)
{ … }
EXPORT_SYMBOL_GPL(…);
int iptunnel_handle_offloads(struct sk_buff *skb,
int gso_type_mask)
{ … }
EXPORT_SYMBOL_GPL(…);
static int iptunnel_pmtud_build_icmp(struct sk_buff *skb, int mtu)
{ … }
static int iptunnel_pmtud_check_icmp(struct sk_buff *skb, int mtu)
{ … }
#if IS_ENABLED(CONFIG_IPV6)
static int iptunnel_pmtud_build_icmpv6(struct sk_buff *skb, int mtu)
{ … }
static int iptunnel_pmtud_check_icmpv6(struct sk_buff *skb, int mtu)
{ … }
#endif
int skb_tunnel_check_pmtu(struct sk_buff *skb, struct dst_entry *encap_dst,
int headroom, bool reply)
{ … }
EXPORT_SYMBOL(…);
static const struct nla_policy ip_tun_policy[LWTUNNEL_IP_MAX + 1] = …;
static const struct nla_policy ip_opts_policy[LWTUNNEL_IP_OPTS_MAX + 1] = …;
static const struct nla_policy
geneve_opt_policy[LWTUNNEL_IP_OPT_GENEVE_MAX + 1] = …;
static const struct nla_policy
vxlan_opt_policy[LWTUNNEL_IP_OPT_VXLAN_MAX + 1] = …;
static const struct nla_policy
erspan_opt_policy[LWTUNNEL_IP_OPT_ERSPAN_MAX + 1] = …;
static int ip_tun_parse_opts_geneve(struct nlattr *attr,
struct ip_tunnel_info *info, int opts_len,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_parse_opts_vxlan(struct nlattr *attr,
struct ip_tunnel_info *info, int opts_len,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_parse_opts_erspan(struct nlattr *attr,
struct ip_tunnel_info *info, int opts_len,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_parse_opts(struct nlattr *attr, struct ip_tunnel_info *info,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_get_optlen(struct nlattr *attr,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_set_opts(struct nlattr *attr, struct ip_tunnel_info *info,
struct netlink_ext_ack *extack)
{ … }
static int ip_tun_build_state(struct net *net, struct nlattr *attr,
unsigned int family, const void *cfg,
struct lwtunnel_state **ts,
struct netlink_ext_ack *extack)
{ … }
static void ip_tun_destroy_state(struct lwtunnel_state *lwtstate)
{ … }
static int ip_tun_fill_encap_opts_geneve(struct sk_buff *skb,
struct ip_tunnel_info *tun_info)
{ … }
static int ip_tun_fill_encap_opts_vxlan(struct sk_buff *skb,
struct ip_tunnel_info *tun_info)
{ … }
static int ip_tun_fill_encap_opts_erspan(struct sk_buff *skb,
struct ip_tunnel_info *tun_info)
{ … }
static int ip_tun_fill_encap_opts(struct sk_buff *skb, int type,
struct ip_tunnel_info *tun_info)
{ … }
static int ip_tun_fill_encap_info(struct sk_buff *skb,
struct lwtunnel_state *lwtstate)
{ … }
static int ip_tun_opts_nlsize(struct ip_tunnel_info *info)
{ … }
static int ip_tun_encap_nlsize(struct lwtunnel_state *lwtstate)
{ … }
static int ip_tun_cmp_encap(struct lwtunnel_state *a, struct lwtunnel_state *b)
{ … }
static const struct lwtunnel_encap_ops ip_tun_lwt_ops = …;
static const struct nla_policy ip6_tun_policy[LWTUNNEL_IP6_MAX + 1] = …;
static int ip6_tun_build_state(struct net *net, struct nlattr *attr,
unsigned int family, const void *cfg,
struct lwtunnel_state **ts,
struct netlink_ext_ack *extack)
{ … }
static int ip6_tun_fill_encap_info(struct sk_buff *skb,
struct lwtunnel_state *lwtstate)
{ … }
static int ip6_tun_encap_nlsize(struct lwtunnel_state *lwtstate)
{ … }
static const struct lwtunnel_encap_ops ip6_tun_lwt_ops = …;
void __init ip_tunnel_core_init(void)
{ … }
DEFINE_STATIC_KEY_FALSE(ip_tunnel_metadata_cnt);
EXPORT_SYMBOL(…);
void ip_tunnel_need_metadata(void)
{ … }
EXPORT_SYMBOL_GPL(…);
void ip_tunnel_unneed_metadata(void)
{ … }
EXPORT_SYMBOL_GPL(…);
__be16 ip_tunnel_parse_protocol(const struct sk_buff *skb)
{ … }
EXPORT_SYMBOL(…);
const struct header_ops ip_tunnel_header_ops = …;
EXPORT_SYMBOL(…);
bool ip_tunnel_netlink_encap_parms(struct nlattr *data[],
struct ip_tunnel_encap *encap)
{ … }
EXPORT_SYMBOL_GPL(…);
void ip_tunnel_netlink_parms(struct nlattr *data[],
struct ip_tunnel_parm_kern *parms)
{ … }
EXPORT_SYMBOL_GPL(…);