]>
Commit | Line | Data |
---|---|---|
f4c89855 LB |
1 | /* |
2 | * Copyright 2015, LabN Consulting, L.L.C. | |
3 | * | |
4 | * This program is free software; you can redistribute it and/or | |
5 | * modify it under the terms of the GNU General Public License | |
6 | * as published by the Free Software Foundation; either version 2 | |
7 | * of the License, or (at your option) any later version. | |
8 | * | |
9 | * This program is distributed in the hope that it will be useful, | |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | * GNU General Public License for more details. | |
13 | * | |
896014f4 DL |
14 | * You should have received a copy of the GNU General Public License along |
15 | * with this program; see the file COPYING; if not, write to the Free Software | |
16 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | |
f4c89855 LB |
17 | */ |
18 | ||
19 | #ifndef _QUAGGA_BGP_ENCAP_TLV_H | |
20 | #define _QUAGGA_BGP_ENCAP_TLV_H | |
21 | ||
f4c89855 LB |
22 | /*********************************************************************** |
23 | * TUNNEL TYPE-SPECIFIC TLV ENCODE | |
24 | ***********************************************************************/ | |
25 | ||
26 | extern void | |
d62a17ae | 27 | bgp_encap_type_l2tpv3overip_to_tlv(struct bgp_encap_type_l2tpv3_over_ip *bet, |
28 | struct attr *attr); | |
f4c89855 | 29 | |
d62a17ae | 30 | extern void bgp_encap_type_gre_to_tlv(struct bgp_encap_type_gre *bet, |
31 | struct attr *attr); | |
f4c89855 | 32 | |
d62a17ae | 33 | extern void bgp_encap_type_ip_in_ip_to_tlv(struct bgp_encap_type_ip_in_ip *bet, |
34 | struct attr *attr); | |
f4c89855 | 35 | |
d62a17ae | 36 | extern void bgp_encap_type_transmit_tunnel_endpoint( |
37 | struct bgp_encap_type_transmit_tunnel_endpoint *bet, struct attr *attr); | |
f4c89855 | 38 | |
d62a17ae | 39 | extern void bgp_encap_type_ipsec_in_tunnel_mode_to_tlv( |
40 | struct bgp_encap_type_ipsec_in_tunnel_mode *bet, struct attr *attr); | |
f4c89855 | 41 | |
d62a17ae | 42 | extern void bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode_to_tlv( |
43 | struct bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode *bet, | |
44 | struct attr *attr); | |
f4c89855 | 45 | |
d62a17ae | 46 | extern void bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode_to_tlv( |
47 | struct bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode *bet, | |
48 | struct attr *attr); | |
f4c89855 | 49 | |
d62a17ae | 50 | extern void bgp_encap_type_pbb_to_tlv(struct bgp_encap_type_pbb *bet, |
51 | struct attr *attr); | |
f4c89855 | 52 | |
d62a17ae | 53 | extern void bgp_encap_type_vxlan_to_tlv(struct bgp_encap_type_vxlan *bet, |
54 | struct attr *attr); | |
f4c89855 | 55 | |
d62a17ae | 56 | extern void bgp_encap_type_nvgre_to_tlv(struct bgp_encap_type_nvgre *bet, |
57 | struct attr *attr); | |
f4c89855 | 58 | |
d62a17ae | 59 | extern void bgp_encap_type_mpls_to_tlv(struct bgp_encap_type_mpls *bet, |
60 | struct attr *attr); | |
f4c89855 LB |
61 | |
62 | extern void | |
d62a17ae | 63 | bgp_encap_type_mpls_in_gre_to_tlv(struct bgp_encap_type_mpls_in_gre *bet, |
64 | struct attr *attr); | |
f4c89855 LB |
65 | |
66 | extern void | |
d62a17ae | 67 | bgp_encap_type_vxlan_gpe_to_tlv(struct bgp_encap_type_vxlan_gpe *bet, |
68 | struct attr *attr); | |
f4c89855 LB |
69 | |
70 | extern void | |
d62a17ae | 71 | bgp_encap_type_mpls_in_udp_to_tlv(struct bgp_encap_type_mpls_in_udp *bet, |
72 | struct attr *attr); | |
f4c89855 LB |
73 | |
74 | /*********************************************************************** | |
75 | * TUNNEL TYPE-SPECIFIC TLV DECODE | |
76 | ***********************************************************************/ | |
77 | ||
d62a17ae | 78 | extern int tlv_to_bgp_encap_type_l2tpv3overip( |
79 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
80 | struct bgp_encap_type_l2tpv3_over_ip *bet); /* caller-allocated */ | |
f4c89855 | 81 | |
d62a17ae | 82 | extern int tlv_to_bgp_encap_type_gre( |
83 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
84 | struct bgp_encap_type_gre *bet); /* caller-allocated */ | |
f4c89855 | 85 | |
d62a17ae | 86 | extern int tlv_to_bgp_encap_type_ip_in_ip( |
87 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
88 | struct bgp_encap_type_ip_in_ip *bet); /* caller-allocated */ | |
f4c89855 | 89 | |
d62a17ae | 90 | extern int tlv_to_bgp_encap_type_transmit_tunnel_endpoint( |
91 | struct bgp_attr_encap_subtlv *stlv, | |
92 | struct bgp_encap_type_transmit_tunnel_endpoint *bet); | |
f4c89855 | 93 | |
d62a17ae | 94 | extern int tlv_to_bgp_encap_type_ipsec_in_tunnel_mode( |
95 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
96 | struct bgp_encap_type_ipsec_in_tunnel_mode *bet); /* caller-allocated */ | |
f4c89855 | 97 | |
d62a17ae | 98 | extern int tlv_to_bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode( |
99 | struct bgp_attr_encap_subtlv *stlv, | |
100 | struct bgp_encap_type_ip_in_ip_tunnel_with_ipsec_transport_mode *bet); | |
f4c89855 | 101 | |
d62a17ae | 102 | extern int tlv_to_bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode( |
103 | struct bgp_attr_encap_subtlv *stlv, | |
104 | struct bgp_encap_type_mpls_in_ip_tunnel_with_ipsec_transport_mode *bet); | |
f4c89855 | 105 | |
d62a17ae | 106 | extern int tlv_to_bgp_encap_type_vxlan(struct bgp_attr_encap_subtlv *stlv, |
107 | struct bgp_encap_type_vxlan *bet); | |
f4c89855 | 108 | |
d62a17ae | 109 | extern int tlv_to_bgp_encap_type_nvgre(struct bgp_attr_encap_subtlv *stlv, |
110 | struct bgp_encap_type_nvgre *bet); | |
f4c89855 | 111 | |
d62a17ae | 112 | extern int tlv_to_bgp_encap_type_mpls(struct bgp_attr_encap_subtlv *stlv, |
113 | struct bgp_encap_type_mpls *bet); | |
f4c89855 | 114 | |
d62a17ae | 115 | extern int tlv_to_bgp_encap_type_mpls(struct bgp_attr_encap_subtlv *stlv, |
116 | struct bgp_encap_type_mpls *bet); | |
f4c89855 LB |
117 | |
118 | extern int | |
d62a17ae | 119 | tlv_to_bgp_encap_type_mpls_in_gre(struct bgp_attr_encap_subtlv *stlv, |
120 | struct bgp_encap_type_mpls_in_gre *bet); | |
f4c89855 LB |
121 | |
122 | extern int | |
d62a17ae | 123 | tlv_to_bgp_encap_type_vxlan_gpe(struct bgp_attr_encap_subtlv *stlv, |
124 | struct bgp_encap_type_vxlan_gpe *bet); | |
f4c89855 LB |
125 | |
126 | extern int | |
d62a17ae | 127 | tlv_to_bgp_encap_type_mpls_in_udp(struct bgp_attr_encap_subtlv *stlv, |
128 | struct bgp_encap_type_mpls_in_udp *bet); | |
f4c89855 | 129 | |
d62a17ae | 130 | extern int tlv_to_bgp_encap_type_pbb( |
131 | struct bgp_attr_encap_subtlv *stlv, /* subtlv chain */ | |
132 | struct bgp_encap_type_pbb *bet); /* caller-allocated */ | |
f4c89855 LB |
133 | |
134 | #endif /* _QUAGGA_BGP_ENCAP_TLV_H */ |