]>
Commit | Line | Data |
---|---|---|
acddc0ed | 1 | // SPDX-License-Identifier: GPL-2.0-or-later |
f4c89855 LB |
2 | /* |
3 | * Copyright 2015, LabN Consulting, L.L.C. | |
f4c89855 LB |
4 | */ |
5 | ||
6 | #ifndef _QUAGGA_BGP_ENCAP_TLV_H | |
7 | #define _QUAGGA_BGP_ENCAP_TLV_H | |
8 | ||
f4c89855 LB |
9 | /*********************************************************************** |
10 | * TUNNEL TYPE-SPECIFIC TLV ENCODE | |
11 | ***********************************************************************/ | |
12 | ||
13 | extern void | |
d62a17ae | 14 | bgp_encap_type_l2tpv3overip_to_tlv(struct bgp_encap_type_l2tpv3_over_ip *bet, |
15 | struct attr *attr); | |
f4c89855 | 16 | |
d62a17ae | 17 | extern void bgp_encap_type_gre_to_tlv(struct bgp_encap_type_gre *bet, |
18 | struct attr *attr); | |
f4c89855 | 19 | |
d62a17ae | 20 | extern void bgp_encap_type_ip_in_ip_to_tlv(struct bgp_encap_type_ip_in_ip *bet, |
21 | struct attr *attr); | |
f4c89855 | 22 | |
d62a17ae | 23 | extern void bgp_encap_type_transmit_tunnel_endpoint( |
24 | struct bgp_encap_type_transmit_tunnel_endpoint *bet, struct attr *attr); | |
f4c89855 | 25 | |
d62a17ae | 26 | extern void bgp_encap_type_ipsec_in_tunnel_mode_to_tlv( |
27 | struct bgp_encap_type_ipsec_in_tunnel_mode *bet, struct attr *attr); | |
f4c89855 | 28 | |
d62a17ae | 29 | extern void bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode_to_tlv( |
30 | struct bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode *bet, | |
31 | struct attr *attr); | |
f4c89855 | 32 | |
d62a17ae | 33 | extern void bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode_to_tlv( |
34 | struct bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode *bet, | |
35 | struct attr *attr); | |
f4c89855 | 36 | |
d62a17ae | 37 | extern void bgp_encap_type_pbb_to_tlv(struct bgp_encap_type_pbb *bet, |
38 | struct attr *attr); | |
f4c89855 | 39 | |
d62a17ae | 40 | extern void bgp_encap_type_vxlan_to_tlv(struct bgp_encap_type_vxlan *bet, |
41 | struct attr *attr); | |
f4c89855 | 42 | |
d62a17ae | 43 | extern void bgp_encap_type_nvgre_to_tlv(struct bgp_encap_type_nvgre *bet, |
44 | struct attr *attr); | |
f4c89855 | 45 | |
d62a17ae | 46 | extern void bgp_encap_type_mpls_to_tlv(struct bgp_encap_type_mpls *bet, |
47 | struct attr *attr); | |
f4c89855 LB |
48 | |
49 | extern void | |
d62a17ae | 50 | bgp_encap_type_mpls_in_gre_to_tlv(struct bgp_encap_type_mpls_in_gre *bet, |
51 | struct attr *attr); | |
f4c89855 LB |
52 | |
53 | extern void | |
d62a17ae | 54 | bgp_encap_type_vxlan_gpe_to_tlv(struct bgp_encap_type_vxlan_gpe *bet, |
55 | struct attr *attr); | |
f4c89855 LB |
56 | |
57 | extern void | |
d62a17ae | 58 | bgp_encap_type_mpls_in_udp_to_tlv(struct bgp_encap_type_mpls_in_udp *bet, |
59 | struct attr *attr); | |
f4c89855 LB |
60 | |
61 | /*********************************************************************** | |
62 | * TUNNEL TYPE-SPECIFIC TLV DECODE | |
63 | ***********************************************************************/ | |
64 | ||
d62a17ae | 65 | extern int tlv_to_bgp_encap_type_l2tpv3overip( |
66 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
67 | struct bgp_encap_type_l2tpv3_over_ip *bet); /* caller-allocated */ | |
f4c89855 | 68 | |
d62a17ae | 69 | extern int tlv_to_bgp_encap_type_gre( |
70 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
71 | struct bgp_encap_type_gre *bet); /* caller-allocated */ | |
f4c89855 | 72 | |
d62a17ae | 73 | extern int tlv_to_bgp_encap_type_ip_in_ip( |
74 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
75 | struct bgp_encap_type_ip_in_ip *bet); /* caller-allocated */ | |
f4c89855 | 76 | |
d62a17ae | 77 | extern int tlv_to_bgp_encap_type_transmit_tunnel_endpoint( |
78 | struct bgp_attr_encap_subtlv *stlv, | |
79 | struct bgp_encap_type_transmit_tunnel_endpoint *bet); | |
f4c89855 | 80 | |
d62a17ae | 81 | extern int tlv_to_bgp_encap_type_ipsec_in_tunnel_mode( |
82 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
83 | struct bgp_encap_type_ipsec_in_tunnel_mode *bet); /* caller-allocated */ | |
f4c89855 | 84 | |
d62a17ae | 85 | extern int tlv_to_bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode( |
86 | struct bgp_attr_encap_subtlv *stlv, | |
87 | struct bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode *bet); | |
f4c89855 | 88 | |
d62a17ae | 89 | extern int tlv_to_bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode( |
90 | struct bgp_attr_encap_subtlv *stlv, | |
91 | struct bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode *bet); | |
f4c89855 | 92 | |
d62a17ae | 93 | extern int tlv_to_bgp_encap_type_vxlan(struct bgp_attr_encap_subtlv *stlv, |
94 | struct bgp_encap_type_vxlan *bet); | |
f4c89855 | 95 | |
d62a17ae | 96 | extern int tlv_to_bgp_encap_type_nvgre(struct bgp_attr_encap_subtlv *stlv, |
97 | struct bgp_encap_type_nvgre *bet); | |
f4c89855 | 98 | |
d62a17ae | 99 | extern int tlv_to_bgp_encap_type_mpls(struct bgp_attr_encap_subtlv *stlv, |
100 | struct bgp_encap_type_mpls *bet); | |
f4c89855 | 101 | |
d62a17ae | 102 | extern int tlv_to_bgp_encap_type_mpls(struct bgp_attr_encap_subtlv *stlv, |
103 | struct bgp_encap_type_mpls *bet); | |
f4c89855 LB |
104 | |
105 | extern int | |
d62a17ae | 106 | tlv_to_bgp_encap_type_mpls_in_gre(struct bgp_attr_encap_subtlv *stlv, |
107 | struct bgp_encap_type_mpls_in_gre *bet); | |
f4c89855 LB |
108 | |
109 | extern int | |
d62a17ae | 110 | tlv_to_bgp_encap_type_vxlan_gpe(struct bgp_attr_encap_subtlv *stlv, |
111 | struct bgp_encap_type_vxlan_gpe *bet); | |
f4c89855 LB |
112 | |
113 | extern int | |
d62a17ae | 114 | tlv_to_bgp_encap_type_mpls_in_udp(struct bgp_attr_encap_subtlv *stlv, |
115 | struct bgp_encap_type_mpls_in_udp *bet); | |
f4c89855 | 116 | |
d62a17ae | 117 | extern int tlv_to_bgp_encap_type_pbb( |
118 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
119 | struct bgp_encap_type_pbb *bet); /* caller-allocated */ | |
f4c89855 LB |
120 | |
121 | #endif /* _QUAGGA_BGP_ENCAP_TLV_H */ |