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:
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 vpe control-plane API messages which are generally
19 called through a shared memory interface.
23 * Note: API placement cleanup in progress
24 * If you're looking for interface APIs, please
25 * see .../vnet/vnet/{interface.api,interface_api.c}
26 * IP APIs: see .../vnet/vnet/ip/{ip.api, ip_api.c}
27 * TAP APIs: see .../vnet/vnet/unix/{tap.api, tap_api.c}
28 * VXLAN APIs: see .../vnet/vnet/vxlan/{vxlan.api, vxlan_api.c}
29 * AF-PACKET APIs: ... see /vnet/devices/af_packet/{af_packet.api, af_packet_api.c}
30 * NETMAP APIs: see ... /vnet/vnet/devices/netmap/{netmap.api, netmap_api.c}
31 * VHOST-USER APIs: see .../vnet/devices/virtio/{vhost_user.api, vhost_user_api.c}
32 * VXLAN GPE APIs: see .../vnet/vnet/vxlan-gpe/{vxlan_gpe.api, vxlan_gpe_api.c}
33 * GRE APIs: see .../vnet/vnet/gre/{gre.api, gre_api.c}
34 * L2TP APIs: see .../vnet/vnet/l2tp/{l2tp.api, l2tp_api.c}
35 * BFD APIs: see .../vnet/vnet/bfd/{bfd.api, bfd_api.c}
36 * IPSEC APIs: see .../vnet/vnet/ipsec/{ipsec.api, ipsec_api.c}
37 * IPSEC-GRE APIs: see .../vnet/vnet/ipsec-gre/{ipsec_gre.api, ipsec_gre_api.c}
38 * LISP APIs: see .../vnet/vnet/lisp/{lisp.api, lisp_api.c}
39 * LISP-GPE APIs: see .../vnet/vnet/lisp-gpe/{lisp_gpe.api, lisp_gpe_api.c}
42 /** \brief Create a new subinterface with the given vlan id
43 @param client_index - opaque cookie to identify the sender
44 @param context - sender context, to match reply w/ request
45 @param sw_if_index - software index of the new vlan's parent interface
46 @param vlan_id - vlan tag of the new interface
48 define create_vlan_subif
56 /** \brief Reply for the vlan subinterface create request
57 @param context - returned sender context, to match reply w/ request
58 @param retval - return code
59 @param sw_if_index - software index allocated for the new subinterface
61 define create_vlan_subif_reply
68 /** \brief Enable or Disable MPLS on and interface
69 @param client_index - opaque cookie to identify the sender
70 @param context - sender context, to match reply w/ request
71 @param sw_if_index - index of the interface
72 @param enable - if non-zero enable, else disable
74 define sw_interface_set_mpls_enable
82 /** \brief Reply for MPLS state on an interface
83 @param context - returned sender context, to match reply w/ request
84 @param retval - return code
86 define sw_interface_set_mpls_enable_reply
92 /** \brief MPLS Route Add / del route
93 @param client_index - opaque cookie to identify the sender
94 @param context - sender context, to match reply w/ request
95 @param mr_label - The MPLS label value
96 @param mr_eos - The End of stack bit
97 @param mr_table_id - The MPLS table-id the route is added in
98 @param mr_classify_table_index - If this is a classify route,
99 this is the classify table index
100 @param mr_create_table_if_needed - If the MPLS or IP tables do not exist,
102 @param mr_is_add - Is this a route add or delete
103 @param mr_is_classify - Is this route result a classify
104 @param mr_is_multipath - Is this route update a multipath - i.e. is this
105 a path addition to an existing route
106 @param mr_is_resolve_host - Recurse resolution constraint via a host prefix
107 @param mr_is_resolve_attached - Recurse resolution constraint via attached prefix
108 @param mr_next_hop_proto_is_ip4 - The next-hop is IPV4
109 @param mr_next_hop_weight - The weight, for UCMP
110 @param mr_next_hop[16] - the nextop address
111 @param mr_next_hop_sw_if_index - the next-hop SW interface
112 @param mr_next_hop_table_id - the next-hop table-id (if appropriate)
113 @param mr_next_hop_n_out_labels - the number of labels in the label stack
114 @param mr_next_hop_out_label_stack - the next-hop output label stack, outer most first
115 @param next_hop_via_label - The next-hop is a resolved via a local label
117 define mpls_route_add_del
124 u32 mr_classify_table_index;
125 u8 mr_create_table_if_needed;
129 u8 mr_is_resolve_host;
130 u8 mr_is_resolve_attached;
131 u8 mr_next_hop_proto_is_ip4;
132 u8 mr_next_hop_weight;
134 u8 mr_next_hop_n_out_labels;
135 u32 mr_next_hop_sw_if_index;
136 u32 mr_next_hop_table_id;
137 u32 mr_next_hop_via_label;
138 u32 mr_next_hop_out_label_stack[mr_next_hop_n_out_labels];
141 /** \brief Reply for MPLS route add / del request
142 @param context - returned sender context, to match reply w/ request
143 @param retval - return code
145 define mpls_route_add_del_reply
151 /** \brief Dump MPLS fib table
152 @param client_index - opaque cookie to identify the sender
161 @param sw_if_index - index of the interface
162 @param weight - The weight, for UCMP
163 @param is_local - local if non-zero, else remote
164 @param is_drop - Drop the packet
165 @param is_unreach - Drop the packet and rate limit send ICMP unreachable
166 @param is_prohibit - Drop the packet and rate limit send ICMP prohibited
167 @param afi - the afi of the next hop, IP46_TYPE_IP4=1, IP46_TYPE_IP6=2
168 @param next_hop[16] - the next hop address
170 WARNING: this type is replicated, pending cleanup completion
173 typeonly manual_print manual_endian define fib_path2
185 /** \brief mpls FIB table response
186 @param table_id - MPLS fib table id
187 @param s_bit - End-of-stack bit
188 @param label - MPLS label value
189 @param count - the number of fib_path in path
190 @param path - array of of fib_path structures
192 manual_endian manual_print define mpls_fib_details
199 vl_api_fib_path2_t path[count];
202 /** \brief Bind/Unbind an MPLS local label to an IP prefix. i.e. create
203 a per-prefix label entry.
204 @param client_index - opaque cookie to identify the sender
205 @param context - sender context, to match reply w/ request
206 @param mb_mpls_table_id - The MPLS table-id the MPLS entry will be added in
207 @param mb_label - The MPLS label value to bind
208 @param mb_ip_table_id - The IP table-id of the IP prefix to bind to.
209 @param mb_create_table_if_needed - Create either/both tables if required.
210 @param mb_is_bind - Bind or unbind
211 @param mb_is_ip4 - The prefix to bind to is IPv4
212 @param mb_address_length - Length of IP prefix
213 @param mb_address[16] - IP prefix/
215 define mpls_ip_bind_unbind
219 u32 mb_mpls_table_id;
222 u8 mb_create_table_if_needed;
225 u8 mb_address_length;
229 /** \brief Reply for MPLS IP bind/unbind request
230 @param context - returned sender context, to match reply w/ request
231 @param retval - return code
233 define mpls_ip_bind_unbind_reply
239 /** \brief MPLS tunnel Add / del route
240 @param client_index - opaque cookie to identify the sender
241 @param context - sender context, to match reply w/ request
242 @param mt_is_add - Is this a route add or delete
243 @param mt_sw_if_index - The SW interface index of the tunnel to delete
244 @param mt_next_hop_proto_is_ip4 - The next-hop is IPV4
245 @param mt_next_hop_weight - The weight, for UCMP
246 @param mt_next_hop[16] - the nextop address
247 @param mt_next_hop_sw_if_index - the next-hop SW interface
248 @param mt_next_hop_table_id - the next-hop table-id (if appropriate)
249 @param mt_next_hop_n_out_labels - the number of next-hop output labels
250 @param mt_next_hop_out_label_stack - the next-hop output label stack, outer most first
252 define mpls_tunnel_add_del
259 u8 mt_next_hop_proto_is_ip4;
260 u8 mt_next_hop_weight;
262 u8 mt_next_hop_n_out_labels;
263 u32 mt_next_hop_sw_if_index;
264 u32 mt_next_hop_table_id;
265 u32 mt_next_hop_out_label_stack[mt_next_hop_n_out_labels];
268 /** \brief Reply for MPLS tunnel add / del request
269 @param context - returned sender context, to match reply w/ request
270 @param retval - return code
271 @param sw_if_index - SW interface index of the tunnel created
273 define mpls_tunnel_add_del_reply
280 /** \brief Dump mpls eth tunnel table
281 @param client_index - opaque cookie to identify the sender
282 @param tunnel_index - eth tunnel identifier or -1 in case of all tunnels
284 define mpls_tunnel_dump
291 /** \brief mpls eth tunnel operational state response
292 @param tunnel_index - eth tunnel identifier
293 @param intfc_address - interface ipv4 addr
294 @param mask_width - interface ipv4 addr mask
295 @param hw_if_index - interface id
297 @param tunnel_dst_mac -
298 @param tx_sw_if_index -
299 @param encap_index - reference to mpls label table
300 @param nlabels - number of resolved labels
301 @param labels - resolved labels
303 define mpls_tunnel_details
309 u8 mt_next_hop_proto_is_ip4;
311 u32 mt_next_hop_sw_if_index;
312 u32 mt_next_hop_table_id;
313 u32 mt_next_hop_n_labels;
314 u32 mt_next_hop_out_labels[mt_next_hop_n_labels];
317 /** \brief Proxy ARP add / del request
318 @param client_index - opaque cookie to identify the sender
319 @param context - sender context, to match reply w/ request
320 @param vrf_id - VRF / Fib table ID
321 @param is_add - 1 if adding the Proxy ARP range, 0 if deleting
322 @param low_address[4] - Low address of the Proxy ARP range
323 @param hi_address[4] - High address of the Proxy ARP range
325 define proxy_arp_add_del
335 /** \brief Reply for proxy arp add / del request
336 @param context - returned sender context, to match reply w/ request
337 @param retval - return code
339 define proxy_arp_add_del_reply
345 /** \brief Proxy ARP add / del 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 - Which interface to enable / disable Proxy Arp on
349 @param enable_disable - 1 to enable Proxy ARP on interface, 0 to disable
351 define proxy_arp_intfc_enable_disable
356 /* 1 = on, 0 = off */
360 /** \brief Reply for Proxy ARP interface enable / disable request
361 @param context - returned sender context, to match reply w/ request
362 @param retval - return code
364 define proxy_arp_intfc_enable_disable_reply
370 /** \brief Reset VRF (remove all routes etc) request
371 @param client_index - opaque cookie to identify the sender
372 @param context - sender context, to match reply w/ request
373 @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
374 @param vrf_id - ID of th FIB table / VRF to reset
384 /** \brief Reply for Reset VRF request
385 @param context - returned sender context, to match reply w/ request
386 @param retval - return code
388 define reset_vrf_reply
394 /** \brief Is Address Reachable request - DISABLED
395 @param client_index - opaque cookie to identify the sender
396 @param context - sender context, to match reply w/ request
397 @param next_hop_sw_if_index - index of interface used to get to next hop
398 @param is_ipv6 - 1 for IPv6, 0 for IPv4
399 @param is_error - address not found or does not match intf
400 @param address[] - Address in question
402 define is_address_reachable
404 u32 client_index; /* (api_main_t *) am->my_client_index */
406 u32 next_hop_sw_if_index;
407 u8 is_known; /* on reply, this is the answer */
409 u8 is_error; /* address not found or does not match intf */
413 /** \brief Want Stats, register for stats updates
414 @param client_index - opaque cookie to identify the sender
415 @param context - sender context, to match reply w/ request
416 @param enable_disable - 1 = enable stats, 0 = disable
417 @param pid - pid of process requesting stats updates
427 /** \brief Reply for Want Stats request
428 @param context - returned sender context, to match reply w/ request
429 @param retval - return code
431 define want_stats_reply
437 typeonly manual_print manual_endian define ip4_fib_counter
445 manual_print manual_endian define vnet_ip4_fib_counters
449 vl_api_ip4_fib_counter_t c[count];
452 typeonly manual_print manual_endian define ip6_fib_counter
460 manual_print manual_endian define vnet_ip6_fib_counters
464 vl_api_ip6_fib_counter_t c[count];
467 /** \brief Request for a single block of summary stats
468 @param client_index - opaque cookie to identify the sender
469 @param context - sender context, to match reply w/ request
471 define vnet_get_summary_stats
477 /** \brief Reply for vnet_get_summary_stats request
478 @param context - sender context, to match reply w/ request
479 @param retval - return code for request
484 define vnet_summary_stats_reply
493 /** \brief OAM event structure
494 @param dst_address[] -
503 /** \brief Want OAM events request
504 @param client_index - opaque cookie to identify the sender
505 @param context - sender context, to match reply w/ request
506 @param enable_disable- enable if non-zero, else disable
507 @param pid - pid of the requesting process
509 define want_oam_events
517 /** \brief Want OAM events response
518 @param context - sender context, to match reply w/ request
519 @param retval - return code for the want oam stats request
521 define want_oam_events_reply
527 /** \brief OAM add / del target request
528 @param client_index - opaque cookie to identify the sender
529 @param context - sender context, to match reply w/ request
530 @param vrf_id - vrf_id of the target
531 @param src_address[] - source address to use for the updates
532 @param dst_address[] - destination address of the target
533 @param is_add - add target if non-zero, else delete
545 /** \brief OAM add / del target response
546 @param context - sender context, to match reply w/ request
547 @param retval - return code of the request
549 define oam_add_del_reply
555 /** \brief Reset fib table request
556 @param client_index - opaque cookie to identify the sender
557 @param context - sender context, to match reply w/ request
558 @param vrf_id - vrf/table id of the fib table to reset
559 @param is_ipv6 - an ipv6 fib to reset if non-zero, else ipv4
569 /** \brief Reset fib response
570 @param context - sender context, to match reply w/ request
571 @param retval - return code for the reset bfib request
573 define reset_fib_reply
579 /** \brief DHCP Proxy config add / del request
580 @param client_index - opaque cookie to identify the sender
581 @param context - sender context, to match reply w/ request
582 @param vrf_id - vrf id
583 @param if_ipv6 - ipv6 if non-zero, else ipv4
584 @param is_add - add the config if non-zero, else delete
585 @param insert_circuit_id - option82 suboption 1 fib number
586 @param dhcp_server[] - server address
587 @param dhcp_src_address[] - <fix this, need details>
589 define dhcp_proxy_config
596 u8 insert_circuit_id;
598 u8 dhcp_src_address[16];
601 /** \brief DHCP Proxy config response
602 @param context - sender context, to match reply w/ request
603 @param retval - return code for the request
605 define dhcp_proxy_config_reply
611 /** \brief DHCP Proxy set / unset vss request
612 @param client_index - opaque cookie to identify the sender
613 @param context - sender context, to match reply w/ request
614 @param tbl_id - table id
615 @param oui - first part of vpn id
616 @param fib_id - second part of vpn id
617 @param is_ipv6 - ip6 if non-zero, else ip4
618 @param is_add - set vss if non-zero, else delete
620 define dhcp_proxy_set_vss
631 /** \brief DHCP proxy set / unset vss response
632 @param context - sender context, to match reply w/ request
633 @param retval - return code for the request
635 define dhcp_proxy_set_vss_reply
641 /** \brief Create loopback interface request
642 @param client_index - opaque cookie to identify the sender
643 @param context - sender context, to match reply w/ request
644 @param mac_address - mac addr to assign to the interface if none-zero
646 define create_loopback
653 /** \brief Create loopback interface response
654 @param context - sender context, to match reply w/ request
655 @param sw_if_index - sw index of the interface that was created
656 @param retval - return code for the request
658 define create_loopback_reply
665 /** \brief Delete loopback interface request
666 @param client_index - opaque cookie to identify the sender
667 @param context - sender context, to match reply w/ request
668 @param sw_if_index - sw index of the interface that was created
670 define delete_loopback
677 /** \brief Delete loopback interface response
678 @param context - sender context, to match reply w/ request
679 @param retval - return code for the request
681 define delete_loopback_reply
687 /** \brief Control ping from client to api server request
688 @param client_index - opaque cookie to identify the sender
689 @param context - sender context, to match reply w/ request
697 /** \brief Control ping from the client to the server response
698 @param client_index - opaque cookie to identify the sender
699 @param context - sender context, to match reply w/ request
700 @param retval - return code for the request
701 @param vpe_pid - the pid of the vpe, returned by the server
703 define control_ping_reply
711 /** \brief Process a vpe parser cli string request
712 @param client_index - opaque cookie to identify the sender
713 @param context - sender context, to match reply w/ request
714 @param cmd_in_shmem - pointer to cli command string
730 /** \brief vpe parser cli string response
731 @param context - sender context, to match reply w/ request
732 @param retval - return code for request
733 @param reply_in_shmem - Reply string from cli processing if any
741 define cli_inband_reply
749 /** \brief Set max allowed ARP or ip6 neighbor entries request
750 @param client_index - opaque cookie to identify the sender
751 @param context - sender context, to match reply w/ request
752 @param is_ipv6 - neighbor limit if non-zero, else ARP limit
753 @param arp_neighbor_limit - the new limit, defaults are ~ 50k
755 define set_arp_neighbor_limit
760 u32 arp_neighbor_limit;
763 /** \brief Set max allowed ARP or ip6 neighbor entries response
764 @param context - sender context, to match reply w/ request
765 @param retval - return code for request
767 define set_arp_neighbor_limit_reply
773 /** \brief L2 interface patch add / del request
774 @param client_index - opaque cookie to identify the sender
775 @param context - sender context, to match reply w/ request
776 @param rx_sw_if_index - receive side interface
777 @param tx_sw_if_index - transmit side interface
778 @param is_add - if non-zero set up the interface patch, else remove it
780 define l2_patch_add_del
789 /** \brief L2 interface patch add / del response
790 @param context - sender context, to match reply w/ request
791 @param retval - return code for the request
793 define l2_patch_add_del_reply
799 /** \brief IPv6 segment routing tunnel add / del request
800 @param client_index - opaque cookie to identify the sender
801 @param context - sender context, to match reply w/ request
802 @param is_add - add the tunnel if non-zero, else delete it
803 @param name[] - tunnel name (len. 64)
804 @param src_address[] -
805 @param dst_address[] -
806 @param dst_mask_width -
807 @param inner_vrf_id -
808 @param outer_vrf_id -
809 @param flags_net_byte_order -
812 @param segs_and_tags[] -
813 @param policy_name[] - name of policy to associate this tunnel to (len. 64)
815 define sr_tunnel_add_del
826 u16 flags_net_byte_order;
833 /** \brief IPv6 segment routing tunnel add / del response
834 @param context - sender context, to match reply w/ request
835 @param retval - return value for request
837 define sr_tunnel_add_del_reply
843 /** \brief IPv6 segment routing policy add / del request
844 @param client_index - opaque cookie to identify the sender
845 @param context - sender context, to match reply w/ request
846 @param is_add - add the tunnel if non-zero, else delete it
847 @param name[] - policy name (len. 64)
848 @param tunnel_names[] -
850 define sr_policy_add_del
859 /** \brief IPv6 segment routing policy add / del response
860 @param context - sender context, to match reply w/ request
861 @param retval - return value for request
863 define sr_policy_add_del_reply
869 /** \brief IPv6 segment routing multicast map to policy add / del request
870 @param client_index - opaque cookie to identify the sender
871 @param context - sender context, to match reply w/ request
872 @param is_add - add the tunnel if non-zero, else delete it
873 @param multicast_address[] - IP6 multicast address
874 @param policy_name[] = policy name (len.64)
876 define sr_multicast_map_add_del
881 u8 multicast_address[16];
885 /** \brief IPv6 segment routing multicast map to policy add / del response
886 @param context - sender context, to match reply w/ request
887 @param retval - return value for request
889 define sr_multicast_map_add_del_reply
895 /** \brief Interface set vpath request
896 @param client_index - opaque cookie to identify the sender
897 @param context - sender context, to match reply w/ request
898 @param sw_if_index - interface used to reach neighbor
899 @param enable - if non-zero enable, else disable
901 define sw_interface_set_vpath
909 /** \brief Interface set vpath response
910 @param context - sender context, to match reply w/ request
911 @param retval - return code for the request
913 define sw_interface_set_vpath_reply
919 /** \brief Set L2 XConnect between two interfaces request
920 @param client_index - opaque cookie to identify the sender
921 @param context - sender context, to match reply w/ request
922 @param rx_sw_if_index - Receive interface index
923 @param tx_sw_if_index - Transmit interface index
924 @param enable - enable xconnect if not 0, else set to L3 mode
926 define sw_interface_set_l2_xconnect
935 /** \brief Set L2 XConnect response
936 @param context - sender context, to match reply w/ request
937 @param retval - L2 XConnect request return code
939 define sw_interface_set_l2_xconnect_reply
945 /** \brief Interface bridge mode request
946 @param client_index - opaque cookie to identify the sender
947 @param context - sender context, to match reply w/ request
948 @param rx_sw_if_index - the interface
949 @param bd_id - bridge domain id
950 @param bvi - Setup interface as a bvi, bridge mode only
951 @param shg - Shared horizon group, for bridge mode only
952 @param enable - Enable beige mode if not 0, else set to L3 mode
954 define sw_interface_set_l2_bridge
965 /** \brief Interface bridge mode response
966 @param context - sender context, to match reply w/ request
967 @param retval - Bridge mode request return code
969 define sw_interface_set_l2_bridge_reply
975 /** \brief L2 FIB add entry request
976 @param client_index - opaque cookie to identify the sender
977 @param context - sender context, to match reply w/ request
978 @param mac - the entry's mac address
979 @param bd_id - the entry's bridge domain id
980 @param sw_if_index - the interface
981 @param is_add - If non zero add the entry, else delete it
998 /** \brief L2 FIB add entry response
999 @param context - sender context, to match reply w/ request
1000 @param retval - return code for the add l2fib entry request
1002 define l2fib_add_del_reply
1008 /** \brief Set L2 flags request !!! TODO - need more info, feature bits in l2_input.h
1009 @param client_index - opaque cookie to identify the sender
1010 @param context - sender context, to match reply w/ request
1011 @param sw_if_index - interface
1012 @param is_set - if non-zero, set the bits, else clear them
1013 @param feature_bitmap - non-zero bits to set or clear
1024 /** \brief Set L2 bits response
1025 @param context - sender context, to match reply w/ request
1026 @param retval - return code for the set l2 bits request
1028 define l2_flags_reply
1032 u32 resulting_feature_bitmap;
1035 /** \brief Set bridge flags (such as L2_LEARN, L2_FWD, L2_FLOOD,
1036 L2_UU_FLOOD, or L2_ARP_TERM) request
1037 @param client_index - opaque cookie to identify the sender
1038 @param context - sender context, to match reply w/ request
1039 @param bd_id - the bridge domain to set the flags for
1040 @param is_set - if non-zero, set the flags, else clear them
1041 @param feature_bitmap - bits that are non-zero to set or clear
1052 /** \brief Set bridge flags response
1053 @param context - sender context, to match reply w/ request
1054 @param retval - return code for the set bridge flags request
1055 @param resulting_feature_bitmap - the feature bitmap value after the request is implemented
1057 define bridge_flags_reply
1061 u32 resulting_feature_bitmap;
1064 /** \brief Set bridge domain ip to mac entry request
1065 @param client_index - opaque cookie to identify the sender
1066 @param context - sender context, to match reply w/ request
1067 @param bd_id - the bridge domain to set the flags for
1068 @param is_add - if non-zero, add the entry, else clear it
1069 @param is_ipv6 - if non-zero, ipv6 address, else ipv4 address
1070 @param mac_address - MAC address
1073 define bd_ip_mac_add_del
1084 /** \brief Set bridge domain ip to mac entry response
1085 @param context - sender context, to match reply w/ request
1086 @param retval - return code for the set bridge flags request
1088 define bd_ip_mac_add_del_reply
1094 /** \brief Add/Delete classification table request
1095 @param client_index - opaque cookie to identify the sender
1096 @param context - sender context, to match reply w/ request
1097 @param is_add- if non-zero add the table, else delete it
1098 @param del_chain - if non-zero delete the whole chain of tables
1099 @param table_index - if add, reuturns index of the created table, else specifies the table to delete
1100 @param nbuckets - number of buckets when adding a table
1101 @param memory_size - memory size when adding a table
1102 @param match_n_vectors - number of match vectors
1103 @param next_table_index - index of next table
1104 @param miss_next_index - index of miss table
1105 @param current_data_flag - option to use current node's packet payload
1106 as the starting point from where packets are classified,
1107 This option is only valid for L2/L3 input ACL for now.
1108 0: by default, classify data from the buffer's start location
1109 1: classify packets from VPP node’s current data pointer
1110 @param current_data_offset - a signed value to shift the start location of
1111 the packet to be classified
1112 For example, if input IP ACL node is used, L2 header’s first byte
1113 can be accessible by configuring current_data_offset to -14
1114 if there is no vlan tag.
1115 This is valid only if current_data_flag is set to 1.
1116 @param mask[] - match mask
1118 define classify_add_del_table
1128 u32 match_n_vectors;
1129 u32 next_table_index;
1130 u32 miss_next_index;
1131 u32 current_data_flag;
1132 i32 current_data_offset;
1136 /** \brief Add/Delete classification table response
1137 @param context - sender context, to match reply w/ request
1138 @param retval - return code for the table add/del requst
1139 @param new_table_index - for add, returned index of the new table
1140 @param skip_n_vectors - for add, returned value of skip_n_vectors in table
1141 @param match_n_vectors -for add, returned value of match_n_vectors in table
1143 define classify_add_del_table_reply
1147 u32 new_table_index;
1149 u32 match_n_vectors;
1152 /** \brief Classify add / del session request
1153 @param client_index - opaque cookie to identify the sender
1154 @param context - sender context, to match reply w/ request
1155 @param is_add - add session if non-zero, else delete
1156 @param table_index - index of the table to add/del the session, required
1157 @param hit_next_index - for add, hit_next_index of new session, required
1158 @param opaque_index - for add, opaque_index of new session
1159 @param advance -for add, advance value for session
1161 0: no action (by default)
1162 metadata is not used.
1163 1: Classified IP packets will be looked up from the
1164 specified ipv4 fib table (configured by metadata as VRF id).
1165 Only valid for L3 input ACL node
1166 2: Classified IP packets will be looked up from the
1167 specified ipv6 fib table (configured by metadata as VRF id).
1168 Only valid for L3 input ACL node
1169 @param metadata - valid only if action != 0
1170 VRF id if action is 1 or 2.
1171 @param match[] - for add, match value for session, required
1173 define classify_add_del_session
1187 /** \brief Classify add / del session response
1188 @param context - sender context, to match reply w/ request
1189 @param retval - return code for the add/del session request
1191 define classify_add_del_session_reply
1197 /** \brief Set/unset the classification table for an interface request
1198 @param client_index - opaque cookie to identify the sender
1199 @param context - sender context, to match reply w/ request
1200 @param is_ipv6 - ipv6 if non-zero, else ipv4
1201 @param sw_if_index - interface to associate with the table
1202 @param table_index - index of the table, if ~0 unset the table
1204 define classify_set_interface_ip_table
1210 u32 table_index; /* ~0 => off */
1213 /** \brief Set/unset interface classification table response
1214 @param context - sender context, to match reply w/ request
1215 @param retval - return code
1217 define classify_set_interface_ip_table_reply
1223 /** \brief Set/unset l2 classification tables for an interface request
1224 @param client_index - opaque cookie to identify the sender
1225 @param context - sender context, to match reply w/ request
1226 @param sw_if_index - interface to set/unset tables for
1227 @param ip4_table_index - ip4 index, use ~0 for all 3 indexes to unset
1228 @param ip6_table_index - ip6 index
1229 @param other_table_index - other index
1231 define classify_set_interface_l2_tables
1237 u32 ip4_table_index;
1238 u32 ip6_table_index;
1239 u32 other_table_index;
1243 /** \brief Set/unset l2 classification tables for an interface response
1244 @param context - sender context, to match reply w/ request
1245 @param retval - return code for the request
1247 define classify_set_interface_l2_tables_reply
1253 /** \brief Get node index using name request
1254 @param client_index - opaque cookie to identify the sender
1255 @param context - sender context, to match reply w/ request
1256 @param node_name[] - name of the node
1258 define get_node_index
1265 /** \brief Get node index using name request
1266 @param context - sender context, to match reply w/ request
1267 @param retval - return code for the request
1268 @param node_index - index of the desired node if found, else ~0
1270 define get_node_index_reply
1277 /** \brief Set the next node for a given node request
1278 @param client_index - opaque cookie to identify the sender
1279 @param context - sender context, to match reply w/ request
1280 @param node_name[] - node to add the next node to
1281 @param next_name[] - node to add as the next node
1283 define add_node_next
1291 /** \brief IP Set the next node for a given node response
1292 @param context - sender context, to match reply w/ request
1293 @param retval - return code for the add next node request
1294 @param next_index - the index of the next node if success, else ~0
1296 define add_node_next_reply
1303 /** \brief DHCP Proxy config 2 add / del request
1304 @param client_index - opaque cookie to identify the sender
1305 @param context - sender context, to match reply w/ request
1306 @param rx_vrf_id - receive vrf id
1307 @param server_vrf_id - server vrf id
1308 @param if_ipv6 - ipv6 if non-zero, else ipv4
1309 @param is_add - add the config if non-zero, else delete
1310 @param insert_circuit_id - option82 suboption 1 fib number
1311 @param dhcp_server[] - server address
1312 @param dhcp_src_address[] - <fix this, need details>
1314 define dhcp_proxy_config_2
1322 u8 insert_circuit_id;
1324 u8 dhcp_src_address[16];
1327 /** \brief DHCP Proxy config 2 add / del response
1328 @param context - sender context, to match reply w/ request
1329 @param retval - return code for request
1331 define dhcp_proxy_config_2_reply
1337 /** \brief L2 fib clear table request, clear all mac entries in the l2 fib
1338 @param client_index - opaque cookie to identify the sender
1339 @param context - sender context, to match reply w/ request
1341 define l2_fib_clear_table
1347 /** \brief L2 fib clear table response
1348 @param context - sender context, to match reply w/ request
1349 @param retval - return code for the request
1351 define l2_fib_clear_table_reply
1357 /** \brief L2 interface ethernet flow point filtering enable/disable request
1358 @param client_index - opaque cookie to identify the sender
1359 @param context - sender context, to match reply w/ request
1360 @param sw_if_index - interface to enable/disable filtering on
1361 @param enable_disable - if non-zero enable filtering, else disable
1363 define l2_interface_efp_filter
1371 /** \brief L2 interface ethernet flow point filtering response
1372 @param context - sender context, to match reply w/ request
1373 @param retval - return code for the request
1375 define l2_interface_efp_filter_reply
1381 /** \brief L2 interface vlan tag rewrite configure request
1382 @param client_index - opaque cookie to identify the sender
1383 @param context - sender context, to match reply w/ request
1384 @param sw_if_index - interface the operation is applied to
1385 @param vtr_op - Choose from l2_vtr_op_t enum values
1386 @param push_dot1q - first pushed flag dot1q id set, else dot1ad
1387 @param tag1 - Needed for any push or translate vtr op
1388 @param tag2 - Needed for any push 2 or translate x-2 vtr ops
1390 define l2_interface_vlan_tag_rewrite
1396 u32 push_dot1q; // ethertype of first pushed tag is dot1q/dot1ad
1397 u32 tag1; // first pushed tag
1398 u32 tag2; // second pushed tag
1401 /** \brief L2 interface vlan tag rewrite response
1402 @param context - sender context, to match reply w/ request
1403 @param retval - return code for the request
1405 define l2_interface_vlan_tag_rewrite_reply
1418 /* These fields map directly onto the subif template */
1422 u8 dot1ad; // 0 = dot1q, 1=dot1ad
1425 u8 outer_vlan_id_any;
1426 u8 inner_vlan_id_any;
1431 define create_subif_reply
1438 /** \brief show version
1439 @param client_index - opaque cookie to identify the sender
1440 @param context - sender context, to match reply w/ request
1448 /** \brief show version response
1449 @param context - sender context, to match reply w/ request
1450 @param retval - return code for the request
1451 @param program - name of the program (vpe)
1452 @param version - version of the program
1453 @param build_directory - root of the workspace where the program was built
1455 define show_version_reply
1462 u8 build_directory[256];
1465 /** \brief l2 fib table entry structure
1466 @param bd_id - the l2 fib / bridge domain table id
1467 @param mac - the entry's mac address
1468 @param sw_if_index - index of the interface
1469 @param static_mac - the entry is statically configured.
1470 @param filter_mac - the entry is a mac filter entry.
1471 @param bvi_mac - the mac address is a bridge virtual interface
1473 define l2_fib_table_entry
1484 /** \brief Dump l2 fib (aka bridge domain) table
1485 @param client_index - opaque cookie to identify the sender
1486 @param bd_id - the l2 fib / bridge domain table identifier
1488 define l2_fib_table_dump
1495 /* Gross kludge, DGMS */
1496 define interface_name_renumber
1501 u32 new_show_dev_instance;
1504 define interface_name_renumber_reply
1510 /** \brief Register for ip4 arp resolution events
1511 @param client_index - opaque cookie to identify the sender
1512 @param context - sender context, to match reply w/ request
1513 @param enable_disable - 1 => register for events, 0 => cancel registration
1514 @param pid - sender's pid
1515 @param address - the exact ip4 address of interest
1517 define want_ip4_arp_events
1526 /** \brief Reply for interface events registration
1527 @param context - returned sender context, to match reply w/ request
1528 @param retval - return code
1530 define want_ip4_arp_events_reply
1536 /** \brief Tell client about an ip4 arp resolution event
1537 @param client_index - opaque cookie to identify the sender
1538 @param context - sender context, to match reply w/ request
1539 @param address - the exact ip4 address of interest
1540 @param pid - client pid registered to receive notification
1541 @param sw_if_index - interface which received ARP packet
1542 @param new_mac - the new mac address
1543 @param mac_ip - 0: resolution event, 1: mac/ip binding in bd
1545 define ip4_arp_event
1556 /** \brief Register for ip6 nd resolution events
1557 @param client_index - opaque cookie to identify the sender
1558 @param context - sender context, to match reply w/ request
1559 @param enable_disable - 1 => register for events, 0 => cancel registration
1560 @param pid - sender's pid
1561 @param address - the exact ip6 address of interest
1563 define want_ip6_nd_events
1572 /** \brief Reply for ip6 nd resolution events registration
1573 @param context - returned sender context, to match reply w/ request
1574 @param retval - return code
1576 define want_ip6_nd_events_reply
1582 /** \brief Tell client about an ip6 nd resolution or mac/ip event
1583 @param client_index - opaque cookie to identify the sender
1584 @param context - sender context, to match reply w/ request
1585 @param pid - client pid registered to receive notification
1586 @param sw_if_index - interface which received ARP packet
1587 @param address - the exact ip6 address of interest
1588 @param new_mac - the new mac address
1589 @param mac_ip - 0: resolution event, 1: mac/ip binding in bd
1602 /** \brief L2 bridge domain add or delete request
1603 @param client_index - opaque cookie to identify the sender
1604 @param context - sender context, to match reply w/ request
1605 @param bd_id - the bridge domain to create
1606 @param flood - enable/disable bcast/mcast flooding in the bd
1607 @param uu_flood - enable/disable uknown unicast flood in the bd
1608 @param forward - enable/disable forwarding on all interfaces in the bd
1609 @param learn - enable/disable learning on all interfaces in the bd
1610 @param arp_term - enable/disable arp termination in the bd
1611 @param mac_age - mac aging time in min, 0 for disabled
1612 @param is_add - add or delete flag
1614 define bridge_domain_add_del
1628 /** \brief L2 bridge domain add or delete response
1629 @param context - sender context, to match reply w/ request
1630 @param retval - return code for the set bridge flags request
1632 define bridge_domain_add_del_reply
1638 /** \brief L2 bridge domain request operational state details
1639 @param client_index - opaque cookie to identify the sender
1640 @param context - sender context, to match reply w/ request
1641 @param bd_id - the bridge domain id desired or ~0 to request all bds
1643 define bridge_domain_dump
1650 /** \brief L2 bridge domain operational state response
1651 @param bd_id - the bridge domain id
1652 @param flood - bcast/mcast flooding state on all interfaces in the bd
1653 @param uu_flood - uknown unicast flooding state on all interfaces in the bd
1654 @param forward - forwarding state on all interfaces in the bd
1655 @param learn - learning state on all interfaces in the bd
1656 @param arp_term - arp termination state on all interfaces in the bd
1657 @param mac_age - mac aging time in min, 0 for disabled
1658 @param n_sw_ifs - number of sw_if_index's in the domain
1660 define bridge_domain_details
1670 u32 bvi_sw_if_index;
1674 /** \brief L2 bridge domain sw interface operational state response
1675 @param bd_id - the bridge domain id
1676 @param sw_if_index - sw_if_index in the domain
1677 @param shg - split horizon group for the interface
1679 define bridge_domain_sw_if_details
1687 /** \brief DHCP Client config add / del request
1688 @param client_index - opaque cookie to identify the sender
1689 @param context - sender context, to match reply w/ request
1690 @param sw_if_index - index of the interface for DHCP client
1691 @param hostname - hostname
1692 @param is_add - add the config if non-zero, else delete
1693 @param want_dhcp_event - DHCP event sent to the sender
1694 via dhcp_compl_event API message if non-zero
1695 @param pid - sender's pid
1697 define dhcp_client_config
1708 /** \brief DHCP Client config response
1709 @param context - sender context, to match reply w/ request
1710 @param retval - return code for the request
1712 define dhcp_client_config_reply
1718 /** \brief Set/unset input ACL interface
1719 @param client_index - opaque cookie to identify the sender
1720 @param context - sender context, to match reply w/ request
1721 @param sw_if_index - interface to set/unset input ACL
1722 @param ip4_table_index - ip4 classify table index (~0 for skip)
1723 @param ip6_table_index - ip6 classify table index (~0 for skip)
1724 @param l2_table_index - l2 classify table index (~0 for skip)
1725 @param is_add - Set input ACL if non-zero, else unset
1726 Note: User is recommeneded to use just one valid table_index per call.
1727 (ip4_table_index, ip6_table_index, or l2_table_index)
1729 define input_acl_set_interface
1734 u32 ip4_table_index;
1735 u32 ip6_table_index;
1740 /** \brief Set/unset input ACL interface response
1741 @param context - sender context, to match reply w/ request
1742 @param retval - return code for the request
1744 define input_acl_set_interface_reply
1750 /** \brief Tell client about a DHCP completion event
1751 @param client_index - opaque cookie to identify the sender
1752 @param pid - client pid registered to receive notification
1753 @param is_ipv6 - if non-zero the address is ipv6, else ipv4
1754 @param host_address - Host IP address
1755 @param router_address - Router IP address
1756 @param host_mac - Host MAC address
1758 define dhcp_compl_event
1764 u8 host_address[16];
1765 u8 router_address[16];
1769 /** \brief cop: enable/disable junk filtration features on an interface
1770 @param client_index - opaque cookie to identify the sender
1771 @param context - sender context, to match reply w/ request
1772 @param sw_if_inded - desired interface
1773 @param enable_disable - 1 => enable, 0 => disable
1776 define cop_interface_enable_disable
1784 /** \brief cop: interface enable/disable junk filtration reply
1785 @param context - returned sender context, to match reply w/ request
1786 @param retval - return code
1789 define cop_interface_enable_disable_reply
1795 /** \brief cop: enable/disable whitelist filtration features on an interface
1796 Note: the supplied fib_id must match in order to remove the feature!
1798 @param client_index - opaque cookie to identify the sender
1799 @param context - sender context, to match reply w/ request
1800 @param sw_if_index - interface handle, physical interfaces only
1801 @param fib_id - fib identifier for the whitelist / blacklist fib
1802 @param ip4 - 1 => enable ip4 filtration, 0=> disable ip4 filtration
1803 @param ip6 - 1 => enable ip6 filtration, 0=> disable ip6 filtration
1804 @param default_cop - 1 => enable non-ip4, non-ip6 filtration 0=> disable it
1807 define cop_whitelist_enable_disable
1818 /** \brief cop: interface enable/disable junk filtration reply
1819 @param context - returned sender context, to match reply w/ request
1820 @param retval - return code
1823 define cop_whitelist_enable_disable_reply
1829 /** \brief get_node_graph - get a copy of the vpp node graph
1830 including the current set of graph arcs.
1832 @param client_index - opaque cookie to identify the sender
1833 @param context - sender context, to match reply w/ request
1836 define get_node_graph
1842 /** \brief get_node_graph_reply
1843 @param context - returned sender context, to match reply w/ request
1844 @param retval - return code
1845 @param reply_in_shmem - result from vlib_node_serialize, in shared
1846 memory. Process with vlib_node_unserialize, remember to switch
1847 heaps and free the result.
1850 define get_node_graph_reply
1857 /** \brief IOAM enable : Enable in-band OAM
1858 @param id - profile id
1859 @param seqno - To enable Seqno Processing
1860 @param analyse - Enabling analysis of iOAM at decap node
1861 @param pow_enable - Proof of Work enabled or not flag
1862 @param trace_enable - iOAM Trace enabled or not flag
1876 /** \brief iOAM Trace profile add / del response
1877 @param context - sender context, to match reply w/ request
1878 @param retval - return value for request
1880 define ioam_enable_reply
1886 /** \brief iOAM disable
1887 @param client_index - opaque cookie to identify the sender
1888 @param context - sender context, to match reply w/ request
1889 @param index - MAP Domain index
1898 /** \brief iOAM disable response
1899 @param context - sender context, to match reply w/ request
1900 @param retval - return value for request
1902 define ioam_disable_reply
1908 /** \brief Add/del policer
1909 @param client_index - opaque cookie to identify the sender
1910 @param context - sender context, to match reply w/ request
1911 @param is_add - add policer if non-zero, else delete
1912 @param name - policer name
1915 @param cb - Committed Burst
1916 @param eb - Excess or Peak Burst
1917 @param rate_type - rate type
1918 @param round_type - rounding type
1919 @param type - policer algorithm
1920 @param color_aware - 0=color-blind, 1=color-aware
1921 @param conform_action_type - conform action type
1922 @param conform_dscp - DSCP for conform mar-and-transmit action
1923 @param exceed_action_type - exceed action type
1924 @param exceed_dscp - DSCP for exceed mar-and-transmit action
1925 @param violate_action_type - violate action type
1926 @param violate_dscp - DSCP for violate mar-and-transmit action
1928 define policer_add_del
1943 u8 conform_action_type;
1945 u8 exceed_action_type;
1947 u8 violate_action_type;
1951 /** \brief Add/del policer response
1952 @param context - sender context, to match reply w/ request
1953 @param retval - return value for request
1954 @param policer_index - for add, returned index of the new policer
1956 define policer_add_del_reply
1963 /** \brief Get list of policers
1964 @param client_index - opaque cookie to identify the sender
1965 @param context - sender context, to match reply w/ request
1966 @param match_name_valid - if 0 request all policers otherwise use match_name
1967 @param match_name - policer name
1974 u8 match_name_valid;
1978 /** \brief Policer operational state response.
1979 @param context - sender context, to match reply w/ request
1980 @param name - policer name
1983 @param cb - Committed Burst
1984 @param eb - Excess or Peak Burst
1985 @param rate_type - rate type
1986 @param round_type - rounding type
1987 @param type - policer algorithm
1988 @param conform_action_type - conform action type
1989 @param conform_dscp - DSCP for conform mar-and-transmit action
1990 @param exceed_action_type - exceed action type
1991 @param exceed_dscp - DSCP for exceed mar-and-transmit action
1992 @param violate_action_type - violate action type
1993 @param violate_dscp - DSCP for violate mar-and-transmit action
1994 @param single_rate - 1 = single rate policer, 0 = two rate policer
1995 @param color_aware - for hierarchical policing
1996 @param scale - power-of-2 shift amount for lower rates
1997 @param cir_tokens_per_period - number of tokens for each period
1998 @param pir_tokens_per_period - number of tokens for each period for 2-rate policer
1999 @param current_limit - current limit
2000 @param current_bucket - current bucket
2001 @param extended_limit - extended limit
2002 @param extended_bucket - extended bucket
2003 @param last_update_time - last update time
2005 define policer_details
2017 u8 conform_action_type;
2019 u8 exceed_action_type;
2021 u8 violate_action_type;
2026 u32 cir_tokens_per_period;
2027 u32 pir_tokens_per_period;
2031 u32 extended_bucket;
2032 u64 last_update_time;
2035 /** \brief Set/unset policer classify interface
2036 @param client_index - opaque cookie to identify the sender
2037 @param context - sender context, to match reply w/ request
2038 @param sw_if_index - interface to set/unset policer classify
2039 @param ip4_table_index - ip4 classify table index (~0 for skip)
2040 @param ip6_table_index - ip6 classify table index (~0 for skip)
2041 @param l2_table_index - l2 classify table index (~0 for skip)
2042 @param is_add - Set if non-zero, else unset
2043 Note: User is recommeneded to use just one valid table_index per call.
2044 (ip4_table_index, ip6_table_index, or l2_table_index)
2046 define policer_classify_set_interface
2051 u32 ip4_table_index;
2052 u32 ip6_table_index;
2057 /** \brief Set/unset policer classify interface response
2058 @param context - sender context, to match reply w/ request
2059 @param retval - return value for request
2061 define policer_classify_set_interface_reply
2067 /** \brief Get list of policer classify interfaces and tables
2068 @param client_index - opaque cookie to identify the sender
2069 @param context - sender context, to match reply w/ request
2070 @param type - classify table type
2072 define policer_classify_dump
2079 /** \brief Policer iclassify operational state response.
2080 @param context - sender context, to match reply w/ request
2081 @param sw_if_index - software interface index
2082 @param table_index - classify table index
2084 define policer_classify_details
2091 /** \brief Classify get table IDs request
2092 @param client_index - opaque cookie to identify the sender
2093 @param context - sender context, to match reply w/ request
2095 define classify_table_ids
2101 /** \brief Reply for classify get table IDs request
2102 @param context - sender context which was passed in the request
2103 @param count - number of ids returned in response
2104 @param ids - array of classify table ids
2106 define classify_table_ids_reply
2114 /** \brief Classify table ids by interface index request
2115 @param client_index - opaque cookie to identify the sender
2116 @param context - sender context, to match reply w/ request
2117 @param sw_if_index - index of the interface
2119 define classify_table_by_interface
2126 /** \brief Reply for classify table id by interface index request
2127 @param context - sender context which was passed in the request
2128 @param count - number of ids returned in response
2129 @param sw_if_index - index of the interface
2130 @param l2_table_id - l2 classify table index
2131 @param ip4_table_id - ip4 classify table index
2132 @param ip6_table_id - ip6 classify table index
2134 define classify_table_by_interface_reply
2144 /** \brief Classify table info
2145 @param client_index - opaque cookie to identify the sender
2146 @param context - sender context, to match reply w/ request
2147 @param table_id - classify table index
2149 define classify_table_info
2156 /** \brief Reply for classify table info request
2157 @param context - sender context which was passed in the request
2158 @param count - number of ids returned in response
2159 @param table_id - classify table index
2160 @param nbuckets - number of buckets when adding a table
2161 @param match_n_vectors - number of match vectors
2162 @param skip_n_vectors - number of skip_n_vectors
2163 @param active_sessions - number of sessions (active entries)
2164 @param next_table_index - index of next table
2165 @param miss_next_index - index of miss table
2166 @param mask[] - match mask
2168 define classify_table_info_reply
2174 u32 match_n_vectors;
2176 u32 active_sessions;
2177 u32 next_table_index;
2178 u32 miss_next_index;
2180 u8 mask[mask_length];
2183 /** \brief Classify sessions dump request
2184 @param client_index - opaque cookie to identify the sender
2185 @param context - sender context, to match reply w/ request
2186 @param table_id - classify table index
2188 define classify_session_dump
2195 /** \brief Reply for classify table session dump request
2196 @param context - sender context which was passed in the request
2197 @param count - number of ids returned in response
2198 @param table_id - classify table index
2199 @param hit_next_index - hit_next_index of session
2200 @param opaque_index - for add, opaque_index of session
2201 @param advance - advance value of session
2202 @param match[] - match value for session
2204 define classify_session_details
2213 u8 match[match_length];
2216 /** \brief Configure IPFIX exporter process request
2217 @param client_index - opaque cookie to identify the sender
2218 @param context - sender context, to match reply w/ request
2219 @param collector_address - address of IPFIX collector
2220 @param collector_port - port of IPFIX collector
2221 @param src_address - address of IPFIX exporter
2222 @param vrf_id - VRF / fib table ID
2223 @param path_mtu - Path MTU between exporter and collector
2224 @param template_interval - number of seconds after which to resend template
2225 @param udp_checksum - UDP checksum calculation enable flag
2227 define set_ipfix_exporter
2231 u8 collector_address[16];
2236 u32 template_interval;
2240 /** \brief Reply to IPFIX exporter configure request
2241 @param context - sender context which was passed in the request
2243 define set_ipfix_exporter_reply
2249 /** \brief IPFIX exporter dump request
2250 @param client_index - opaque cookie to identify the sender
2251 @param context - sender context, to match reply w/ request
2253 define ipfix_exporter_dump
2259 /** \brief Reply to IPFIX exporter dump request
2260 @param context - sender context which was passed in the request
2261 @param collector_address - address of IPFIX collector
2262 @param collector_port - port of IPFIX collector
2263 @param src_address - address of IPFIX exporter
2264 @param fib_index - fib table index
2265 @param path_mtu - Path MTU between exporter and collector
2266 @param template_interval - number of seconds after which to resend template
2267 @param udp_checksum - UDP checksum calculation enable flag
2269 define ipfix_exporter_details
2272 u8 collector_address[16];
2277 u32 template_interval;
2281 /** \brief IPFIX classify stream configure request
2282 @param client_index - opaque cookie to identify the sender
2283 @param context - sender context, to match reply w/ request
2284 @param domain_id - domain ID reported in IPFIX messages for classify stream
2285 @param src_port - source port of UDP session for classify stream
2287 define set_ipfix_classify_stream {
2294 /** \brief IPFIX classify stream configure response
2295 @param context - sender context, to match reply w/ request
2296 @param retval - return value for request
2298 define set_ipfix_classify_stream_reply {
2303 /** \brief IPFIX classify stream dump request
2304 @param client_index - opaque cookie to identify the sender
2305 @param context - sender context, to match reply w/ request
2307 define ipfix_classify_stream_dump {
2312 /** \brief Reply to IPFIX classify stream dump request
2313 @param context - sender context, to match reply w/ request
2314 @param domain_id - domain ID reported in IPFIX messages for classify stream
2315 @param src_port - source port of UDP session for classify stream
2317 define ipfix_classify_stream_details {
2323 /** \brief IPFIX add or delete classifier table request
2324 @param client_index - opaque cookie to identify the sender
2325 @param context - sender context, to match reply w/ request
2326 @param table_id - classifier table ID
2327 @param ip_version - version of IP used in the classifier table
2328 @param transport_protocol - transport protocol used in the classifier table or 255 for unspecified
2330 define ipfix_classify_table_add_del {
2335 u8 transport_protocol;
2339 /** \brief IPFIX add classifier table response
2340 @param context - sender context which was passed in the request
2342 define ipfix_classify_table_add_del_reply {
2347 /** \brief IPFIX classify tables dump request
2348 @param client_index - opaque cookie to identify the sender
2349 @param context - sender context, to match reply w/ request
2351 define ipfix_classify_table_dump {
2356 /** \brief Reply to IPFIX classify tables dump request
2357 @param context - sender context, to match reply w/ request
2358 @param table_id - classifier table ID
2359 @param ip_version - version of IP used in the classifier table
2360 @param transport_protocol - transport protocol used in the classifier table or 255 for unspecified
2362 define ipfix_classify_table_details {
2366 u8 transport_protocol;
2369 /** \brief Set/unset flow classify interface
2370 @param client_index - opaque cookie to identify the sender
2371 @param context - sender context, to match reply w/ request
2372 @param sw_if_index - interface to set/unset flow classify
2373 @param ip4_table_index - ip4 classify table index (~0 for skip)
2374 @param ip6_table_index - ip6 classify table index (~0 for skip)
2375 @param l2_table_index - l2 classify table index (~0 for skip)
2376 @param is_add - Set if non-zero, else unset
2377 Note: User is recommeneded to use just one valid table_index per call.
2378 (ip4_table_index, ip6_table_index, or l2_table_index)
2380 define flow_classify_set_interface {
2384 u32 ip4_table_index;
2385 u32 ip6_table_index;
2389 /** \brief Set/unset flow classify interface response
2390 @param context - sender context, to match reply w/ request
2391 @param retval - return value for request
2393 define flow_classify_set_interface_reply {
2398 /** \brief Get list of flow classify interfaces and tables
2399 @param client_index - opaque cookie to identify the sender
2400 @param context - sender context, to match reply w/ request
2401 @param type - classify table type
2403 define flow_classify_dump {
2409 /** \brief Flow classify operational state response.
2410 @param context - sender context, to match reply w/ request
2411 @param sw_if_index - software interface index
2412 @param table_index - classify table index
2414 define flow_classify_details {
2420 /** \brief Query relative index via node names
2421 @param client_index - opaque cookie to identify the sender
2422 @param context - sender context, to match reply w/ request
2423 @param node_name - name of node to find relative index from
2424 @param next_name - next node from node_name to find relative index of
2426 define get_next_index
2434 /** \brief Reply for get next node index
2435 @param context - sender context which was passed in the request
2436 @param retval - return value
2437 @param next_index - index of the next_node
2439 define get_next_index_reply
2446 /** \brief PacketGenerator create interface request
2447 @param client_index - opaque cookie to identify the sender
2448 @param context - sender context, to match reply w/ request
2449 @param interface_id - interface index
2451 define pg_create_interface
2458 /** \brief PacketGenerator create interface response
2459 @param context - sender context, to match reply w/ request
2460 @param retval - return value for request
2462 define pg_create_interface_reply
2469 /** \brief PacketGenerator capture packets on given interface request
2470 @param client_index - opaque cookie to identify the sender
2471 @param context - sender context, to match reply w/ request
2472 @param interface_id - pg interface index
2473 @param is_enabled - 1 if enabling streams, 0 if disabling
2474 @param count - number of packets to be captured
2475 @param pcap_file - pacp file name to store captured packets
2484 u32 pcap_name_length;
2485 u8 pcap_file_name[pcap_name_length];
2488 /** \brief PacketGenerator capture packets response
2489 @param context - sender context, to match reply w/ request
2490 @param retval - return value for request
2492 define pg_capture_reply
2498 /** \brief Enable / disable packet generator request
2499 @param client_index - opaque cookie to identify the sender
2500 @param context - sender context, to match reply w/ request
2501 @param is_enabled - 1 if enabling streams, 0 if disabling
2502 @param stream - stream name to be enable/disabled, if not specified handle all streams
2504 define pg_enable_disable
2509 u32 stream_name_length;
2510 u8 stream_name[stream_name_length];
2513 /** \brief Reply for enable / disable packet generator
2514 @param context - returned sender context, to match reply w/ request
2515 @param retval - return code
2517 define pg_enable_disable_reply
2523 /** \brief Configure IP source and L4 port-range check
2524 @param client_index - opaque cookie to identify the sender
2525 @param context - sender context, to match reply w/ request
2526 @param is_ip6 - 1 if source address type is IPv6
2527 @param is_add - 1 if add, 0 if delete
2528 @param mask_length - mask length for address entry
2529 @param address - array of address bytes
2530 @param number_of_ranges - length of low_port and high_port arrays (must match)
2531 @param low_ports[32] - up to 32 low end of port range entries (must have corresponding high_ports entry)
2532 @param high_ports[32] - up to 32 high end of port range entries (must have corresponding low_ports entry)
2533 @param vrf_id - fib table/vrf id to associate the source and port-range check with
2534 @note To specify a single port set low_port and high_port entry the same
2536 define ip_source_and_port_range_check_add_del
2544 u8 number_of_ranges;
2550 /** \brief Configure IP source and L4 port-range check reply
2551 @param context - returned sender context, to match reply w/ request
2552 @param retval - return code
2554 define ip_source_and_port_range_check_add_del_reply
2560 /** \brief Set interface source and L4 port-range request
2561 @param client_index - opaque cookie to identify the sender
2562 @param context - sender context, to match reply w/ request
2563 @param interface_id - interface index
2564 @param tcp_vrf_id - VRF associated with source and TCP port-range check
2565 @param udp_vrf_id - VRF associated with source and TCP port-range check
2567 define ip_source_and_port_range_check_interface_add_del
2579 /** \brief Set interface source and L4 port-range response
2580 @param context - sender context, to match reply w/ request
2581 @param retval - return value for request
2583 define ip_source_and_port_range_check_interface_add_del_reply
2589 /** \brief Delete sub interface request
2590 @param client_index - opaque cookie to identify the sender
2591 @param context - sender context, to match reply w/ request
2592 @param sw_if_index - sw index of the interface that was created by create_subif
2594 define delete_subif {
2600 /** \brief Delete sub interface response
2601 @param context - sender context, to match reply w/ request
2602 @param retval - return code for the request
2604 define delete_subif_reply {
2609 /** \brief DPDK interface HQoS pipe profile set request
2610 @param client_index - opaque cookie to identify the sender
2611 @param context - sender context, to match reply w/ request
2612 @param sw_if_index - the interface
2613 @param subport - subport ID
2614 @param pipe - pipe ID within its subport
2615 @param profile - pipe profile ID
2617 define sw_interface_set_dpdk_hqos_pipe {
2626 /** \brief DPDK interface HQoS pipe profile set reply
2627 @param context - sender context, to match reply w/ request
2628 @param retval - request return code
2630 define sw_interface_set_dpdk_hqos_pipe_reply {
2635 /** \brief DPDK interface HQoS subport parameters set request
2636 @param client_index - opaque cookie to identify the sender
2637 @param context - sender context, to match reply w/ request
2638 @param sw_if_index - the interface
2639 @param subport - subport ID
2640 @param tb_rate - subport token bucket rate (measured in bytes/second)
2641 @param tb_size - subport token bucket size (measured in credits)
2642 @param tc_rate - subport traffic class 0 .. 3 rates (measured in bytes/second)
2643 @param tc_period - enforcement period for rates (measured in milliseconds)
2645 define sw_interface_set_dpdk_hqos_subport {
2656 /** \brief DPDK interface HQoS subport parameters set reply
2657 @param context - sender context, to match reply w/ request
2658 @param retval - request return code
2660 define sw_interface_set_dpdk_hqos_subport_reply {
2665 /** \brief DPDK interface HQoS tctbl entry set request
2666 @param client_index - opaque cookie to identify the sender
2667 @param context - sender context, to match reply w/ request
2668 @param sw_if_index - the interface
2669 @param entry - entry index ID
2670 @param tc - traffic class (0 .. 3)
2671 @param queue - traffic class queue (0 .. 3)
2673 define sw_interface_set_dpdk_hqos_tctbl {
2682 /** \brief DPDK interface HQoS tctbl entry set reply
2683 @param context - sender context, to match reply w/ request
2684 @param retval - request return code
2686 define sw_interface_set_dpdk_hqos_tctbl_reply {
2691 /** \brief L2 interface pbb tag rewrite configure request
2692 @param client_index - opaque cookie to identify the sender
2693 @param context - sender context, to match reply w/ request
2694 @param sw_if_index - interface the operation is applied to
2695 @param vtr_op - Choose from l2_vtr_op_t enum values
2696 @param inner_tag - needed for translate_qinq vtr op only
2697 @param outer_tag - needed for translate_qinq vtr op only
2698 @param b_dmac - B-tag remote mac address, needed for any push or translate_qinq vtr op
2699 @param b_smac - B-tag local mac address, needed for any push or translate qinq vtr op
2700 @param b_vlanid - B-tag vlanid, needed for any push or translate qinq vtr op
2701 @param i_sid - I-tag service id, needed for any push or translate qinq vtr op
2703 define l2_interface_pbb_tag_rewrite
2716 /** \brief L2 interface pbb tag rewrite response
2717 @param context - sender context, to match reply w/ request
2718 @param retval - return code for the request
2720 define l2_interface_pbb_tag_rewrite_reply
2726 /** \brief Punt traffic to the host
2727 @param client_index - opaque cookie to identify the sender
2728 @param context - sender context, to match reply w/ request
2729 @param is_add - add punt if non-zero, else delete
2730 @param ipv - L3 protocol 4 - IPv4, 6 - IPv6, ~0 - All
2731 @param l4_protocol - L4 protocol to be punted, only UDP (0x11) is supported
2732 @param l4_port - TCP/UDP port to be punted
2743 /** \brief Reply to the punt request
2744 @param context - sender context which was passed in the request
2745 @param retval - return code of punt request
2753 /** \brief Feature path enable/disable request
2754 @param client_index - opaque cookie to identify the sender
2755 @param context - sender context, to match reply w/ request
2756 @param sw_if_index - the interface
2757 @param enable - 1 = on, 0 = off
2759 define feature_enable_disable {
2765 u8 feature_name[64];
2768 /** \brief Reply to the eature path enable/disable request
2769 @param context - sender context which was passed in the request
2770 @param retval - return code for the request
2772 define feature_enable_disable_reply
2780 * eval: (c-set-style "gnu")