blob: e4edfa1768a0faf4dff9a8a05d973ac75a4a9f08 [file] [log] [blame]
Neale Rannsd792d9c2017-10-21 10:53:20 -07001/*
2 * Copyright (c) 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/** \file
17
18 This file defines vpp BIER control-plane API messages which are generally
19 called through a shared memory interface.
20*/
21vl_api_version 1.0.0
22
23/** \brief BIER Table Indentifier
24 @param bt_set
25 @param bt_sub_domain
26 @param bt_bit_header_length
27*/
28typeonly define bier_table_id
29{
30 u8 bt_set;
31 u8 bt_sub_domain;
32 u8 bt_hdr_len_id;
33};
34
35/** \brief BIER Table Add / del route
36 @param client_index - opaque cookie to identify the sender
37 @param context - sender context, to match reply w/ request
38 @param bt_tbl_id - The BIER table-id the route is added in
Neale Ranns91286372017-12-05 13:24:04 -080039 @param bt_label - The MPLS label for the table (0 or all ones means not set)
40 If the label is not set, then it is assumed that non-MPLS
41 encoding is used.
Neale Rannsd792d9c2017-10-21 10:53:20 -070042 @param bt_is_add - Is this a route add or delete
43*/
44autoreply define bier_table_add_del
45{
46 u32 client_index;
47 u32 context;
48 vl_api_bier_table_id_t bt_tbl_id;
49 u32 bt_label;
50 u8 bt_is_add;
51};
52
53define bier_table_dump
54{
55 u32 client_index;
56 u32 context;
57};
58
59define bier_table_details
60{
61 u32 context;
62 u32 bt_label;
63 vl_api_bier_table_id_t bt_tbl_id;
64};
65
66/** \brief FIB path
67 @param sw_if_index - index of the interface
68 @param weight - The weight, for UCMP
69 @param preference - The preference of the path. lowest preference is prefered
70 @param is_local - local if non-zero, else remote
71 @param is_drop - Drop the packet
Neale Ranns91286372017-12-05 13:24:04 -080072 @param is_udp_encap - The path describes a UDP-o-IP encapsulation.
Neale Rannsd792d9c2017-10-21 10:53:20 -070073 @param afi - the afi of the next hop, IP46_TYPE_IP4=1, IP46_TYPE_IP6=2
74 @param next_hop[16] - the next hop address
Neale Ranns91286372017-12-05 13:24:04 -080075 @param next_hop_id - Used when the path resolves via an object that has a unique
76 identifier. e.g. the UDP encap object
Neale Rannsd792d9c2017-10-21 10:53:20 -070077
78 WARNING: this type is replicated, pending cleanup completion
79*/
80typeonly define fib_path3
81{
82 u32 sw_if_index;
83 u32 table_id;
84 u8 weight;
85 u8 preference;
86 u8 is_local;
87 u8 is_drop;
Neale Ranns91286372017-12-05 13:24:04 -080088 u8 is_udp_encap;
Neale Rannsd792d9c2017-10-21 10:53:20 -070089 u8 afi;
90 u8 next_hop[16];
Neale Ranns91286372017-12-05 13:24:04 -080091 u32 next_hop_id;
Neale Rannsd792d9c2017-10-21 10:53:20 -070092 u32 rpf_id;
93 u8 n_labels;
94 u32 label_stack[16];
95};
96
97/** \brief BIER Route Add / del route
98 @param client_index - opaque cookie to identify the sender
99 @param context - sender context, to match reply w/ request
100 @param br_bp - The Bit-position value
101 @param br_tbl_id - The BIER table-id the route is added in
102 @param br_is_add - Is this a route add or delete
103 @param br_is_replace - Are the paths specfied replacing those already
104 present or are they to be combined.
105 @param br_n_paths - The number of paths
106 @param br_paths - The array of paths
107*/
108autoreply define bier_route_add_del
109{
110 u32 client_index;
111 u32 context;
112 u16 br_bp;
113 u8 br_is_add;
114 u8 br_is_replace;
115 vl_api_bier_table_id_t br_tbl_id;
116 u8 br_n_paths;
117 vl_api_fib_path3_t br_paths[br_n_paths];
118};
119
120define bier_route_dump
121{
122 u32 client_index;
123 u32 context;
124 vl_api_bier_table_id_t br_tbl_id;
125};
126
127define bier_route_details
128{
129 u32 client_index;
130 u32 context;
131 u16 br_bp;
132 vl_api_bier_table_id_t br_tbl_id;
133 u32 br_n_paths;
134 vl_api_fib_path3_t br_paths[br_n_paths];
135};
136
137/** \brief BIER Imposition Add
138 @param client_index - opaque cookie to identify the sender
139 @param context - sender context, to match reply w/ request
140 @param bi_tbl_id - The BIER table-id used to forward post encap
141 @param bi_src - The source Bit-position in the encap.
142 @param bi_is_add - Is this a route add or delete
143 @param bi_n_bytes - The number of bytes in the following bit-string
144 @param bi_bytes - The bit-string represented as a byte array
145*/
146define bier_imp_add
147{
148 u32 client_index;
149 u32 context;
150 vl_api_bier_table_id_t bi_tbl_id;
151 u16 bi_src;
152 u8 bi_is_add;
153 u8 bi_n_bytes;
154 u8 bi_bytes[bi_n_bytes];
155};
156
157/** \brief Reply for BIER route add / del request
158 @param context - returned sender context, to match reply w/ request
159 @param retval - return code
160 @param bi_index - The index of the created imposition object.
161*/
162define bier_imp_add_reply
163{
164 u32 context;
165 i32 retval;
166 u32 bi_index;
167};
168
169/** \brief BIER Imposition Del
170 @param client_index - opaque cookie to identify the sender
171 @param context - sender context, to match reply w/ request
172 @param bi_index - The index of the imposition object (as returned
173 from the ADD)
174*/
175autoreply define bier_imp_del
176{
177 u32 client_index;
178 u32 context;
179 u32 bi_index;
180};
181
182define bier_imp_dump
183{
184 u32 client_index;
185 u32 context;
186};
187
188define bier_imp_details
189{
190 u32 client_index;
191 u32 context;
192 vl_api_bier_table_id_t bi_tbl_id;
193 u16 bi_src;
194 u8 bi_n_bytes;
195 u8 bi_bytes[bi_n_bytes];
196};
197
198/** \brief BIER Disposition Table Add / del route
199 @param client_index - opaque cookie to identify the sender
200 @param context - sender context, to match reply w/ request
201 @param bt_tbl_id - The BIER Disposition table-id.
202*/
203autoreply define bier_disp_table_add_del
204{
205 u32 client_index;
206 u32 context;
207 u32 bdt_tbl_id;
208 u8 bdt_is_add;
209};
210
211define bier_disp_table_dump
212{
213 u32 client_index;
214 u32 context;
215};
216
217define bier_disp_table_details
218{
219 u32 context;
220 u32 bdt_tbl_id;
221};
222
223/** \brief BIER Disposition Entry Add / del
224 @param client_index - opaque cookie to identify the sender
225 @param context - sender context, to match reply w/ request
226 @param bde_bp - The Bit-position value for the entry
227 @param bde_tbl_id - The BIER dispositiontable-id the route is added in
228 @param bde_next_hop_sw_if_index - the nextop interface
229 @param bde_is_add - Is this a route add or delete
230 @param bde_payload_proto - The payload protocol for which the next-hop
231 is added
232 @param bde_next_hop_table_id - The table ID for the next-hop
233 @param bde_next_hop_proto_is_ip4 - The next-hop is IPV4
234 @param bde_next_hop[16] - the nextop address.
235 Set this to all 0s for dispostion.
236*/
237autoreply define bier_disp_entry_add_del
238{
239 u32 client_index;
240 u32 context;
241 u16 bde_bp;
242 u32 bde_tbl_id;
243 u8 bde_is_add;
244 u8 bde_payload_proto;
245 u8 bde_n_paths;
246 vl_api_fib_path3_t bde_paths[bde_n_paths];
247};
248
249define bier_disp_entry_dump
250{
251 u32 client_index;
252 u32 context;
253 u32 bde_tbl_id;
254};
255
256define bier_disp_entry_details
257{
258 u32 context;
259 u16 bde_bp;
260 u32 bde_tbl_id;
261 u8 bde_is_add;
262 u8 bde_payload_proto;
263 u8 bde_n_paths;
264 vl_api_fib_path3_t bde_paths[bde_n_paths];
265};
266
267/*
268 * Local Variables:
269 * eval: (c-set-style "gnu")
270 * End:
271 */