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:
7 * http://www.apache.org/licenses/LICENSE-2.0
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.
18 This file defines vpp IP control-plane API messages which are generally
19 called through a shared memory interface.
24 /** \brief Add / del table request
25 A table can be added multiple times, but need be deleted only once.
26 @param client_index - opaque cookie to identify the sender
27 @param context - sender context, to match reply w/ request
28 @param is_ipv6 - V4 or V6 table
29 @param table_id - table ID associated with the route
30 This table ID will apply to both the unicats
32 @param name - A client provided name/tag for the table. If this is
33 not set by the client, then VPP will generate something
36 autoreply define ip_table_add_del
46 /** \brief Dump IP fib table
47 @param client_index - opaque cookie to identify the sender
56 @param sw_if_index - index of the interface
57 @param weight - The weight, for UCMP
58 @param preference - The preference of the path. lowest preference is prefered
59 @param is_local - local if non-zero, else remote
60 @param is_drop - Drop the packet
61 @param is_unreach - Drop the packet and rate limit send ICMP unreachable
62 @param is_prohibit - Drop the packet and rate limit send ICMP prohibited
63 @param afi - the afi of the next hop, IP46_TYPE_IP4=1, IP46_TYPE_IP6=2
64 @param next_hop[16] - the next hop address
66 WARNING: this type is replicated, pending cleanup completion
68 typeonly manual_print manual_endian define fib_path
82 /** \brief IP FIB table response
83 @param table_id - IP fib table id
84 @address_length - mask length
86 @param count - the number of fib_path in path
87 @param path - array of of fib_path structures
89 manual_endian manual_print define ip_fib_details
97 vl_api_fib_path_t path[count];
100 /** \brief Dump IP6 fib table
101 @param client_index - opaque cookie to identify the sender
109 /** \brief IP6 FIB table entry response
110 @param table_id - IP6 fib table id
111 @param address_length - mask length
112 @param address - ip6 prefix
113 @param count - the number of fib_path in path
114 @param path - array of of fib_path structures
116 manual_endian manual_print define ip6_fib_details
124 vl_api_fib_path_t path[count];
127 /** \brief Dump IP neighboors
128 @param client_index - opaque cookie to identify the sender
129 @param context - sender context, to match reply w/ request
130 @param sw_if_index - the interface to dump neighboors
131 @param is_ipv6 - [1|0] to indicate if address family is ipv[6|4]
133 define ip_neighbor_dump
141 /** \brief IP neighboors dump response
142 @param context - sender context which was passed in the request
143 @param is_static - [1|0] to indicate if neighbor is statically configured
144 @param is_ipv6 - [1|0] to indicate if address family is ipv[6|4]
146 define ip_neighbor_details {
154 /** \brief IP neighbor add / del request
155 @param client_index - opaque cookie to identify the sender
156 @param context - sender context, to match reply w/ request
157 @param sw_if_index - interface used to reach neighbor
158 @param is_add - 1 to add neighbor, 0 to delete
159 @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
160 @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
161 @param is_static - A static neighbor Entry - there are not flushed
162 If the interface goes down.
163 @param is_no_adj_fib - Do not create a corresponding entry in the FIB
164 table for the neighbor.
165 @param mac_address - l2 address of the neighbor
166 @param dst_address - ip4 or ip6 address of the neighbor
168 autoreply define ip_neighbor_add_del
173 /* 1 = add, 0 = delete */
182 /** \brief Set the ip flow hash config for a fib request
183 @param client_index - opaque cookie to identify the sender
184 @param context - sender context, to match reply w/ request
185 @param vrf_id - vrf/fib id
186 @param is_ipv6 - if non-zero the fib is ip6, else ip4
187 @param src - if non-zero include src in flow hash
188 @param dst - if non-zero include dst in flow hash
189 @param sport - if non-zero include sport in flow hash
190 @param dport - if non-zero include dport in flow hash
191 @param proto -if non-zero include proto in flow hash
192 @param reverse - if non-zero include reverse in flow hash
194 autoreply define set_ip_flow_hash
208 /** \brief IPv6 router advertisement config request
209 @param client_index - opaque cookie to identify the sender
210 @param context - sender context, to match reply w/ request
215 @param send_unicast -
218 @param default_router -
219 @param max_interval -
220 @param min_interval -
222 @param initial_count -
223 @param initial_interval -
225 autoreply define sw_interface_ip6nd_ra_config
242 u32 initial_interval;
245 /** \brief IPv6 router advertisement prefix config request
246 @param client_index - opaque cookie to identify the sender
247 @param context - sender context, to match reply w/ request
248 @param sw_if_index - The interface the RA prefix information is for
249 @param address[] - The prefix to advertise
250 @param address_length - the prefix length
251 @param use_default - Revert to default settings
252 @param no_advertise - Do not advertise this prefix
253 @param off_link - The prefix is off link (it is not configured on the interface)
254 Configures the L-flag, When set, indicates that this
255 prefix can be used for on-link determination.
256 @param no_autoconfig - Setting for the A-flag. When
257 set indicates that this prefix can be used for
258 stateless address configuration.
259 @param no_onlink - The prefix is not on link. Make sure this is consistent
260 with the off_link parameter else YMMV
261 @param is_no - add/delete
262 @param val_lifetime - The length of time in
263 seconds (relative to the time the packet is sent)
264 that the prefix is valid for the purpose of on-link
265 determination. A value of all one bits
266 (0xffffffff) represents infinity
267 @param pref_lifetime - The length of time in
268 seconds (relative to the time the packet is sent)
269 that addresses generated from the prefix via
270 stateless address autoconfiguration remain
271 preferred [ADDRCONF]. A value of all one bits
272 (0xffffffff) represents infinity.
274 autoreply define sw_interface_ip6nd_ra_prefix
291 /** \brief IPv6 ND proxy config
292 @param client_index - opaque cookie to identify the sender
293 @param context - sender context, to match reply w/ request
294 @param sw_if_index - The interface the host is on
295 @param address - The address of the host for which to proxy for
296 @param is_add - Adding or deleting
298 autoreply define ip6nd_proxy_add_del
307 /** \brief IPv6 ND proxy details returned after request
308 @param context - sender context, to match reply w/ request
309 @param retval - return code for the request
311 define ip6nd_proxy_details
319 /** \brief IPv6 ND proxy dump request
320 @param context - sender context, to match reply w/ request
321 @param retval - return code for the request
322 @param sw_if_index - The interface the host is on
323 @param address - The address of the host for which to proxy for
325 define ip6nd_proxy_dump
331 /** \brief IPv6 interface enable / disable request
332 @param client_index - opaque cookie to identify the sender
333 @param context - sender context, to match reply w/ request
334 @param sw_if_index - interface used to reach neighbor
335 @param enable - if non-zero enable ip6 on interface, else disable
337 autoreply define sw_interface_ip6_enable_disable
342 u8 enable; /* set to true if enable */
345 /** \brief IPv6 set link local address on interface request
346 @param client_index - opaque cookie to identify the sender
347 @param context - sender context, to match reply w/ request
348 @param sw_if_index - interface to set link local on
349 @param address[] - the new link local address
351 autoreply define sw_interface_ip6_set_link_local_address
359 /** \brief Add / del route request
360 @param client_index - opaque cookie to identify the sender
361 @param context - sender context, to match reply w/ request
362 @param sw_if_index - software index of the new vlan's parent interface
363 @param vrf_id - fib table /vrf associated with the route
364 @param lookup_in_vrf -
365 @param classify_table_index -
366 @param create_vrf_if_needed -
367 @param is_add - 1 if adding the route, 0 if deleting
368 @param is_drop - Drop the packet
369 @param is_unreach - Drop the packet and rate limit send ICMP unreachable
370 @param is_prohibit - Drop the packet and rate limit send ICMP prohibited
371 @param is_ipv6 - 0 if an ip4 route, else ip6
372 @param is_local - The route will result in packets sent to VPP IP stack
373 @param is_udp_encap - The path describes a UDP-o-IP encapsulation.
375 @param is_multipath - Set to 1 if this is a multipath route, else 0
376 @param is_source_lookup - The the path is a deaggregate path (i.e. a lookup
377 in another table) is the lookup on the packet's
378 source address or destination.
379 @param next_hop_weight - Weight for Unequal cost multi-path
380 @param next_hop_preference - Path that are up that have the best preference are
381 are used for forwarding. lower value is better.
382 @param next_hop_id - Used when the path resolves via an object that has a unique
384 @param dst_address_length -
385 @param dst_address[16] -
386 @param next_hop_address[16] -
387 @param next_hop_n_out_labels - the number of labels in the label stack
388 @param next_hop_out_label_stack - the next-hop output label stack, outer most first
389 @param next_hop_via_label - The next-hop is a resolved via a local label
391 autoreply define ip_add_del_route
395 u32 next_hop_sw_if_index;
397 u32 classify_table_index;
398 u32 next_hop_table_id;
400 u8 create_vrf_if_needed;
410 u8 is_resolve_attached;
415 u8 next_hop_preference;
417 u8 dst_address_length;
419 u8 next_hop_address[16];
420 u8 next_hop_n_out_labels;
421 u32 next_hop_via_label;
422 u32 next_hop_out_label_stack[next_hop_n_out_labels];
425 /** \brief Add / del route request
426 @param client_index - opaque cookie to identify the sender
427 @param context - sender context, to match reply w/ request
428 @param sw_if_index - software index of the new vlan's parent interface
429 @param vrf_id - fib table /vrf associated with the route
430 @param next_hop_afi - Use dpo_proto_t
433 autoreply define ip_mroute_add_del
437 u32 next_hop_sw_if_index;
443 u16 grp_address_length;
445 u8 create_vrf_if_needed;
453 /** \brief Dump IP multicast fib table
454 @param client_index - opaque cookie to identify the sender
462 /** \brief IP Multicast FIB table response
463 @param table_id - IP fib table id
464 @address_length - mask length
465 @grp_address - Group address/prefix
466 @src_address - Source address
467 @param count - the number of fib_path in path
468 @param path - array of of fib_path structures
470 manual_endian manual_print define ip_mfib_details
480 vl_api_fib_path_t path[count];
483 /** \brief Dump IP6 multicast fib table
484 @param client_index - opaque cookie to identify the sender
492 /** \brief IP6 Multicast FIB table response
493 @param table_id - IP fib table id
494 @address_length - mask length
495 @grp_address - Group address/prefix
496 @src_address - Source address
497 @param count - the number of fib_path in path
498 @param path - array of of fib_path structures
500 manual_endian manual_print define ip6_mfib_details
508 vl_api_fib_path_t path[count];
511 define ip_address_details
521 define ip_address_dump
543 define mfib_signal_dump
549 define mfib_signal_details
559 u8 ip_packet_data[256];
562 /** \brief IP punt policer
563 @param client_index - opaque cookie to identify the sender
564 @param context - sender context, to match reply w/ request
565 @param is_add - 1 to add neighbor, 0 to delete
566 @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
567 @param policer_index - Index of policer to use
569 autoreply define ip_punt_police
578 /** \brief IP punt redirect
579 @param client_index - opaque cookie to identify the sender
580 @param context - sender context, to match reply w/ request
581 @param is_add - 1 to add neighbor, 0 to delete
582 @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
583 @param tx_sw_if_index - the TX interface to which traffic shoulde be
585 @param nh - The next-hop to redirect the traffic to.
587 autoreply define ip_punt_redirect
598 autoreply define ip_container_proxy_add_del
611 * eval: (c-set-style "gnu")