FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
lisp_gpe.api
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015-2016 Cisco and/or its affiliates.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at:
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 option version = "2.0.0";
17 
18 import "vnet/interface_types.api";
19 import "plugins/lisp/lisp-cp/lisp_types.api";
20 
21 /** \brief GPE locator structure
22  @param is_ip4 - whether addr is IPv4 or v6
23  @param weight - locator weight
24  @param addr - IPv4/6 address
25 */
26 typedef gpe_locator
27 {
28  u8 weight;
29  vl_api_address_t addr;
30 };
31 
32 /** \brief add or delete GPE tunnel
33  @param client_index - opaque cookie to identify the sender
34  @param context - sender context, to match reply w/ request
35  @param is_add - add address if non-zero, else delete
36  @param rmt_eid - remote eid
37  @param lcl_eid - local eid
38  @param vni - virtual network identifier
39  @param dp_table - vrf/bridge domain id
40  @param action - negative action when 0 locators configured
41  @param loc_num - number of locators
42  @param locs - array of remote locators
43 */
44 define gpe_add_del_fwd_entry
45 {
48  bool is_add [default=true];
49  vl_api_eid_t rmt_eid;
50  vl_api_eid_t lcl_eid;
55  vl_api_gpe_locator_t locs[loc_num];
56 };
57 
58 define gpe_add_del_fwd_entry_reply
59 {
63 };
64 
65 /** \brief enable or disable gpe protocol
66  @param client_index - opaque cookie to identify the sender
67  @param context - sender context, to match reply w/ request
68  @param is_enable [default=true] - enable protocol if non-zero, else disable
69 */
70 autoreply define gpe_enable_disable
71 {
74  bool is_enable [default=true];
75 };
76 
77 /** \brief add or delete gpe_iface
78  @param client_index - opaque cookie to identify the sender
79  @param context - sender context, to match reply w/ request
80  @param is_add - add address if non-zero, else delete
81 */
82 autoreply define gpe_add_del_iface
83 {
86  bool is_add [default=true];
87  bool is_l2;
90 };
91 
92 define gpe_fwd_entry_vnis_get
93 {
96 };
97 
98 define gpe_fwd_entry_vnis_get_reply
99 {
103  u32 vnis[count];
104 };
105 
106 define gpe_fwd_entries_get
107 {
111 };
112 
113 typedef gpe_fwd_entry
114 {
115  u32 fwd_entry_index;
117  vl_api_eid_t leid;
118  vl_api_eid_t reid;
121 };
122 
123 define gpe_fwd_entries_get_reply
124 {
128  vl_api_gpe_fwd_entry_t entries[count];
129 };
130 
131 define gpe_fwd_entry_path_dump
132 {
136 };
137 
138 define gpe_fwd_entry_path_details
139 {
141  vl_api_gpe_locator_t lcl_loc;
142  vl_api_gpe_locator_t rmt_loc;
143 };
144 
145 /** \brief Set GPE encapsulation mode
146  @param client_index - opaque cookie to identify the sender
147  @param context - sender context, to match reply w/ request
148  @param mode - LISP (value 0) or VXLAN (value 1)
149 */
150 autoreply define gpe_set_encap_mode
151 {
154  bool is_vxlan;
155 };
156 
157 /** \brief get GPE encapsulation mode
158  @param client_index - opaque cookie to identify the sender
159  @param context - sender context, to match reply w/ request
160  @param mode - LISP (value 0) or VXLAN (value 1)
161 */
162 define gpe_get_encap_mode
163 {
166 };
167 
168 /** \brief Reply for set_encap_mode
169  @param context - returned sender context, to match reply w/ request
170  @param retval - return code
171  @param encap_mode - GPE encapsulation mode
172 */
173 define gpe_get_encap_mode_reply
174 {
177  /* FIXME: gpe encap enum */
179 };
180 
181 /** \brief Add native fwd rpath
182  @param context - returned sender context, to match reply w/ request
183  @param retval - return code
184  @param is_add - flag to indicate add or del
185  @param table_id - table id for route path
186  @param nh_sw_if_index - next-hop sw_if_index (~0 if not set)
187  @param is_ip4 - flag to indicate if nh is ip4
188  @param nh_addr - next hop ip address
189 */
190 autoreply define gpe_add_del_native_fwd_rpath
191 {
194  bool is_add [default=true];
196  vl_api_interface_index_t nh_sw_if_index;
197  vl_api_address_t nh_addr;
198 };
199 
200 /** \brief get GPE native fwd rpath
201  @param client_index - opaque cookie to identify the sender
202  @param context - sender context, to match reply w/ request
203 */
204 define gpe_native_fwd_rpaths_get
205 {
208  bool is_ip4;
209 };
210 
211 /** \brief Reply for get native fwd rpath
212  @param context - returned sender context, to match reply w/ request
213  @param retval - return code
214  @param table_id - table id for route path
215  @param nh_sw_if_index - next-hop sw_if_index (~0 if not set)
216  @param nh_addr - next hop address
217 */
218 typedef gpe_native_fwd_rpath
219 {
220  u32 fib_index;
221  vl_api_interface_index_t nh_sw_if_index;
222  vl_api_address_t nh_addr;
223 };
224 
225 define gpe_native_fwd_rpaths_get_reply
226 {
230  vl_api_gpe_native_fwd_rpath_t entries[count];
231 };
232 
233 /*
234  * Local Variables:
235  * eval: (c-set-style "gnu")
236  * End:
237  */
leid
vl_api_eid_t leid
Definition: lisp_gpe.api:117
vl_api_gpe_fwd_entry_vnis_get_reply_t::count
u32 count
Definition: lisp_gpe.api:102
weight
u8 weight
Definition: fib_types.api:120
vl_api_gpe_add_del_fwd_entry_reply_t::context
u32 context
Definition: lisp_gpe.api:60
vl_api_gpe_enable_disable_t
enable or disable gpe protocol
Definition: lisp_gpe.api:70
vl_api_gpe_fwd_entry_vnis_get_t::client_index
u32 client_index
Definition: lisp_gpe.api:94
vl_api_gpe_add_del_native_fwd_rpath_t::context
u32 context
Definition: lisp_gpe.api:193
vl_api_gpe_add_del_fwd_entry_reply_t::retval
i32 retval
Definition: lisp_gpe.api:61
vl_api_gpe_add_del_native_fwd_rpath_t::nh_sw_if_index
vl_api_interface_index_t nh_sw_if_index
Definition: lisp_gpe.api:196
vl_api_gpe_add_del_fwd_entry_t::action
u8 action
Definition: lisp_gpe.api:53
vl_api_gpe_fwd_entry_vnis_get_reply_t::vnis
u32 vnis[count]
Definition: lisp_gpe.api:103
vl_api_gpe_add_del_iface_t::context
u32 context
Definition: lisp_gpe.api:85
gpe_native_fwd_rpath
typedef gpe_native_fwd_rpath
Reply for get native fwd rpath.
Definition: lisp_gpe.api:219
vl_api_gpe_add_del_fwd_entry_t::client_index
u32 client_index
Definition: lisp_gpe.api:46
vl_api_gpe_enable_disable_t::context
u32 context
Definition: lisp_gpe.api:73
vl_api_gpe_get_encap_mode_reply_t::context
u32 context
Definition: lisp_gpe.api:175
vl_api_gpe_native_fwd_rpaths_get_reply_t::count
u32 count
Definition: lisp_gpe.api:229
entries
u32 entries
Definition: flowhash_template.h:362
vl_api_gpe_native_fwd_rpaths_get_reply_t::retval
i32 retval
Definition: lisp_gpe.api:228
vl_api_gpe_add_del_iface_t
add or delete gpe_iface
Definition: lisp_gpe.api:82
vl_api_gpe_set_encap_mode_t::is_vxlan
bool is_vxlan
Definition: lisp_gpe.api:154
vl_api_gpe_fwd_entry_path_details_t
Definition: lisp_gpe.api:138
vl_api_gpe_add_del_native_fwd_rpath_t
Add native fwd rpath.
Definition: lisp_gpe.api:190
vl_api_gpe_fwd_entry_path_dump_t::context
u32 context
Definition: lisp_gpe.api:134
gpe_fwd_entry
typedef gpe_fwd_entry
Definition: lisp_gpe.api:114
vl_api_gpe_get_encap_mode_reply_t::retval
i32 retval
Definition: lisp_gpe.api:176
i32
signed int i32
Definition: types.h:77
vl_api_gpe_set_encap_mode_t::context
u32 context
Definition: lisp_gpe.api:153
vl_api_gpe_fwd_entry_path_details_t::rmt_loc
vl_api_gpe_locator_t rmt_loc
Definition: lisp_gpe.api:142
count
u8 count
Definition: dhcp.api:208
vl_api_gpe_get_encap_mode_t::client_index
u32 client_index
Definition: lisp_gpe.api:164
vl_api_gpe_add_del_fwd_entry_reply_t::fwd_entry_index
u32 fwd_entry_index
Definition: lisp_gpe.api:62
vl_api_gpe_set_encap_mode_t
Set GPE encapsulation mode.
Definition: lisp_gpe.api:150
vl_api_gpe_add_del_fwd_entry_t::context
u32 context
Definition: lisp_gpe.api:47
gpe_locator
typedef gpe_locator
GPE locator structure.
Definition: lisp_gpe.api:27
vl_api_gpe_set_encap_mode_t::client_index
u32 client_index
Definition: lisp_gpe.api:152
vl_api_gpe_fwd_entry_path_details_t::lcl_loc
vl_api_gpe_locator_t lcl_loc
Definition: lisp_gpe.api:141
addr
vl_api_address_t addr
Definition: lisp_gpe.api:29
vl_api_gpe_fwd_entry_path_details_t::context
u32 context
Definition: lisp_gpe.api:140
dp_table
u32 dp_table
Definition: lisp_gpe.api:116
vl_api_gpe_fwd_entry_path_dump_t::client_index
u32 client_index
Definition: lisp_gpe.api:133
vl_api_gpe_get_encap_mode_reply_t
Reply for set_encap_mode.
Definition: lisp_gpe.api:173
vl_api_gpe_add_del_native_fwd_rpath_t::table_id
u32 table_id
Definition: lisp_gpe.api:195
vl_api_gpe_add_del_iface_t::client_index
u32 client_index
Definition: lisp_gpe.api:84
vl_api_gpe_add_del_native_fwd_rpath_t::client_index
u32 client_index
Definition: lisp_gpe.api:192
vl_api_gpe_get_encap_mode_reply_t::encap_mode
u8 encap_mode
Definition: lisp_gpe.api:178
vl_api_gpe_fwd_entry_vnis_get_reply_t::retval
i32 retval
Definition: lisp_gpe.api:101
vl_api_gpe_native_fwd_rpaths_get_reply_t
Definition: lisp_gpe.api:225
vl_api_gpe_enable_disable_t::is_enable
bool is_enable[default=true]
Definition: lisp_gpe.api:74
vl_api_gpe_native_fwd_rpaths_get_t::context
u32 context
Definition: lisp_gpe.api:207
vl_api_gpe_add_del_fwd_entry_t::is_add
bool is_add[default=true]
Definition: lisp_gpe.api:48
vl_api_gpe_fwd_entries_get_t::context
u32 context
Definition: lisp_gpe.api:109
vl_api_gpe_fwd_entry_vnis_get_t::context
u32 context
Definition: lisp_gpe.api:95
reid
vl_api_eid_t reid
Definition: lisp_gpe.api:118
vl_api_gpe_fwd_entry_vnis_get_t
Definition: lisp_gpe.api:92
vl_api_gpe_native_fwd_rpaths_get_t::is_ip4
bool is_ip4
Definition: lisp_gpe.api:208
vl_api_gpe_fwd_entries_get_reply_t::context
u32 context
Definition: lisp_gpe.api:125
vl_api_gpe_add_del_native_fwd_rpath_t::nh_addr
vl_api_address_t nh_addr
Definition: lisp_gpe.api:197
vni
u32 vni
Definition: lisp_gpe.api:119
action
u8 action
Definition: lisp_gpe.api:120
version
option version
Definition: lisp_gpe.api:16
vl_api_gpe_fwd_entries_get_t::client_index
u32 client_index
Definition: lisp_gpe.api:108
u32
unsigned int u32
Definition: types.h:88
vl_api_gpe_add_del_iface_t::is_l2
bool is_l2
Definition: lisp_gpe.api:87
vl_api_gpe_add_del_native_fwd_rpath_t::is_add
bool is_add[default=true]
Definition: lisp_gpe.api:194
nh_addr
vl_api_address_t nh_addr
Definition: lisp_gpe.api:222
vl_api_gpe_add_del_fwd_entry_t::lcl_eid
vl_api_eid_t lcl_eid
Definition: lisp_gpe.api:50
vl_api_gpe_fwd_entries_get_t::vni
u32 vni
Definition: lisp_gpe.api:110
vl_api_gpe_add_del_fwd_entry_t::locs
vl_api_gpe_locator_t locs[loc_num]
Definition: lisp_gpe.api:55
vl_api_gpe_fwd_entries_get_t
Definition: lisp_gpe.api:106
vl_api_gpe_native_fwd_rpaths_get_t
get GPE native fwd rpath
Definition: lisp_gpe.api:204
vl_api_gpe_add_del_fwd_entry_t::rmt_eid
vl_api_eid_t rmt_eid
Definition: lisp_gpe.api:49
vl_api_gpe_add_del_fwd_entry_t
add or delete GPE tunnel
Definition: lisp_gpe.api:44
vl_api_gpe_add_del_fwd_entry_t::vni
u32 vni
Definition: lisp_gpe.api:51
vl_api_gpe_add_del_fwd_entry_reply_t
Definition: lisp_gpe.api:58
vl_api_gpe_fwd_entries_get_reply_t
Definition: lisp_gpe.api:123
nh_sw_if_index
vl_api_interface_index_t nh_sw_if_index
Definition: lisp_gpe.api:221
u8
unsigned char u8
Definition: types.h:56
vl_api_gpe_fwd_entries_get_reply_t::entries
vl_api_gpe_fwd_entry_t entries[count]
Definition: lisp_gpe.api:128
vl_api_gpe_native_fwd_rpaths_get_t::client_index
u32 client_index
Definition: lisp_gpe.api:206
vl_api_gpe_native_fwd_rpaths_get_reply_t::context
u32 context
Definition: lisp_gpe.api:227
vl_api_gpe_fwd_entries_get_reply_t::count
u32 count
Definition: lisp_gpe.api:127
vl_api_gpe_get_encap_mode_t::context
u32 context
Definition: lisp_gpe.api:165
vl_api_gpe_add_del_iface_t::dp_table
u32 dp_table
Definition: lisp_gpe.api:88
vl_api_gpe_enable_disable_t::client_index
u32 client_index
Definition: lisp_gpe.api:72
vl_api_gpe_add_del_iface_t::is_add
bool is_add[default=true]
Definition: lisp_gpe.api:86
vl_api_gpe_fwd_entry_vnis_get_reply_t
Definition: lisp_gpe.api:98
vl_api_gpe_get_encap_mode_t
get GPE encapsulation mode
Definition: lisp_gpe.api:162
vl_api_gpe_native_fwd_rpaths_get_reply_t::entries
vl_api_gpe_native_fwd_rpath_t entries[count]
Definition: lisp_gpe.api:230
vl_api_gpe_add_del_fwd_entry_t::loc_num
u32 loc_num
Definition: lisp_gpe.api:54
vl_api_gpe_fwd_entry_path_dump_t
Definition: lisp_gpe.api:131
vl_api_gpe_fwd_entry_path_dump_t::fwd_entry_index
u32 fwd_entry_index
Definition: lisp_gpe.api:135
vl_api_gpe_fwd_entry_vnis_get_reply_t::context
u32 context
Definition: lisp_gpe.api:100
vl_api_gpe_add_del_fwd_entry_t::dp_table
u32 dp_table
Definition: lisp_gpe.api:52
vl_api_gpe_fwd_entries_get_reply_t::retval
i32 retval
Definition: lisp_gpe.api:126
vl_api_gpe_add_del_iface_t::vni
u32 vni
Definition: lisp_gpe.api:89