Add vxlan-bypass feature to IP4 forwarding path
[vpp.git] / vpp / vpp-api / vpe.api
1 /* Hey Emacs use -*- mode: C -*- */
2 /*
3  * Copyright (c) 2015-2016 Cisco and/or its affiliates.
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at:
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 /** \file
18
19     This file defines vpe control-plane API messages which are generally
20     called through a shared memory interface. 
21 */
22
23
24 /** \brief Register for interface events
25     @param client_index - opaque cookie to identify the sender
26     @param context - sender context, to match reply w/ request
27     @param enable_disable - 1 => register for events, 0 => cancel registration
28     @param pid - sender's pid
29 */
30 define want_interface_events
31 {
32   u32 client_index;
33   u32 context;
34   u32 enable_disable;
35   u32 pid;
36 };
37
38 /** \brief Reply for interface events registration
39     @param context - returned sender context, to match reply w/ request
40     @param retval - return code
41 */
42 define want_interface_events_reply
43 {
44   u32 context;
45   i32 retval;
46 };
47
48 /** \brief Interface details structure (fix this) 
49     @param sw_if_index - index of the interface
50     @param sup_sw_if_index - index of parent interface if any, else same as sw_if_index  
51     @param l2_address_length - length of the interface's l2 address
52     @param pid - the interface's l2 address
53     @param interface_name - name of the interface
54     @param link_duplex - 1 if half duplex, 2 if full duplex
55     @param link_speed - 1 = 10M, 2 = 100M, 4 = 1G, 8 = 10G, 16 = 40G, 32 = 100G
56     @param link_MTU - max. transmittion unit 
57     @param sub_if_id - A number 0-N to uniquely identify this subif on super if
58     @param sub_dot1ad -  0 = dot1q, 1=dot1ad
59     @param sub_number_of_tags - Number of tags (0 - 2)
60     @param sub_outer_vlan_id
61     @param sub_inner_vlan_id
62     @param sub_exact_match
63     @param sub_default
64     @param sub_outer_vlan_id_any
65     @param sub_inner_vlan_id_any
66     @param vtr_op - vlan tag rewrite operation
67     @param vtr_push_dot1q
68     @param vtr_tag1
69     @param vtr_tag2
70 */
71 define sw_interface_details
72 {
73   u32 context;
74   u32 sw_if_index;
75
76   /* index of sup interface (e.g. hw interface).
77      equal to sw_if_index for super hw interface. */
78   u32 sup_sw_if_index;
79
80   /* Layer 2 address, if applicable */
81   u32 l2_address_length;
82   u8 l2_address[8];
83
84   /* Interface name */
85   u8 interface_name[64];
86
87   /* 1 = up, 0 = down */
88   u8 admin_up_down;
89   u8 link_up_down;
90
91   /* 1 = half duplex, 2 = full duplex */
92   u8 link_duplex;
93
94   /* 1 = 10M, 2 = 100M, 4 = 1G, 8 = 10G, 16 = 40G, 32 = 100G */
95   u8 link_speed;
96
97   /* MTU */
98   u16 link_mtu;
99
100   /* Subinterface ID. A number 0-N to uniquely identify this subinterface under the super interface */
101   u32 sub_id;
102
103   /* 0 = dot1q, 1=dot1ad */
104   u8 sub_dot1ad;
105
106   /* Number of tags 0-2 */
107   u8 sub_number_of_tags;
108   u16 sub_outer_vlan_id;
109   u16 sub_inner_vlan_id;
110   u8 sub_exact_match;
111   u8 sub_default;
112   u8 sub_outer_vlan_id_any;
113   u8 sub_inner_vlan_id_any;
114
115   /* vlan tag rewrite state */
116   u32 vtr_op;
117   u32 vtr_push_dot1q;           // ethertype of first pushed tag is dot1q/dot1ad
118   u32 vtr_tag1;                 // first pushed tag
119   u32 vtr_tag2;                 // second pushed tag
120 };
121
122 /* works */
123 define sw_interface_dump
124 {
125   u32 client_index;
126   u32 context;
127   u8 name_filter_valid;
128   u8 name_filter[49];
129 };
130
131 /** \brief Set or delete one or all ip addresses on a specified interface
132     @param client_index - opaque cookie to identify the sender
133     @param context - sender context, to match reply w/ request
134     @param sw_if_index - index of the interface to add/del addresses 
135     @param is_add - add address if non-zero, else delete
136     @param is_ipv6 - if non-zero the address is ipv6, else ipv4
137     @param del_all - if non-zero delete all addresses on the interface
138     @param address_length - address length in bytes, 4 for ip4, 16 for ip6
139     @param address - array of address bytes
140 */
141 define sw_interface_add_del_address
142 {
143   u32 client_index;
144   u32 context;
145   u32 sw_if_index;
146   u8 is_add;
147   u8 is_ipv6;
148   u8 del_all;
149   u8 address_length;
150   u8 address[16];
151 };
152
153 /** \brief Reply for interface events registration
154     @param context - returned sender context, to match reply w/ request
155     @param retval - return code
156 */
157 define sw_interface_add_del_address_reply
158 {
159   u32 context;
160   i32 retval;
161 };
162
163 /** \brief Associate the specified interface with a fib table
164     @param client_index - opaque cookie to identify the sender
165     @param context - sender context, to match reply w/ request
166     @param sw_if_index - index of the interface
167     @param is_ipv6 - if non-zero ipv6, else ipv4
168     @param vrf_id - fib table/vrd id to associate the interface with
169 */
170 define sw_interface_set_table
171 {
172   u32 client_index;
173   u32 context;
174   u32 sw_if_index;
175   u8 is_ipv6;
176   u32 vrf_id;
177 };
178
179 /** \brief Reply for interface events registration
180     @param context - returned sender context, to match reply w/ request
181     @param retval - return code
182 */
183 define sw_interface_set_table_reply
184 {
185   u32 context;
186   i32 retval;
187 };
188
189 /** \brief Enable or Disable MPLS on and interface
190     @param client_index - opaque cookie to identify the sender
191     @param context - sender context, to match reply w/ request
192     @param sw_if_index - index of the interface
193     @param enable - if non-zero enable, else disable
194 */
195 define sw_interface_set_mpls_enable
196 {
197   u32 client_index;
198   u32 context;
199   u32 sw_if_index;
200   u8 enable;
201 };
202
203 /** \brief Reply for MPLS state on an interface
204     @param context - returned sender context, to match reply w/ request
205     @param retval - return code
206 */
207 define sw_interface_set_mpls_enable_reply
208 {
209   u32 context;
210   i32 retval;
211 };
212
213 /** \brief Initialize a new tap interface with the given paramters 
214     @param client_index - opaque cookie to identify the sender
215     @param context - sender context, to match reply w/ request
216     @param use_random_mac - let the system generate a unique mac address
217     @param tap_name - name to associate with the new interface
218     @param mac_address - mac addr to assign to the interface if use_radom not set
219 */
220 define tap_connect
221 {
222   u32 client_index;
223   u32 context;
224   u8 use_random_mac;
225   u8 tap_name[64];
226   u8 mac_address[6];
227   u8 renumber;
228   u32 custom_dev_instance;
229 };
230
231 /** \brief Reply for tap connect request
232     @param context - returned sender context, to match reply w/ request
233     @param retval - return code
234     @param sw_if_index - software index allocated for the new tap interface
235 */
236 define tap_connect_reply
237 {
238   u32 context;
239   i32 retval;
240   u32 sw_if_index;
241 };
242
243 /** \brief Modify a tap interface with the given paramters 
244     @param client_index - opaque cookie to identify the sender
245     @param context - sender context, to match reply w/ request
246     @param sw_if_index - interface index of existing tap interface
247     @param use_random_mac - let the system generate a unique mac address
248     @param tap_name - name to associate with the new interface
249     @param mac_address - mac addr to assign to the interface if use_radom not set
250 */
251 define tap_modify
252 {
253   u32 client_index;
254   u32 context;
255   u32 sw_if_index;
256   u8 use_random_mac;
257   u8 tap_name[64];
258   u8 mac_address[6];
259   u8 renumber;
260   u32 custom_dev_instance;
261 };
262
263 /** \brief Reply for tap modify request
264     @param context - returned sender context, to match reply w/ request
265     @param retval - return code
266     @param sw_if_index - software index if the modified tap interface
267 */
268 define tap_modify_reply
269 {
270   u32 context;
271   i32 retval;
272   u32 sw_if_index;
273 };
274
275 /** \brief Delete tap interface
276     @param client_index - opaque cookie to identify the sender
277     @param context - sender context, to match reply w/ request
278     @param sw_if_index - interface index of existing tap interface
279 */
280 define tap_delete
281 {
282   u32 client_index;
283   u32 context;
284   u32 sw_if_index;
285 };
286
287 /** \brief Reply for tap delete request
288     @param context - returned sender context, to match reply w/ request
289     @param retval - return code
290 */
291 define tap_delete_reply
292 {
293   u32 context;
294   i32 retval;
295 };
296
297 /** \brief Dump tap interfaces request */
298 define sw_interface_tap_dump
299 {
300   u32 client_index;
301   u32 context;
302 };
303
304 /** \brief Reply for tap dump request
305     @param sw_if_index - software index of tap interface
306     @param dev_name - Linux tap device name
307 */
308 define sw_interface_tap_details
309 {
310   u32 context;
311   u32 sw_if_index;
312   u8 dev_name[64];
313 };
314
315 /** \brief Create a new subinterface with the given vlan id
316     @param client_index - opaque cookie to identify the sender
317     @param context - sender context, to match reply w/ request
318     @param sw_if_index - software index of the new vlan's parent interface
319     @param vlan_id - vlan tag of the new interface
320 */
321 define create_vlan_subif
322 {
323   u32 client_index;
324   u32 context;
325   u32 sw_if_index;
326   u32 vlan_id;
327 };
328
329 /** \brief Reply for the vlan subinterface create request
330     @param context - returned sender context, to match reply w/ request
331     @param retval - return code
332     @param sw_if_index - software index allocated for the new subinterface
333 */
334 define create_vlan_subif_reply
335 {
336   u32 context;
337   i32 retval;
338   u32 sw_if_index;
339 };
340
341 /** \brief MPLS Route Add / del route
342     @param client_index - opaque cookie to identify the sender
343     @param context - sender context, to match reply w/ request
344     @param mr_label - The MPLS label value
345     @param mr_eos - The End of stack bit
346     @param mr_table_id - The MPLS table-id the route is added in
347     @param mr_classify_table_index - If this is a classify route, 
348                                      this is the classify table index
349     @param  mr_create_table_if_needed - If the MPLS or IP tables do not exist,
350                                         create them
351     @param mr_is_add - Is this a route add or delete
352     @param mr_is_classify - Is this route result a classify
353     @param mr_is_multipath - Is this route update a multipath - i.e. is this
354                              a path addition to an existing route
355     @param mr_is_resolve_host - Recurse resolution constraint via a host prefix
356     @param mr_is_resolve_attached - Recurse resolution constraint via attached prefix
357     @param mr_next_hop_proto_is_ip4 - The next-hop is IPV4
358     @param mr_next_hop_weight - The weight, for UCMP
359     @param mr_next_hop[16] - the nextop address
360     @param mr_next_hop_sw_if_index - the next-hop SW interface
361     @param mr_next_hop_table_id - the next-hop table-id (if appropriate)
362     @param mr_next_hop_out_label - the next-hop output label
363 */
364 define mpls_route_add_del
365 {
366   u32 client_index;
367   u32 context;
368   u32 mr_label;
369   u8 mr_eos;
370   u32 mr_table_id;
371   u32 mr_classify_table_index;
372   u8 mr_create_table_if_needed;
373   u8 mr_is_add;
374   u8 mr_is_classify;
375   u8 mr_is_multipath;
376   u8 mr_is_resolve_host;
377   u8 mr_is_resolve_attached;
378   u8 mr_next_hop_proto_is_ip4;
379   u8 mr_next_hop_weight;
380   u8 mr_next_hop[16];
381   u32 mr_next_hop_sw_if_index;
382   u32 mr_next_hop_table_id;
383   u32 mr_next_hop_out_label;
384 };
385
386 /** \brief Reply for MPLS route add / del request
387     @param context - returned sender context, to match reply w/ request
388     @param retval - return code
389 */
390 define mpls_route_add_del_reply
391 {
392   u32 context;
393   i32 retval;
394 };
395
396 /** \brief Dump MPLS fib table
397     @param client_index - opaque cookie to identify the sender
398 */
399 define mpls_fib_dump
400 {
401   u32 client_index;
402   u32 context;
403 };
404
405 /** \brief FIB path
406     @param sw_if_index - index of the interface
407     @param weight - The weight, for UCMP
408     @param is_local - local if non-zero, else remote
409     @param is_drop - Drop the packet
410     @param is_unreach - Drop the packet and rate limit send ICMP unreachable
411     @param is_prohibit - Drop the packet and rate limit send ICMP prohibited
412     @param afi - the afi of the next hop, IP46_TYPE_IP4=1, IP46_TYPE_IP6=2
413     @param next_hop[16] - the next hop address
414 */
415 typeonly manual_print manual_endian define fib_path
416 {
417   u32 sw_if_index;
418   u32 weight;
419   u8 is_local;
420   u8 is_drop;
421   u8 is_unreach;
422   u8 is_prohibit;
423   u8 afi;
424   u8 next_hop[16];
425 };
426
427 /** \brief mpls FIB table response
428     @param table_id - MPLS fib table id
429     @param s_bit - End-of-stack bit
430     @param label - MPLS label value
431     @param count - the number of fib_path in path
432     @param path  - array of of fib_path structures
433 */
434 manual_endian manual_print define mpls_fib_details
435 {
436   u32 context;
437   u32 table_id;
438   u8  eos_bit;
439   u32 label;
440   u32 count;
441   vl_api_fib_path_t path[count];
442 };
443
444 /** \brief Dump IP6 fib table
445     @param client_index - opaque cookie to identify the sender
446 */
447 define ip6_fib_dump
448 {
449   u32 client_index;
450   u32 context;
451 };
452
453 /** \brief IP6 FIB table response
454     @param table_id - IP6 fib table id
455     @address_length - mask length
456     @address - ip6 prefix
457     @param count - the number of fib_path in path
458     @param path  - array of of fib_path structures
459 */
460 manual_endian manual_print define ip6_fib_details
461 {
462   u32 context;
463   u32 table_id;
464   u8  address_length;
465   u8  address[16];
466   u32 count;
467   vl_api_fib_path_t path[count];
468 };
469
470 /** \brief Dump IP fib table
471     @param client_index - opaque cookie to identify the sender
472 */
473 define ip_fib_dump
474 {
475   u32 client_index;
476   u32 context;
477 };
478
479 /** \brief IP FIB table response
480     @param table_id - IP fib table id
481     @address_length - mask length
482     @address - ip4 prefix
483     @param count - the number of fib_path in path
484     @param path  - array of of fib_path structures
485 */
486 manual_endian manual_print define ip_fib_details
487 {
488   u32 context;
489   u32 table_id;
490   u8  address_length;
491   u8  address[4];
492   u32 count;
493   vl_api_fib_path_t path[count];
494 };
495
496 /** \brief Bind/Unbind an MPLS local label to an IP prefix. i.e. create
497            a per-prefix label entry.
498     @param client_index - opaque cookie to identify the sender
499     @param context - sender context, to match reply w/ request
500     @param mb_mpls_table_id - The MPLS table-id the MPLS entry will be added in
501     @param mb_label - The MPLS label value to bind
502     @param mb_ip_table_id - The IP table-id of the IP prefix to bind to.
503     @param mb_create_table_if_needed - Create either/both tables if required.
504     @param mb_is_bind - Bind or unbind
505     @param mb_is_ip4 - The prefix to bind to is IPv4
506     @param mb_address_length - Length of IP prefix
507     @param mb_address[16] - IP prefix/
508 */
509 define mpls_ip_bind_unbind
510 {
511   u32 client_index;
512   u32 context;
513   u32 mb_mpls_table_id;
514   u32 mb_label;
515   u32 mb_ip_table_id;
516   u8 mb_create_table_if_needed;
517   u8 mb_is_bind;
518   u8 mb_is_ip4;
519   u8 mb_address_length;
520   u8 mb_address[16];
521 };
522
523 /** \brief Reply for MPLS IP bind/unbind request
524     @param context - returned sender context, to match reply w/ request
525     @param retval - return code
526 */
527 define mpls_ip_bind_unbind_reply
528 {
529   u32 context;
530   i32 retval;
531 };
532
533 /** \brief Add / del route request
534     @param client_index - opaque cookie to identify the sender
535     @param context - sender context, to match reply w/ request
536     @param sw_if_index - software index of the new vlan's parent interface
537     @param vrf_id - fib table /vrf associated with the route
538     @param lookup_in_vrf - 
539     @param resolve_attempts - 
540     @param classify_table_index - 
541     @param create_vrf_if_needed - 
542     @param resolve_if_needed - 
543     @param is_add - 1 if adding the route, 0 if deleting
544     @param is_drop - Drop the packet
545     @param is_unreach - Drop the packet and rate limit send ICMP unreachable
546     @param is_prohibit - Drop the packet and rate limit send ICMP prohibited
547     @param is_ipv6 - 0 if an ip4 route, else ip6
548     @param is_local - 
549     @param is_classify - 
550     @param is_multipath - Set to 1 if this is a multipath route, else 0
551     @param not_last - Is last or not last msg in group of multiple add/del msgs
552     @param next_hop_weight - 
553     @param dst_address_length - 
554     @param dst_address[16] - 
555     @param next_hop_address[16] - 
556 */
557 define ip_add_del_route
558 {
559   u32 client_index;
560   u32 context;
561   u32 next_hop_sw_if_index;
562   u32 table_id;
563   u32 resolve_attempts;
564   u32 classify_table_index;
565   u32 next_hop_out_label;
566   u32 next_hop_table_id;
567   u8 create_vrf_if_needed;
568   u8 resolve_if_needed;
569   u8 is_add;
570   u8 is_drop;
571   u8 is_unreach;
572   u8 is_prohibit;
573   u8 is_ipv6;
574   u8 is_local;
575   u8 is_classify;
576   u8 is_multipath;
577   u8 is_resolve_host;
578   u8 is_resolve_attached;
579   /* Is last/not-last message in group of multiple add/del messages. */
580   u8 not_last;
581   u8 next_hop_weight;
582   u8 dst_address_length;
583   u8 dst_address[16];
584   u8 next_hop_address[16];
585 };
586
587 /** \brief Reply for add / del route request
588     @param context - returned sender context, to match reply w/ request
589     @param retval - return code
590 */
591 define ip_add_del_route_reply
592 {
593   u32 context;
594   i32 retval;
595 };
596
597 /** \brief Add / del MPLS encapsulation request
598     @param client_index - opaque cookie to identify the sender
599     @param context - sender context, to match reply w/ request
600     @param vrf_id - vrf id
601     @param dst_address[4] - 
602     @param is_add - 1 if adding the encap, 0 if deleting
603     @param nlabels - number of labels 
604     @param labels - array of labels
605 */
606 define mpls_add_del_encap
607 {
608   u32 client_index;
609   u32 context;
610   u32 vrf_id;
611   u8 dst_address[4];
612   /* 1 = add, 0 = delete */
613   u8 is_add;
614   u8 nlabels;
615   u32 labels[0];
616 };
617
618 /** \brief Reply for add / del encapsulation request
619     @param context - returned sender context, to match reply w/ request
620     @param retval - return code
621 */
622 define mpls_add_del_encap_reply
623 {
624   u32 context;
625   i32 retval;
626 };
627
628 /** \brief Proxy ARP add / del request
629     @param client_index - opaque cookie to identify the sender
630     @param context - sender context, to match reply w/ request
631     @param vrf_id - VRF / Fib table ID
632     @param is_add - 1 if adding the Proxy ARP range, 0 if deleting
633     @param low_address[4] - Low address of the Proxy ARP range
634     @param hi_address[4] - High address of the Proxy ARP range
635 */
636 define proxy_arp_add_del
637 {
638   u32 client_index;
639   u32 context;
640   u32 vrf_id;
641   u8 is_add;
642   u8 low_address[4];
643   u8 hi_address[4];
644 };
645
646 /** \brief Reply for proxy arp add / del request
647     @param context - returned sender context, to match reply w/ request
648     @param retval - return code
649 */
650 define proxy_arp_add_del_reply
651 {
652   u32 context;
653   i32 retval;
654 };
655
656 /** \brief Proxy ARP add / del request
657     @param client_index - opaque cookie to identify the sender
658     @param context - sender context, to match reply w/ request
659     @param sw_if_index - Which interface to enable / disable Proxy Arp on
660     @param enable_disable - 1 to enable Proxy ARP on interface, 0 to disable
661 */
662 define proxy_arp_intfc_enable_disable
663 {
664   u32 client_index;
665   u32 context;
666   u32 sw_if_index;
667   /* 1 = on, 0 = off */
668   u8 enable_disable;
669 };
670
671 /** \brief Reply for Proxy ARP interface enable / disable request
672     @param context - returned sender context, to match reply w/ request
673     @param retval - return code
674 */
675 define proxy_arp_intfc_enable_disable_reply
676 {
677   u32 context;
678   i32 retval;
679 };
680
681 /** \brief IP neighbor add / del request
682     @param client_index - opaque cookie to identify the sender
683     @param context - sender context, to match reply w/ request
684     @param vrf_id - vrf_id, only for IP4
685     @param sw_if_index - interface used to reach neighbor
686     @param is_add - 1 to add neighbor, 0 to delete
687     @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
688     @param is_static - 
689     @param mac_address - l2 address of the neighbor
690     @param dst_address - ip4 or ip6 address of the neighbor
691 */
692 define ip_neighbor_add_del
693 {
694   u32 client_index;
695   u32 context;
696   u32 vrf_id;                   /* only makes sense for ip4 */
697   u32 sw_if_index;
698   /* 1 = add, 0 = delete */
699   u8 is_add;
700   u8 is_ipv6;
701   u8 is_static;
702   u8 mac_address[6];
703   u8 dst_address[16];
704 };
705
706 /** \brief Reply for IP Neighbor add / delete request
707     @param context - returned sender context, to match reply w/ request
708     @param retval - return code
709 */
710 define ip_neighbor_add_del_reply
711 {
712   u32 context;
713   i32 retval;
714 };
715
716 /** \brief Reset VRF (remove all routes etc) request
717     @param client_index - opaque cookie to identify the sender
718     @param context - sender context, to match reply w/ request
719     @param is_ipv6 - 1 for IPv6 neighbor, 0 for IPv4
720     @param vrf_id - ID of th FIB table / VRF to reset
721 */
722 define reset_vrf
723 {
724   u32 client_index;
725   u32 context;
726   u8 is_ipv6;
727   u32 vrf_id;
728 };
729
730 /** \brief Reply for Reset VRF request
731     @param context - returned sender context, to match reply w/ request
732     @param retval - return code
733 */
734 define reset_vrf_reply
735 {
736   u32 context;
737   i32 retval;
738 };
739
740 /** \brief Is Address Reachable request - DISABLED
741     @param client_index - opaque cookie to identify the sender
742     @param context - sender context, to match reply w/ request
743     @param next_hop_sw_if_index - index of interface used to get to next hop
744     @param is_ipv6 - 1 for IPv6, 0 for IPv4
745     @param is_error - address not found or does not match intf
746     @param address[] - Address in question 
747 */
748 define is_address_reachable
749 {
750   u32 client_index;             /* (api_main_t *) am->my_client_index */
751   u32 context;
752   u32 next_hop_sw_if_index;
753   u8 is_known;                  /* on reply, this is the answer */
754   u8 is_ipv6;
755   u8 is_error;                  /* address not found or does not match intf */
756   u8 address[16];
757 };
758
759 /** \brief Want Stats, register for stats updates
760     @param client_index - opaque cookie to identify the sender
761     @param context - sender context, to match reply w/ request
762     @param enable_disable - 1 = enable stats, 0 = disable
763     @param pid - pid of process requesting stats updates
764 */
765 define want_stats
766 {
767   u32 client_index;
768   u32 context;
769   u32 enable_disable;
770   u32 pid;
771 };
772
773 /** \brief Reply for Want Stats request
774     @param context - returned sender context, to match reply w/ request
775     @param retval - return code
776 */
777 define want_stats_reply
778 {
779   u32 context;
780   i32 retval;
781 };
782
783 /** \brief Want stats counters structure 
784     @param vnet_counter_type- such as ip4, ip6, punts, etc
785     @param is_combined - rx & tx total (all types) counts   
786     @param first_sw_if_index - first sw index in block of index, counts
787     @param count - number of interfaces this stats block includes counters for
788     @param data - contiguous block of vlib_counter_t structures 
789 */
790 define vnet_interface_counters
791 {
792   /* enums - plural - in vnet/interface.h */
793   u8 vnet_counter_type;
794   u8 is_combined;
795   u32 first_sw_if_index;
796   u32 count;
797   u8 data[count];
798 };
799
800 typeonly manual_print manual_endian define ip4_fib_counter
801 {
802   u32 address;
803   u8 address_length;
804   u64 packets;
805   u64 bytes;
806 };
807
808 manual_print manual_endian define vnet_ip4_fib_counters
809 {
810   u32 vrf_id;
811   u32 count;
812   vl_api_ip4_fib_counter_t c[count];
813 };
814
815 typeonly manual_print manual_endian define ip6_fib_counter
816 {
817   u64 address[2];
818   u8 address_length;
819   u64 packets;
820   u64 bytes;
821 };
822
823 manual_print manual_endian define vnet_ip6_fib_counters
824 {
825   u32 vrf_id;
826   u32 count;
827   vl_api_ip6_fib_counter_t c[count];
828 };
829
830 /** \brief Request for a single block of summary stats
831     @param client_index - opaque cookie to identify the sender
832     @param context - sender context, to match reply w/ request
833 */
834 define vnet_get_summary_stats
835 {
836   u32 client_index;
837   u32 context;
838 };
839
840 /** \brief Reply for vnet_get_summary_stats request
841     @param context - sender context, to match reply w/ request
842     @param retval - return code for request
843     @param total_pkts -  
844     @param total_bytes -
845     @param vector_rate - 
846 */
847 define vnet_summary_stats_reply
848 {
849   u32 context;
850   i32 retval;
851   u64 total_pkts[2];
852   u64 total_bytes[2];
853   f64 vector_rate;
854 };
855
856 /** \brief OAM event structure
857     @param dst_address[] - 
858     @param state
859 */
860 define oam_event
861 {
862   u8 dst_address[4];
863   u8 state;
864 };
865
866 /** \brief Want OAM events request
867     @param client_index - opaque cookie to identify the sender
868     @param context - sender context, to match reply w/ request
869     @param enable_disable- enable if non-zero, else disable
870     @param pid - pid of the requesting process
871 */
872 define want_oam_events
873 {
874   u32 client_index;
875   u32 context;
876   u32 enable_disable;
877   u32 pid;
878 };
879
880 /** \brief Want OAM events response
881     @param context - sender context, to match reply w/ request
882     @param retval - return code for the want oam stats request
883 */
884 define want_oam_events_reply
885 {
886   u32 context;
887   i32 retval;
888 };
889
890 /** \brief OAM add / del target request
891     @param client_index - opaque cookie to identify the sender
892     @param context - sender context, to match reply w/ request
893     @param vrf_id - vrf_id of the target
894     @param src_address[] - source address to use for the updates 
895     @param dst_address[] - destination address of the target
896     @param is_add - add target if non-zero, else delete
897 */
898 define oam_add_del
899 {
900   u32 client_index;
901   u32 context;
902   u32 vrf_id;
903   u8 src_address[4];
904   u8 dst_address[4];
905   u8 is_add;
906 };
907
908 /** \brief OAM add / del target response
909     @param context - sender context, to match reply w/ request
910     @param retval - return code of the request
911 */
912 define oam_add_del_reply
913 {
914   u32 context;
915   i32 retval;
916 };
917
918 /** \brief Reset fib table request
919     @param client_index - opaque cookie to identify the sender
920     @param context - sender context, to match reply w/ request
921     @param vrf_id - vrf/table id of the fib table to reset
922     @param is_ipv6 - an ipv6 fib to reset if non-zero, else ipv4
923 */
924 define reset_fib
925 {
926   u32 client_index;
927   u32 context;
928   u32 vrf_id;
929   u8 is_ipv6;
930 };
931
932 /** \brief Reset fib response
933     @param context - sender context, to match reply w/ request
934     @param retval - return code for the reset bfib request
935 */
936 define reset_fib_reply
937 {
938   u32 context;
939   i32 retval;
940 };
941
942 /** \brief DHCP Proxy config add / del request
943     @param client_index - opaque cookie to identify the sender
944     @param context - sender context, to match reply w/ request
945     @param vrf_id - vrf id
946     @param if_ipv6 - ipv6 if non-zero, else ipv4
947     @param is_add - add the config if non-zero, else delete
948     @param insert_circuit_id - option82 suboption 1 fib number
949     @param dhcp_server[] - server address
950     @param dhcp_src_address[] - <fix this, need details>
951 */
952 define dhcp_proxy_config
953 {
954   u32 client_index;
955   u32 context;
956   u32 vrf_id;
957   u8 is_ipv6;
958   u8 is_add;
959   u8 insert_circuit_id;
960   u8 dhcp_server[16];
961   u8 dhcp_src_address[16];
962 };
963
964 /** \brief DHCP Proxy config response
965     @param context - sender context, to match reply w/ request
966     @param retval - return code for the request
967 */
968 define dhcp_proxy_config_reply
969 {
970   u32 context;
971   i32 retval;
972 };
973
974 /** \brief DHCP Proxy set / unset vss request
975     @param client_index - opaque cookie to identify the sender
976     @param context - sender context, to match reply w/ request
977     @param tbl_id - table id
978     @param oui - first part of vpn id
979     @param fib_id - second part of vpn id
980     @param is_ipv6 - ip6 if non-zero, else ip4
981     @param is_add - set vss if non-zero, else delete
982 */
983 define dhcp_proxy_set_vss
984 {
985   u32 client_index;
986   u32 context;
987   u32 tbl_id;
988   u32 oui;
989   u32 fib_id;
990   u8 is_ipv6;
991   u8 is_add;
992 };
993
994 /** \brief DHCP proxy set / unset vss response
995     @param context - sender context, to match reply w/ request
996     @param retval - return code for the request
997 */
998 define dhcp_proxy_set_vss_reply
999 {
1000   u32 context;
1001   i32 retval;
1002 };
1003
1004 /** \brief Set the ip flow hash config for a fib request
1005     @param client_index - opaque cookie to identify the sender
1006     @param context - sender context, to match reply w/ request
1007     @param vrf_id - vrf/fib id
1008     @param is_ipv6 - if non-zero the fib is ip6, else ip4
1009     @param src - if non-zero include src in flow hash
1010     @param dst - if non-zero include dst in flow hash
1011     @param sport - if non-zero include sport in flow hash
1012     @param dport - if non-zero include dport in flow hash
1013     @param proto -if non-zero include proto in flow hash
1014     @param reverse - if non-zero include reverse in flow hash
1015 */
1016 define set_ip_flow_hash
1017 {
1018   u32 client_index;
1019   u32 context;
1020   u32 vrf_id;
1021   u8 is_ipv6;
1022   u8 src;
1023   u8 dst;
1024   u8 sport;
1025   u8 dport;
1026   u8 proto;
1027   u8 reverse;
1028 };
1029
1030 /** \brief Set the ip flow hash config for a fib response
1031     @param context - sender context, to match reply w/ request
1032     @param retval - return code for the request
1033 */
1034 define set_ip_flow_hash_reply
1035 {
1036   u32 context;
1037   i32 retval;
1038 };
1039
1040 /** \brief IPv6 router advertisement config request
1041     @param client_index - opaque cookie to identify the sender
1042     @param context - sender context, to match reply w/ request
1043     @param suppress -
1044     @param managed -
1045     @param other -
1046     @param ll_option -
1047     @param send_unicast -
1048     @param cease -
1049     @param is_no -
1050     @param default_router -
1051     @param max_interval -
1052     @param min_interval -
1053     @param lifetime -
1054     @param initial_count -
1055     @param initial_interval -
1056 */
1057 define sw_interface_ip6nd_ra_config
1058 {
1059   u32 client_index;
1060   u32 context;
1061   u32 sw_if_index;
1062   u8 suppress;
1063   u8 managed;
1064   u8 other;
1065   u8 ll_option;
1066   u8 send_unicast;
1067   u8 cease;
1068   u8 is_no;
1069   u8 default_router;
1070   u32 max_interval;
1071   u32 min_interval;
1072   u32 lifetime;
1073   u32 initial_count;
1074   u32 initial_interval;
1075 };
1076
1077 /** \brief IPv6 router advertisement config response
1078     @param context - sender context, to match reply w/ request
1079     @param retval - return code for the request
1080 */
1081 define sw_interface_ip6nd_ra_config_reply
1082 {
1083   u32 context;
1084   i32 retval;
1085 };
1086
1087 /** \brief IPv6 router advertisement prefix config request
1088     @param client_index - opaque cookie to identify the sender
1089     @param context - sender context, to match reply w/ request
1090     @param sw_if_index - 
1091     @param address[] -
1092     @param address_length -
1093     @param use_default -
1094     @param no_advertise -
1095     @param off_link -
1096     @param no_autoconfig -
1097     @param no_onlink -
1098     @param is_no -
1099     @param val_lifetime -
1100     @param pref_lifetime -
1101 */
1102 define sw_interface_ip6nd_ra_prefix
1103 {
1104   u32 client_index;
1105   u32 context;
1106   u32 sw_if_index;
1107   u8 address[16];
1108   u8 address_length;
1109   u8 use_default;
1110   u8 no_advertise;
1111   u8 off_link;
1112   u8 no_autoconfig;
1113   u8 no_onlink;
1114   u8 is_no;
1115   u32 val_lifetime;
1116   u32 pref_lifetime;
1117 };
1118
1119 /** \brief IPv6 router advertisement prefix config response
1120     @param context - sender context, to match reply w/ request
1121     @param retval - return code for the request
1122 */
1123 define sw_interface_ip6nd_ra_prefix_reply
1124 {
1125   u32 context;
1126   i32 retval;
1127 };
1128
1129 /** \brief IPv6 interface enable / disable request
1130     @param client_index - opaque cookie to identify the sender
1131     @param context - sender context, to match reply w/ request
1132     @param sw_if_index - interface used to reach neighbor
1133     @param enable - if non-zero enable ip6 on interface, else disable
1134 */
1135 define sw_interface_ip6_enable_disable
1136 {
1137   u32 client_index;
1138   u32 context;
1139   u32 sw_if_index;
1140   u8 enable;                    /* set to true if enable */
1141 };
1142
1143 /** \brief IPv6 interface enable / disable response
1144     @param context - sender context, to match reply w/ request
1145     @param retval - return code for the request
1146 */
1147 define sw_interface_ip6_enable_disable_reply
1148 {
1149   u32 context;
1150   i32 retval;
1151 };
1152
1153 /** \brief IPv6 set link local address on interface request
1154     @param client_index - opaque cookie to identify the sender
1155     @param context - sender context, to match reply w/ request
1156     @param sw_if_index - interface to set link local on
1157     @param address[] - the new link local address
1158     @param address_length - link local address length
1159 */
1160 define sw_interface_ip6_set_link_local_address
1161 {
1162   u32 client_index;
1163   u32 context;
1164   u32 sw_if_index;
1165   u8 address[16];
1166   u8 address_length;
1167 };
1168
1169 /** \brief IPv6 set link local address on interface response
1170     @param context - sender context, to match reply w/ request
1171     @param retval - error code for the request
1172 */
1173 define sw_interface_ip6_set_link_local_address_reply
1174 {
1175   u32 context;
1176   i32 retval;
1177 };
1178
1179 /** \brief Set unnumbered interface add / del request
1180     @param client_index - opaque cookie to identify the sender
1181     @param context - sender context, to match reply w/ request
1182     @param sw_if_index - interface with an IP address
1183     @param unnumbered_sw_if_index - interface which will use the address
1184     @param is_add - if non-zero set the association, else unset it
1185 */
1186 define sw_interface_set_unnumbered
1187 {
1188   u32 client_index;
1189   u32 context;
1190   u32 sw_if_index;              /* use this intfc address */
1191   u32 unnumbered_sw_if_index;   /* on this interface */
1192   u8 is_add;
1193 };
1194
1195 /** \brief Set unnumbered interface add / del response
1196     @param context - sender context, to match reply w/ request
1197     @param retval - return code for the request
1198 */
1199 define sw_interface_set_unnumbered_reply
1200 {
1201   u32 context;
1202   i32 retval;
1203 };
1204
1205 /** \brief Create loopback interface request
1206     @param client_index - opaque cookie to identify the sender
1207     @param context - sender context, to match reply w/ request
1208     @param mac_address - mac addr to assign to the interface if none-zero
1209 */
1210 define create_loopback
1211 {
1212   u32 client_index;
1213   u32 context;
1214   u8 mac_address[6];
1215 };
1216
1217 /** \brief Create loopback interface response
1218     @param context - sender context, to match reply w/ request
1219     @param sw_if_index - sw index of the interface that was created
1220     @param retval - return code for the request
1221 */
1222 define create_loopback_reply
1223 {
1224   u32 context;
1225   i32 retval;
1226   u32 sw_if_index;
1227 };
1228
1229 /** \brief Delete loopback interface request
1230     @param client_index - opaque cookie to identify the sender
1231     @param context - sender context, to match reply w/ request
1232     @param sw_if_index - sw index of the interface that was created
1233 */
1234 define delete_loopback
1235 {
1236   u32 client_index;
1237   u32 context;
1238   u32 sw_if_index;
1239 };
1240
1241 /** \brief Delete loopback interface response
1242     @param context - sender context, to match reply w/ request
1243     @param retval - return code for the request
1244 */
1245 define delete_loopback_reply
1246 {
1247   u32 context;
1248   i32 retval;
1249 };
1250
1251 /** \brief Control ping from client to api server request
1252     @param client_index - opaque cookie to identify the sender
1253     @param context - sender context, to match reply w/ request
1254 */
1255 define control_ping
1256 {
1257   u32 client_index;
1258   u32 context;
1259 };
1260
1261 /** \brief Control ping from the client to the server response
1262     @param client_index - opaque cookie to identify the sender
1263     @param context - sender context, to match reply w/ request
1264     @param retval - return code for the request
1265     @param vpe_pid - the pid of the vpe, returned by the server
1266 */
1267 define control_ping_reply
1268 {
1269   u32 context;
1270   i32 retval;
1271   u32 client_index;
1272   u32 vpe_pid;
1273 };
1274
1275 /** \brief Process a vpe parser cli string request
1276     @param client_index - opaque cookie to identify the sender
1277     @param context - sender context, to match reply w/ request
1278     @param cmd_in_shmem - pointer to cli command string
1279 */
1280 define cli_request
1281 {
1282   u32 client_index;
1283   u32 context;
1284   u64 cmd_in_shmem;
1285 };
1286 define cli_inband
1287 {
1288   u32 client_index;
1289   u32 context;
1290   u32 length;
1291   u8 cmd[length];
1292 };
1293
1294 /** \brief vpe parser cli string response
1295     @param context - sender context, to match reply w/ request
1296     @param retval - return code for request
1297     @param reply_in_shmem - Reply string from cli processing if any
1298 */
1299 define cli_reply
1300 {
1301   u32 context;
1302   i32 retval;
1303   u64 reply_in_shmem;
1304 };
1305 define cli_inband_reply
1306 {
1307   u32 context;
1308   i32 retval;
1309   u32 length;
1310   u8 reply[length];
1311 };
1312
1313 /** \brief Set max allowed ARP or ip6 neighbor entries request
1314     @param client_index - opaque cookie to identify the sender
1315     @param context - sender context, to match reply w/ request
1316     @param is_ipv6 - neighbor limit if non-zero, else ARP limit
1317     @param arp_neighbor_limit - the new limit, defaults are ~ 50k
1318 */
1319 define set_arp_neighbor_limit
1320 {
1321   u32 client_index;
1322   u32 context;
1323   u8 is_ipv6;
1324   u32 arp_neighbor_limit;
1325 };
1326
1327 /** \brief Set max allowed ARP or ip6 neighbor entries response
1328     @param context - sender context, to match reply w/ request
1329     @param retval - return code for request
1330 */
1331 define set_arp_neighbor_limit_reply
1332 {
1333   u32 context;
1334   i32 retval;
1335 };
1336
1337 /** \brief L2 interface patch add / del request
1338     @param client_index - opaque cookie to identify the sender
1339     @param context - sender context, to match reply w/ request
1340     @param rx_sw_if_index - receive side interface 
1341     @param tx_sw_if_index - transmit side interface
1342     @param is_add - if non-zero set up the interface patch, else remove it
1343 */
1344 define l2_patch_add_del
1345 {
1346   u32 client_index;
1347   u32 context;
1348   u32 rx_sw_if_index;
1349   u32 tx_sw_if_index;
1350   u8 is_add;
1351 };
1352
1353 /** \brief L2 interface patch add / del response
1354     @param context - sender context, to match reply w/ request
1355     @param retval - return code for the request
1356 */
1357 define l2_patch_add_del_reply
1358 {
1359   u32 context;
1360   i32 retval;
1361 };
1362
1363 /** \brief IPv6 segment routing tunnel add / del request
1364     @param client_index - opaque cookie to identify the sender
1365     @param context - sender context, to match reply w/ request
1366     @param is_add - add the tunnel if non-zero, else delete it
1367     @param name[] - tunnel name (len. 64)
1368     @param src_address[] -
1369     @param dst_address[] -
1370     @param dst_mask_width -
1371     @param inner_vrf_id -
1372     @param outer_vrf_id -
1373     @param flags_net_byte_order -
1374     @param n_segments -
1375     @param n_tags -
1376     @param segs_and_tags[] -
1377     @param policy_name[] - name of policy to associate this tunnel to (len. 64)
1378 */
1379 define sr_tunnel_add_del
1380 {
1381   u32 client_index;
1382   u32 context;
1383   u8 is_add;
1384   u8 name[64];
1385   u8 src_address[16];
1386   u8 dst_address[16];
1387   u8 dst_mask_width;
1388   u32 inner_vrf_id;
1389   u32 outer_vrf_id;
1390   u16 flags_net_byte_order;
1391   u8 n_segments;
1392   u8 n_tags;
1393   u8 segs_and_tags[0];
1394   u8 policy_name[64];
1395 };
1396
1397 /** \brief IPv6 segment routing tunnel add / del response
1398     @param context - sender context, to match reply w/ request
1399     @param retval - return value for request
1400 */
1401 define sr_tunnel_add_del_reply
1402 {
1403   u32 context;
1404   i32 retval;
1405 };
1406
1407 /** \brief IPv6 segment routing policy add / del request
1408     @param client_index - opaque cookie to identify the sender
1409     @param context - sender context, to match reply w/ request
1410     @param is_add - add the tunnel if non-zero, else delete it
1411     @param name[] - policy name (len. 64)
1412     @param tunnel_names[] -
1413 */
1414 define sr_policy_add_del
1415 {
1416   u32 client_index;
1417   u32 context;
1418   u8 is_add;
1419   u8 name[64];
1420   u8 tunnel_names[0];
1421 };
1422
1423 /** \brief IPv6 segment routing policy add / del response
1424     @param context - sender context, to match reply w/ request
1425     @param retval - return value for request
1426 */
1427 define sr_policy_add_del_reply
1428 {
1429   u32 context;
1430   i32 retval;
1431 };
1432
1433 /** \brief IPv6 segment routing multicast map to policy add / del request
1434     @param client_index - opaque cookie to identify the sender
1435     @param context - sender context, to match reply w/ request
1436     @param is_add - add the tunnel if non-zero, else delete it
1437     @param multicast_address[] - IP6 multicast address
1438     @param policy_name[] = policy name (len.64)
1439 */
1440 define sr_multicast_map_add_del
1441 {
1442   u32 client_index;
1443   u32 context;
1444   u8 is_add;
1445   u8 multicast_address[16];
1446   u8 policy_name[64];
1447 };
1448
1449 /** \brief IPv6 segment routing multicast map to policy add / del response
1450     @param context - sender context, to match reply w/ request
1451     @param retval - return value for request
1452 */
1453 define sr_multicast_map_add_del_reply
1454 {
1455   u32 context;
1456   i32 retval;
1457 };
1458
1459 /** \brief Interface set vpath request
1460     @param client_index - opaque cookie to identify the sender
1461     @param context - sender context, to match reply w/ request
1462     @param sw_if_index - interface used to reach neighbor
1463     @param enable - if non-zero enable, else disable
1464 */
1465 define sw_interface_set_vpath
1466 {
1467   u32 client_index;
1468   u32 context;
1469   u32 sw_if_index;
1470   u8 enable;
1471 };
1472
1473 /** \brief Interface set vpath response
1474     @param context - sender context, to match reply w/ request
1475     @param retval - return code for the request
1476 */
1477 define sw_interface_set_vpath_reply
1478 {
1479   u32 context;
1480   i32 retval;
1481 };
1482
1483 /** \brief Interface set vxlan-bypass request
1484     @param client_index - opaque cookie to identify the sender
1485     @param context - sender context, to match reply w/ request
1486     @param sw_if_index - interface used to reach neighbor
1487     @param is_ipv6 - if non-zero, enable ipv6-vxlan-bypass, else ipv4-vxlan-bypass
1488     @param enable - if non-zero enable, else disable
1489 */
1490 define sw_interface_set_vxlan_bypass
1491 {
1492   u32 client_index;
1493   u32 context;
1494   u32 sw_if_index;
1495   u8 is_ipv6;
1496   u8 enable;
1497 };
1498
1499 /** \brief Interface set vxlan-bypass response
1500     @param context - sender context, to match reply w/ request
1501     @param retval - return code for the request
1502 */
1503 define sw_interface_set_vxlan_bypass_reply
1504 {
1505   u32 context;
1506   i32 retval;
1507 };
1508
1509 /** \brief MPLS Ethernet add / del tunnel request
1510     @param client_index - opaque cookie to identify the sender
1511     @param context - sender context, to match reply w/ request
1512     @param vrf_id - vrf_id, only for IP4
1513     @param sw_if_index - interface used to reach neighbor
1514     @param is_add - add if set, tunnel delete if 0
1515     @param dst_mac_address - 
1516     @param adj_address - 
1517     @param adj_address_length -
1518 */
1519 define mpls_ethernet_add_del_tunnel
1520 {
1521   u32 client_index;
1522   u32 context;
1523   u32 vrf_id;
1524   u32 tx_sw_if_index;
1525   u8 is_add;
1526   u8 l2_only;
1527   u8 dst_mac_address[6];
1528   u8 adj_address[4];
1529   u8 adj_address_length;
1530 };
1531
1532 /** \brief Reply for MPLS Ethernet add / delete tunnel request
1533     @param context - sender context, to match reply w/ request
1534     @param retval - return code for the request
1535 */
1536 define mpls_ethernet_add_del_tunnel_reply
1537 {
1538   u32 context;
1539   i32 retval;
1540   u32 tunnel_sw_if_index;
1541 };
1542 /** \brief MPLS Ethernet add/ del tunnel 2
1543     @param client_index - opaque cookie to identify the sender
1544     @param context - sender context, to match reply w/ request
1545     @param inner_vrf_id - 
1546     @param outer_vrf_id - 
1547     @param resolve_attempts - 
1548     @param resolve_opaque - 
1549     @param resolve_if_needed -
1550     @param is_add -
1551     @param adj_address -
1552     @param adj_address_length -
1553     @param next_hop_ip4_address_in_outer_vrf -
1554 */
1555 define mpls_ethernet_add_del_tunnel_2
1556 {
1557   u32 client_index;
1558   u32 context;
1559   u32 inner_vrf_id;
1560   u32 outer_vrf_id;
1561   u32 resolve_attempts;
1562   u32 resolve_opaque;           /* no need to set this */
1563   u8 resolve_if_needed;
1564   u8 is_add;
1565   u8 l2_only;
1566   u8 adj_address[4];
1567   u8 adj_address_length;
1568   u8 next_hop_ip4_address_in_outer_vrf[4];
1569 };
1570
1571 /** \brief MPLS Ethernet add/ del tunnel 2
1572     @param context - sender context, to match reply w/ request
1573     @param retval - return code for add /del request
1574 */
1575 define mpls_ethernet_add_del_tunnel_2_reply
1576 {
1577   u32 context;
1578   i32 retval;
1579 };
1580
1581 /** \brief Set L2 XConnect between two interfaces request
1582     @param client_index - opaque cookie to identify the sender
1583     @param context - sender context, to match reply w/ request
1584     @param rx_sw_if_index - Receive interface index
1585     @param tx_sw_if_index - Transmit interface index
1586     @param enable - enable xconnect if not 0, else set to L3 mode
1587 */
1588 define sw_interface_set_l2_xconnect
1589 {
1590   u32 client_index;
1591   u32 context;
1592   u32 rx_sw_if_index;
1593   u32 tx_sw_if_index;
1594   u8 enable;
1595 };
1596
1597 /** \brief Set L2 XConnect response
1598     @param context - sender context, to match reply w/ request
1599     @param retval - L2 XConnect request return code
1600 */
1601 define sw_interface_set_l2_xconnect_reply
1602 {
1603   u32 context;
1604   i32 retval;
1605 };
1606
1607 /** \brief Interface bridge mode request
1608     @param client_index - opaque cookie to identify the sender
1609     @param context - sender context, to match reply w/ request
1610     @param rx_sw_if_index - the interface
1611     @param bd_id - bridge domain id
1612     @param bvi - Setup interface as a bvi, bridge mode only
1613     @param shg - Shared horizon group, for bridge mode only
1614     @param enable - Enable beige mode if not 0, else set to L3 mode
1615 */
1616 define sw_interface_set_l2_bridge
1617 {
1618   u32 client_index;
1619   u32 context;
1620   u32 rx_sw_if_index;
1621   u32 bd_id;
1622   u8 shg;
1623   u8 bvi;
1624   u8 enable;
1625 };
1626
1627 /** \brief Interface bridge mode response
1628     @param context - sender context, to match reply w/ request
1629     @param retval - Bridge mode request return code
1630 */
1631 define sw_interface_set_l2_bridge_reply
1632 {
1633   u32 context;
1634   i32 retval;
1635 };
1636
1637 /** \brief L2 FIB add entry request
1638     @param client_index - opaque cookie to identify the sender
1639     @param context - sender context, to match reply w/ request
1640     @param mac - the entry's mac address
1641     @param bd_id - the entry's bridge domain id
1642     @param sw_if_index - the interface
1643     @param is_add - If non zero add the entry, else delete it
1644     @param static_mac - 
1645     @param filter_mac -
1646 */
1647 define l2fib_add_del
1648 {
1649   u32 client_index;
1650   u32 context;
1651   u64 mac;
1652   u32 bd_id;
1653   u32 sw_if_index;
1654   u8 is_add;
1655   u8 static_mac;
1656   u8 filter_mac;
1657   u8 bvi_mac;
1658 };
1659
1660 /** \brief L2 FIB add entry response
1661     @param context - sender context, to match reply w/ request
1662     @param retval - return code for the add l2fib entry request
1663 */
1664 define l2fib_add_del_reply
1665 {
1666   u32 context;
1667   i32 retval;
1668 };
1669
1670 /** \brief Set L2 flags request !!! TODO - need more info, feature bits in l2_input.h
1671     @param client_index - opaque cookie to identify the sender
1672     @param context - sender context, to match reply w/ request
1673     @param sw_if_index - interface 
1674     @param is_set - if non-zero, set the bits, else clear them
1675     @param feature_bitmap - non-zero bits to set or clear
1676 */
1677 define l2_flags
1678 {
1679   u32 client_index;
1680   u32 context;
1681   u32 sw_if_index;
1682   u8 is_set;
1683   u32 feature_bitmap;
1684 };
1685
1686 /** \brief Set L2 bits response
1687     @param context - sender context, to match reply w/ request
1688     @param retval - return code for the set l2 bits request
1689 */
1690 define l2_flags_reply
1691 {
1692   u32 context;
1693   i32 retval;
1694   u32 resulting_feature_bitmap;
1695 };
1696
1697 /** \brief Set bridge flags (such as L2_LEARN, L2_FWD, L2_FLOOD, 
1698     L2_UU_FLOOD, or L2_ARP_TERM) request
1699     @param client_index - opaque cookie to identify the sender
1700     @param context - sender context, to match reply w/ request
1701     @param bd_id - the bridge domain to set the flags for
1702     @param is_set - if non-zero, set the flags, else clear them
1703     @param feature_bitmap - bits that are non-zero to set or clear
1704 */
1705 define bridge_flags
1706 {
1707   u32 client_index;
1708   u32 context;
1709   u32 bd_id;
1710   u8 is_set;
1711   u32 feature_bitmap;
1712 };
1713
1714 /** \brief Set bridge flags response
1715     @param context - sender context, to match reply w/ request
1716     @param retval - return code for the set bridge flags request
1717     @param resulting_feature_bitmap - the feature bitmap value after the request is implemented
1718 */
1719 define bridge_flags_reply
1720 {
1721   u32 context;
1722   i32 retval;
1723   u32 resulting_feature_bitmap;
1724 };
1725
1726 /** \brief Set bridge domain ip to mac entry request
1727     @param client_index - opaque cookie to identify the sender
1728     @param context - sender context, to match reply w/ request
1729     @param bd_id - the bridge domain to set the flags for
1730     @param is_add - if non-zero, add the entry, else clear it
1731     @param is_ipv6 - if non-zero, ipv6 address, else ipv4 address
1732     @param mac_address - MAC address
1733     @param 
1734 */
1735 define bd_ip_mac_add_del
1736 {
1737   u32 client_index;
1738   u32 context;
1739   u32 bd_id;
1740   u8 is_add;
1741   u8 is_ipv6;
1742   u8 ip_address[16];
1743   u8 mac_address[6];
1744 };
1745
1746 /** \brief Set bridge domain ip to mac entry response
1747     @param context - sender context, to match reply w/ request
1748     @param retval - return code for the set bridge flags request
1749 */
1750 define bd_ip_mac_add_del_reply
1751 {
1752   u32 context;
1753   i32 retval;
1754 };
1755
1756 /** \brief Add/Delete classification table request
1757     @param client_index - opaque cookie to identify the sender
1758     @param context - sender context, to match reply w/ request
1759     @param is_add- if non-zero add the table, else delete it
1760     @param table_index - if add, reuturns index of the created table, else specifies the table to delete  
1761     @param nbuckets - number of buckets when adding a table
1762     @param memory_size - memory size when adding a table
1763     @param match_n_vectors - number of match vectors
1764     @param next_table_index - index of next table
1765     @param miss_next_index - index of miss table
1766     @param current_data_flag - option to use current node's packet payload
1767             as the starting point from where packets are classified,
1768             This option is only valid for L2/L3 input ACL for now.
1769             0: by default, classify data from the buffer's start location
1770             1: classify packets from VPP node’s current data pointer
1771     @param current_data_offset - a signed value to shift the start location of
1772             the packet to be classified
1773             For example, if input IP ACL node is used, L2 header’s first byte
1774             can be accessible by configuring current_data_offset to -14
1775             if there is no vlan tag.
1776             This is valid only if current_data_flag is set to 1.
1777     @param mask[] - match mask
1778 */
1779 define classify_add_del_table
1780 {
1781   u32 client_index;
1782   u32 context;
1783   u8 is_add;
1784   u32 table_index;
1785   u32 nbuckets;
1786   u32 memory_size;
1787   u32 skip_n_vectors;
1788   u32 match_n_vectors;
1789   u32 next_table_index;
1790   u32 miss_next_index;
1791   u32 current_data_flag;
1792   i32 current_data_offset;
1793   u8 mask[0];
1794 };
1795
1796 /** \brief Add/Delete classification table response
1797     @param context - sender context, to match reply w/ request
1798     @param retval - return code for the table add/del requst
1799     @param new_table_index - for add, returned index of the new table
1800     @param skip_n_vectors - for add, returned value of skip_n_vectors in table
1801     @param match_n_vectors -for add, returned value of match_n_vectors in table
1802 */
1803 define classify_add_del_table_reply
1804 {
1805   u32 context;
1806   i32 retval;
1807   u32 new_table_index;
1808   u32 skip_n_vectors;
1809   u32 match_n_vectors;
1810 };
1811
1812 /** \brief Classify add / del session request
1813     @param client_index - opaque cookie to identify the sender
1814     @param context - sender context, to match reply w/ request
1815     @param is_add - add session if non-zero, else delete
1816     @param table_index - index of the table to add/del the session, required
1817     @param hit_next_index - for add, hit_next_index of new session, required
1818     @param opaque_index - for add, opaque_index of new session
1819     @param advance -for add, advance value for session
1820     @param action -
1821            0: no action (by default)
1822               metadata is not used.
1823            1: Classified IP packets will be looked up from the
1824               specified ipv4 fib table (configured by metadata as VRF id).
1825               Only valid for L3 input ACL node
1826            2: Classified IP packets will be looked up from the
1827               specified ipv6 fib table (configured by metadata as VRF id).
1828               Only valid for L3 input ACL node
1829     @param metadata - valid only if action != 0
1830            VRF id if action is 1 or 2.
1831     @param match[] - for add, match value for session, required
1832 */
1833 define classify_add_del_session
1834 {
1835   u32 client_index;
1836   u32 context;
1837   u8 is_add;
1838   u32 table_index;
1839   u32 hit_next_index;
1840   u32 opaque_index;
1841   i32 advance;
1842   u8 action;
1843   u32 metadata;
1844   u8 match[0];
1845 };
1846
1847 /** \brief Classify add / del session response
1848     @param context - sender context, to match reply w/ request
1849     @param retval - return code for the add/del session request
1850 */
1851 define classify_add_del_session_reply
1852 {
1853   u32 context;
1854   i32 retval;
1855 };
1856
1857 /** \brief Set/unset the classification table for an interface request 
1858     @param client_index - opaque cookie to identify the sender
1859     @param context - sender context, to match reply w/ request
1860     @param is_ipv6 - ipv6 if non-zero, else ipv4
1861     @param sw_if_index - interface to associate with the table
1862     @param table_index - index of the table, if ~0 unset the table
1863 */
1864 define classify_set_interface_ip_table
1865 {
1866   u32 client_index;
1867   u32 context;
1868   u8 is_ipv6;
1869   u32 sw_if_index;
1870   u32 table_index;              /* ~0 => off */
1871 };
1872
1873 /** \brief Set/unset interface classification table response 
1874     @param context - sender context, to match reply w/ request
1875     @param retval - return code
1876 */
1877 define classify_set_interface_ip_table_reply
1878 {
1879   u32 context;
1880   i32 retval;
1881 };
1882
1883 /** \brief Set/unset l2 classification tables for an interface request
1884     @param client_index - opaque cookie to identify the sender
1885     @param context - sender context, to match reply w/ request
1886     @param sw_if_index - interface to set/unset tables for
1887     @param ip4_table_index - ip4 index, use ~0 for all 3 indexes to unset
1888     @param ip6_table_index - ip6 index
1889     @param other_table_index - other index
1890 */
1891 define classify_set_interface_l2_tables
1892 {
1893   u32 client_index;
1894   u32 context;
1895   u32 sw_if_index;
1896   /* 3 x ~0 => off */
1897   u32 ip4_table_index;
1898   u32 ip6_table_index;
1899   u32 other_table_index;
1900   u8 is_input;
1901 };
1902
1903 /** \brief Set/unset l2 classification tables for an interface response
1904     @param context - sender context, to match reply w/ request
1905     @param retval - return code for the request
1906 */
1907 define classify_set_interface_l2_tables_reply
1908 {
1909   u32 context;
1910   i32 retval;
1911 };
1912
1913 /** \brief Get node index using name request
1914     @param client_index - opaque cookie to identify the sender
1915     @param context - sender context, to match reply w/ request
1916     @param node_name[] - name of the node
1917 */
1918 define get_node_index
1919 {
1920   u32 client_index;
1921   u32 context;
1922   u8 node_name[64];
1923 };
1924
1925 /** \brief Get node index using name request
1926     @param context - sender context, to match reply w/ request
1927     @param retval - return code for the request
1928     @param node_index - index of the desired node if found, else ~0
1929 */
1930 define get_node_index_reply
1931 {
1932   u32 context;
1933   i32 retval;
1934   u32 node_index;
1935 };
1936
1937 /** \brief Set the next node for a given node request
1938     @param client_index - opaque cookie to identify the sender
1939     @param context - sender context, to match reply w/ request
1940     @param node_name[] - node to add the next node to
1941     @param next_name[] - node to add as the next node
1942 */
1943 define add_node_next
1944 {
1945   u32 client_index;
1946   u32 context;
1947   u8 node_name[64];
1948   u8 next_name[64];
1949 };
1950
1951 /** \brief IP Set the next node for a given node response
1952     @param context - sender context, to match reply w/ request
1953     @param retval - return code for the add next node request
1954     @param next_index - the index of the next node if success, else ~0
1955 */
1956 define add_node_next_reply
1957 {
1958   u32 context;
1959   i32 retval;
1960   u32 next_index;
1961 };
1962
1963 /** \brief DHCP Proxy config 2 add / del request
1964     @param client_index - opaque cookie to identify the sender
1965     @param context - sender context, to match reply w/ request
1966     @param rx_vrf_id - receive vrf id
1967     @param server_vrf_id - server vrf id
1968     @param if_ipv6 - ipv6 if non-zero, else ipv4
1969     @param is_add - add the config if non-zero, else delete
1970     @param insert_circuit_id - option82 suboption 1 fib number
1971     @param dhcp_server[] - server address
1972     @param dhcp_src_address[] - <fix this, need details>
1973 */
1974 define dhcp_proxy_config_2
1975 {
1976   u32 client_index;
1977   u32 context;
1978   u32 rx_vrf_id;
1979   u32 server_vrf_id;
1980   u8 is_ipv6;
1981   u8 is_add;
1982   u8 insert_circuit_id;
1983   u8 dhcp_server[16];
1984   u8 dhcp_src_address[16];
1985 };
1986
1987 /** \brief DHCP Proxy config 2 add / del response
1988     @param context - sender context, to match reply w/ request
1989     @param retval - return code for request
1990 */
1991 define dhcp_proxy_config_2_reply
1992 {
1993   u32 context;
1994   i32 retval;
1995 };
1996
1997 /** \brief l2tpv3 tunnel interface create request
1998     @param client_index - opaque cookie to identify the sender
1999     @param context - sender context, to match reply w/ request
2000     @param client_address - remote client tunnel ip address
2001     @param client_address - local tunnel ip address
2002     @param is_ipv6 - ipv6 if non-zero, else ipv4
2003     @param local_session_id - local tunnel session id
2004     @param remote_session_id - remote tunnel session id
2005     @param local_cookie - local tunnel cookie
2006     @param l2_sublayer_present - l2 sublayer is present in packets if non-zero
2007     @param encap_vrf_id - fib identifier used for outgoing encapsulated packets
2008 */
2009 define l2tpv3_create_tunnel
2010 {
2011   u32 client_index;
2012   u32 context;
2013   u8 client_address[16];
2014   u8 our_address[16];
2015   u8 is_ipv6;
2016   u32 local_session_id;
2017   u32 remote_session_id;
2018   u64 local_cookie;
2019   u64 remote_cookie;
2020   u8 l2_sublayer_present;
2021   u32 encap_vrf_id;
2022 };
2023
2024 /** \brief l2tpv3 tunnel interface create response
2025     @param context - sender context, to match reply w/ request
2026     @param retval - return code for the request
2027     @param sw_if_index - index of the new tunnel interface
2028 */
2029 define l2tpv3_create_tunnel_reply
2030 {
2031   u32 context;
2032   i32 retval;
2033   u32 sw_if_index;
2034 };
2035
2036 define l2tpv3_set_tunnel_cookies
2037 {
2038   u32 client_index;
2039   u32 context;
2040   u32 sw_if_index;
2041   u64 new_local_cookie;
2042   u64 new_remote_cookie;
2043 };
2044
2045 /** \brief L2TP tunnel set cookies response
2046     @param context - sender context, to match reply w/ request
2047     @param retval - return code for the request
2048 */
2049 define l2tpv3_set_tunnel_cookies_reply
2050 {
2051   u32 context;
2052   i32 retval;
2053 };
2054
2055 define sw_if_l2tpv3_tunnel_details
2056 {
2057   u32 context;
2058   u32 sw_if_index;
2059   u8 interface_name[64];
2060   u8 client_address[16];
2061   u8 our_address[16];
2062   u32 local_session_id;
2063   u32 remote_session_id;
2064   u64 local_cookie[2];
2065   u64 remote_cookie;
2066   u8 l2_sublayer_present;
2067 };
2068
2069 define sw_if_l2tpv3_tunnel_dump
2070 {
2071   u32 client_index;
2072   u32 context;
2073 };
2074
2075 /** \brief L2 fib clear table request, clear all mac entries in the l2 fib
2076     @param client_index - opaque cookie to identify the sender
2077     @param context - sender context, to match reply w/ request
2078 */
2079 define l2_fib_clear_table
2080 {
2081   u32 client_index;
2082   u32 context;
2083 };
2084
2085 /** \brief L2 fib clear table response
2086     @param context - sender context, to match reply w/ request
2087     @param retval - return code for the request
2088 */
2089 define l2_fib_clear_table_reply
2090 {
2091   u32 context;
2092   i32 retval;
2093 };
2094
2095 /** \brief L2 interface ethernet flow point filtering enable/disable request
2096     @param client_index - opaque cookie to identify the sender
2097     @param context - sender context, to match reply w/ request
2098     @param sw_if_index - interface to enable/disable filtering on
2099     @param enable_disable - if non-zero enable filtering, else disable
2100 */
2101 define l2_interface_efp_filter
2102 {
2103   u32 client_index;
2104   u32 context;
2105   u32 sw_if_index;
2106   u32 enable_disable;
2107 };
2108
2109 /** \brief L2 interface ethernet flow point filtering response
2110     @param context - sender context, to match reply w/ request
2111     @param retval - return code for the request
2112 */
2113 define l2_interface_efp_filter_reply
2114 {
2115   u32 context;
2116   i32 retval;
2117 };
2118
2119 define l2tpv3_interface_enable_disable
2120 {
2121   u32 client_index;
2122   u32 context;
2123   u8 enable_disable;
2124   u32 sw_if_index;
2125 };
2126
2127 define l2tpv3_interface_enable_disable_reply
2128 {
2129   u32 context;
2130   i32 retval;
2131 };
2132
2133 define l2tpv3_set_lookup_key
2134 {
2135   u32 client_index;
2136   u32 context;
2137   /* 0 = ip6 src_address, 1 = ip6 dst_address, 2 = session_id */
2138   u8 key;
2139 };
2140
2141 define l2tpv3_set_lookup_key_reply
2142 {
2143   u32 context;
2144   i32 retval;
2145 };
2146
2147 define vxlan_add_del_tunnel
2148 {
2149   u32 client_index;
2150   u32 context;
2151   u8 is_add;
2152   u8 is_ipv6;
2153   u8 src_address[16];
2154   u8 dst_address[16];
2155   u32 mcast_sw_if_index;
2156   u32 encap_vrf_id;
2157   u32 decap_next_index;
2158   u32 vni;
2159 };
2160
2161 define vxlan_add_del_tunnel_reply
2162 {
2163   u32 context;
2164   i32 retval;
2165   u32 sw_if_index;
2166 };
2167
2168 define vxlan_tunnel_dump
2169 {
2170   u32 client_index;
2171   u32 context;
2172   u32 sw_if_index;
2173 };
2174
2175 define vxlan_tunnel_details
2176 {
2177   u32 context;
2178   u32 sw_if_index;
2179   u8 src_address[16];
2180   u8 dst_address[16];
2181   u32 mcast_sw_if_index;
2182   u32 encap_vrf_id;
2183   u32 decap_next_index;
2184   u32 vni;
2185   u8 is_ipv6;
2186 };
2187
2188 define gre_add_del_tunnel
2189 {
2190   u32 client_index;
2191   u32 context;
2192   u8 is_add;
2193   u8 is_ipv6;
2194   u8 teb;
2195   u8 src_address[16];
2196   u8 dst_address[16];
2197   u32 outer_fib_id;
2198 };
2199
2200 define gre_add_del_tunnel_reply
2201 {
2202   u32 context;
2203   i32 retval;
2204   u32 sw_if_index;
2205 };
2206
2207 define gre_tunnel_dump
2208 {
2209   u32 client_index;
2210   u32 context;
2211   u32 sw_if_index;
2212 };
2213
2214 define gre_tunnel_details
2215 {
2216   u32 context;
2217   u32 sw_if_index;
2218   u8 is_ipv6;
2219   u8 teb;
2220   u8 src_address[16];
2221   u8 dst_address[16];
2222   u32 outer_fib_id;
2223 };
2224
2225 /** \brief L2 interface vlan tag rewrite configure request
2226     @param client_index - opaque cookie to identify the sender
2227     @param context - sender context, to match reply w/ request
2228     @param sw_if_index - interface the operation is applied to
2229     @param vtr_op - Choose from l2_vtr_op_t enum values
2230     @param push_dot1q - first pushed flag dot1q id set, else dot1ad
2231     @param tag1 - Needed for any push or translate vtr op
2232     @param tag2 - Needed for any push 2 or translate x-2 vtr ops
2233 */
2234 define l2_interface_vlan_tag_rewrite
2235 {
2236   u32 client_index;
2237   u32 context;
2238   u32 sw_if_index;
2239   u32 vtr_op;
2240   u32 push_dot1q;               // ethertype of first pushed tag is dot1q/dot1ad
2241   u32 tag1;                     // first pushed tag
2242   u32 tag2;                     // second pushed tag
2243 };
2244
2245 /** \brief L2 interface vlan tag rewrite response
2246     @param context - sender context, to match reply w/ request
2247     @param retval - return code for the request
2248 */
2249 define l2_interface_vlan_tag_rewrite_reply
2250 {
2251   u32 context;
2252   i32 retval;
2253 };
2254
2255 /** \brief vhost-user interface create request
2256     @param client_index - opaque cookie to identify the sender
2257     @param is_server - our side is socket server
2258     @param sock_filename - unix socket filename, used to speak with frontend
2259     @param use_custom_mac - enable or disable the use of the provided hardware address
2260     @param mac_address - hardware address to use if 'use_custom_mac' is set
2261 */
2262 define create_vhost_user_if
2263 {
2264   u32 client_index;
2265   u32 context;
2266   u8 is_server;
2267   u8 sock_filename[256];
2268   u8 renumber;
2269   u32 custom_dev_instance;
2270   u8 use_custom_mac;
2271   u8 mac_address[6];
2272 };
2273
2274 /** \brief vhost-user interface create response
2275     @param context - sender context, to match reply w/ request
2276     @param retval - return code for the request
2277     @param sw_if_index - interface the operation is applied to
2278 */
2279 define create_vhost_user_if_reply
2280 {
2281   u32 context;
2282   i32 retval;
2283   u32 sw_if_index;
2284 };
2285
2286 /** \brief vhost-user interface modify request
2287     @param client_index - opaque cookie to identify the sender
2288     @param is_server - our side is socket server
2289     @param sock_filename - unix socket filename, used to speak with frontend
2290 */
2291 define modify_vhost_user_if
2292 {
2293   u32 client_index;
2294   u32 context;
2295   u32 sw_if_index;
2296   u8 is_server;
2297   u8 sock_filename[256];
2298   u8 renumber;
2299   u32 custom_dev_instance;
2300 };
2301
2302 /** \brief vhost-user interface modify response
2303     @param context - sender context, to match reply w/ request
2304     @param retval - return code for the request
2305 */
2306 define modify_vhost_user_if_reply
2307 {
2308   u32 context;
2309   i32 retval;
2310 };
2311
2312 /** \brief vhost-user interface delete request
2313     @param client_index - opaque cookie to identify the sender
2314 */
2315 define delete_vhost_user_if
2316 {
2317   u32 client_index;
2318   u32 context;
2319   u32 sw_if_index;
2320 };
2321
2322 /** \brief vhost-user interface delete response
2323     @param context - sender context, to match reply w/ request
2324     @param retval - return code for the request
2325 */
2326 define delete_vhost_user_if_reply
2327 {
2328   u32 context;
2329   i32 retval;
2330 };
2331
2332 define create_subif
2333 {
2334   u32 client_index;
2335   u32 context;
2336   u32 sw_if_index;
2337   u32 sub_id;
2338
2339   /* These fields map directly onto the subif template */
2340   u8 no_tags;
2341   u8 one_tag;
2342   u8 two_tags;
2343   u8 dot1ad;                    // 0 = dot1q, 1=dot1ad
2344   u8 exact_match;
2345   u8 default_sub;
2346   u8 outer_vlan_id_any;
2347   u8 inner_vlan_id_any;
2348   u16 outer_vlan_id;
2349   u16 inner_vlan_id;
2350 };
2351
2352 define create_subif_reply
2353 {
2354   u32 context;
2355   i32 retval;
2356   u32 sw_if_index;
2357 };
2358
2359 /** \brief show version
2360     @param client_index - opaque cookie to identify the sender
2361     @param context - sender context, to match reply w/ request
2362 */
2363 define show_version
2364 {
2365   u32 client_index;
2366   u32 context;
2367 };
2368
2369 /** \brief show version response
2370     @param context - sender context, to match reply w/ request
2371     @param retval - return code for the request
2372     @param program - name of the program (vpe)
2373     @param version  - version of the program
2374     @param build_directory - root of the workspace where the program was built
2375 */
2376 define show_version_reply
2377 {
2378   u32 context;
2379   i32 retval;
2380   u8 program[32];
2381   u8 version[32];
2382   u8 build_date[32];
2383   u8 build_directory[256];
2384 };
2385
2386 /** \brief Vhost-user interface details structure (fix this)
2387     @param sw_if_index - index of the interface
2388     @param interface_name - name of interface
2389     @param virtio_net_hdr_sz - net header size
2390     @param features - interface features
2391     @param is_server - vhost-user server socket
2392     @param sock_filename - socket filename
2393     @param num_regions - number of used memory regions
2394 */
2395 define sw_interface_vhost_user_details
2396 {
2397   u32 context;
2398   u32 sw_if_index;
2399   u8 interface_name[64];
2400   u32 virtio_net_hdr_sz;
2401   u64 features;
2402   u8 is_server;
2403   u8 sock_filename[256];
2404   u32 num_regions;
2405   i32 sock_errno;
2406 };
2407
2408 /* works */
2409 define sw_interface_vhost_user_dump
2410 {
2411   u32 client_index;
2412   u32 context;
2413 };
2414
2415 define ip_address_details
2416 {
2417   u32 client_index;
2418   u32 context;
2419   u8 ip[16];
2420   u8 prefix_length;
2421 };
2422
2423 define ip_address_dump
2424 {
2425   u32 client_index;
2426   u32 context;
2427   u32 sw_if_index;
2428   u8 is_ipv6;
2429 };
2430
2431 define ip_details
2432 {
2433   u32 sw_if_index;
2434   u32 context;
2435 };
2436
2437 define ip_dump
2438 {
2439   u32 client_index;
2440   u32 context;
2441   u8 is_ipv6;
2442 };
2443
2444 /** \brief l2 fib table entry structure
2445     @param bd_id - the l2 fib / bridge domain table id
2446     @param mac - the entry's mac address
2447     @param sw_if_index - index of the interface
2448     @param static_mac - the entry is statically configured.
2449     @param filter_mac - the entry is a mac filter entry.
2450     @param bvi_mac - the mac address is a bridge virtual interface
2451 */
2452 define l2_fib_table_entry
2453 {
2454   u32 context;
2455   u32 bd_id;
2456   u64 mac;
2457   u32 sw_if_index;
2458   u8 static_mac;
2459   u8 filter_mac;
2460   u8 bvi_mac;
2461 };
2462
2463 /** \brief Dump l2 fib (aka bridge domain) table
2464     @param client_index - opaque cookie to identify the sender
2465     @param bd_id - the l2 fib / bridge domain table identifier
2466 */
2467 define l2_fib_table_dump
2468 {
2469   u32 client_index;
2470   u32 context;
2471   u32 bd_id;
2472 };
2473
2474 define vxlan_gpe_add_del_tunnel
2475 {
2476   u32 client_index;
2477   u32 context;
2478   u8 is_ipv6;
2479   u8 local[16];
2480   u8 remote[16];
2481   u32 encap_vrf_id;
2482   u32 decap_vrf_id;
2483   u8 protocol;
2484   u32 vni;
2485   u8 is_add;
2486 };
2487
2488 define vxlan_gpe_add_del_tunnel_reply
2489 {
2490   u32 context;
2491   i32 retval;
2492   u32 sw_if_index;
2493 };
2494
2495 define vxlan_gpe_tunnel_dump
2496 {
2497   u32 client_index;
2498   u32 context;
2499   u32 sw_if_index;
2500 };
2501
2502 define vxlan_gpe_tunnel_details
2503 {
2504   u32 context;
2505   u32 sw_if_index;
2506   u8 local[16];
2507   u8 remote[16];
2508   u32 vni;
2509   u8 protocol;
2510   u32 encap_vrf_id;
2511   u32 decap_vrf_id;
2512   u8 is_ipv6;
2513 };
2514
2515 /** \brief add or delete locator_set
2516     @param client_index - opaque cookie to identify the sender
2517     @param context - sender context, to match reply w/ request
2518     @param is_add - add address if non-zero, else delete
2519     @param locator_set_name - locator name
2520     @param locator_num - number of locators
2521     @param locators - LISP locator records
2522         Structure of one locator record is as follows:
2523
2524         define locator_t {
2525           u32 sw_if_index;
2526           u8 priority;
2527           u8 weight;
2528         }
2529 */
2530 define lisp_add_del_locator_set
2531 {
2532   u32 client_index;
2533   u32 context;
2534   u8 is_add;
2535   u8 locator_set_name[64];
2536   u32 locator_num;
2537   u8 locators[0];
2538 };
2539
2540 /** \brief Reply for locator_set add/del
2541     @param context - returned sender context, to match reply w/ request
2542     @param retval - return code
2543     @param ls_index - locator set index
2544 */
2545 define lisp_add_del_locator_set_reply
2546 {
2547   u32 context;
2548   i32 retval;
2549   u32 ls_index;
2550 };
2551
2552 /** \brief add or delete locator for locator_set
2553     @param client_index - opaque cookie to identify the sender
2554     @param context - sender context, to match reply w/ request
2555     @param is_add - add address if non-zero, else delete
2556     @param locator_set_name - name of locator_set to add/del locator
2557     @param sw_if_index - index of the interface
2558     @param priority - priority of the lisp locator
2559     @param weight - weight of the lisp locator
2560 */
2561 define lisp_add_del_locator
2562 {
2563   u32 client_index;
2564   u32 context;
2565   u8 is_add;
2566   u8 locator_set_name[64];
2567   u32 sw_if_index;
2568   u8 priority;
2569   u8 weight;
2570 };
2571
2572 /** \brief Reply for locator add/del
2573     @param context - returned sender context, to match reply w/ request
2574     @param retval - return code
2575 */
2576 define lisp_add_del_locator_reply
2577 {
2578   u32 context;
2579   i32 retval;
2580 };
2581
2582 /** \brief add or delete lisp eid-table
2583     @param client_index - opaque cookie to identify the sender
2584     @param context - sender context, to match reply w/ request
2585     @param is_add - add address if non-zero, else delete
2586     @param eid_type:
2587       0 : ipv4
2588       1 : ipv6
2589       2 : mac
2590     @param eid - EID can be ip4, ip6 or mac
2591     @param prefix_len - prefix len
2592     @param locator_set_name - name of locator_set to add/del eid-table
2593     @param vni - virtual network instance
2594 */
2595 define lisp_add_del_local_eid
2596 {
2597   u32 client_index;
2598   u32 context;
2599   u8 is_add;
2600   u8 eid_type;
2601   u8 eid[16];
2602   u8 prefix_len;
2603   u8 locator_set_name[64];
2604   u32 vni;
2605 };
2606
2607 /** \brief Reply for local_eid add/del
2608     @param context - returned sender context, to match reply w/ request
2609     @param retval - return code
2610 */
2611 define lisp_add_del_local_eid_reply
2612 {
2613   u32 context;
2614   i32 retval;
2615 };
2616
2617 /** \brief add or delete lisp gpe tunnel
2618     @param client_index - opaque cookie to identify the sender
2619     @param context - sender context, to match reply w/ request
2620     @param is_add - add address if non-zero, else delete
2621     @param eid_type -
2622       0 : ipv4
2623       1 : ipv6
2624       2 : mac
2625     @param rmt_eid - remote eid
2626     @param lcl_eid - local eid
2627     @param rmt_len - remote prefix len
2628     @param lcl_len - local prefix len
2629     @param vni - virtual network identifier
2630     @param dp_table - vrf/bridge domain id
2631     @param loc_num - number of locators
2632     @param lcl_locs - array of local locators
2633     @param rmt_locs - array of remote locators
2634     @param action - negative action when 0 locators configured
2635 */
2636 define lisp_gpe_add_del_fwd_entry
2637 {
2638   u32 client_index;
2639   u32 context;
2640   u8 is_add;
2641   u8 eid_type;
2642   u8 rmt_eid[16];
2643   u8 lcl_eid[16];
2644   u8 rmt_len;
2645   u8 lcl_len;
2646   u32 vni;
2647   u32 dp_table;
2648   u32 loc_num;
2649   u8 lcl_locs[loc_num];
2650   u8 rmt_locs[loc_num];
2651   u8 action;
2652 };
2653
2654 /** \brief Reply for gpe_fwd_entry add/del
2655     @param context - returned sender context, to match reply w/ request
2656     @param retval - return code
2657 */
2658 define lisp_gpe_add_del_fwd_entry_reply
2659 {
2660   u32 context;
2661   i32 retval;
2662 };
2663
2664 /** \brief add or delete map-resolver
2665     @param client_index - opaque cookie to identify the sender
2666     @param context - sender context, to match reply w/ request
2667     @param is_add - add address if non-zero, else delete
2668     @param is_ipv6 - if non-zero the address is ipv6, else ipv4
2669     @param ip_address - array of address bytes
2670 */
2671 define lisp_add_del_map_resolver
2672 {
2673   u32 client_index;
2674   u32 context;
2675   u8 is_add;
2676   u8 is_ipv6;
2677   u8 ip_address[16];
2678 };
2679
2680 /** \brief Reply for map_resolver add/del
2681     @param context - returned sender context, to match reply w/ request
2682     @param retval - return code
2683 */
2684 define lisp_add_del_map_resolver_reply
2685 {
2686   u32 context;
2687   i32 retval;
2688 };
2689
2690 /** \brief enable or disable lisp-gpe protocol
2691     @param client_index - opaque cookie to identify the sender
2692     @param context - sender context, to match reply w/ request
2693     @param is_en - enable protocol if non-zero, else disable
2694 */
2695 define lisp_gpe_enable_disable
2696 {
2697   u32 client_index;
2698   u32 context;
2699   u8 is_en;
2700 };
2701
2702 /** \brief Reply for gpe enable/disable
2703     @param context - returned sender context, to match reply w/ request
2704     @param retval - return code
2705 */
2706 define lisp_gpe_enable_disable_reply
2707 {
2708   u32 context;
2709   i32 retval;
2710 };
2711
2712 /** \brief enable or disable LISP feature
2713     @param client_index - opaque cookie to identify the sender
2714     @param context - sender context, to match reply w/ request
2715     @param is_en - enable protocol if non-zero, else disable
2716 */
2717 define lisp_enable_disable
2718 {
2719   u32 client_index;
2720   u32 context;
2721   u8 is_en;
2722 };
2723
2724 /** \brief Reply for gpe enable/disable
2725     @param context - returned sender context, to match reply w/ request
2726     @param retval - return code
2727 */
2728 define lisp_enable_disable_reply
2729 {
2730   u32 context;
2731   i32 retval;
2732 };
2733
2734 /** \brief add or delete gpe_iface
2735     @param client_index - opaque cookie to identify the sender
2736     @param context - sender context, to match reply w/ request
2737     @param is_add - add address if non-zero, else delete
2738 */
2739 define lisp_gpe_add_del_iface
2740 {
2741   u32 client_index;
2742   u32 context;
2743   u8 is_add;
2744   u8 is_l2;
2745   u32 dp_table;
2746   u32 vni;
2747 };
2748
2749 /** \brief Reply for gpe_iface add/del
2750     @param context - returned sender context, to match reply w/ request
2751     @param retval - return code
2752 */
2753 define lisp_gpe_add_del_iface_reply
2754 {
2755   u32 context;
2756   i32 retval;
2757 };
2758
2759 /** \brief configure or disable LISP PITR node
2760     @param client_index - opaque cookie to identify the sender
2761     @param context - sender context, to match reply w/ request
2762     @param ls_name - locator set name
2763     @param is_add - add locator set if non-zero, else disable pitr
2764 */
2765 define lisp_pitr_set_locator_set
2766 {
2767   u32 client_index;
2768   u32 context;
2769   u8 is_add;
2770   u8 ls_name[64];
2771 };
2772
2773 /** \brief Reply for lisp_pitr_set_locator_set
2774     @param context - returned sender context, to match reply w/ request
2775     @param retval - return code
2776 */
2777 define lisp_pitr_set_locator_set_reply
2778 {
2779   u32 context;
2780   i32 retval;
2781 };
2782
2783 /** \brief set LISP map-request mode. Based on configuration VPP will send
2784       src/dest or just normal destination map requests.
2785     @param client_index - opaque cookie to identify the sender
2786     @param context - sender context, to match reply w/ request
2787     @param mode - new map-request mode. Supported values are:
2788       0 - destination only
2789       1 - source/destaination
2790 */
2791 define lisp_map_request_mode
2792 {
2793   u32 client_index;
2794   u32 context;
2795   u8 mode;
2796 };
2797
2798 /** \brief Reply for lisp_map_request_mode
2799     @param context - returned sender context, to match reply w/ request
2800     @param retval - return code
2801 */
2802 define lisp_map_request_mode_reply
2803 {
2804   u32 context;
2805   i32 retval;
2806 };
2807
2808 /** \brief Request for LISP map-request mode
2809     @param client_index - opaque cookie to identify the sender
2810     @param context - sender context, to match reply w/ request
2811 */
2812 define show_lisp_map_request_mode
2813 {
2814   u32 client_index;
2815   u32 context;
2816 };
2817
2818 /** \brief Reply for show_lisp_map_request_mode
2819     @param context - returned sender context, to match reply w/ request
2820     @param retval - return code
2821     @param mode - map-request mode
2822 */
2823 define show_lisp_map_request_mode_reply
2824 {
2825   u32 context;
2826   i32 retval;
2827   u8 mode;
2828 };
2829
2830 /** \brief add or delete remote static mapping
2831     @param client_index - opaque cookie to identify the sender
2832     @param context - sender context, to match reply w/ request
2833     @param is_add - add address if non-zero, else delete
2834     @param is_src_dst - flag indicating src/dst based routing policy
2835     @param del_all - if set, delete all remote mappings
2836     @param vni - virtual network instance
2837     @param action - negative map-reply action
2838     @param eid_type -
2839       0 : ipv4
2840       1 : ipv6
2841       2 : mac
2842     @param deid - dst EID
2843     @param seid - src EID, valid only if is_src_dst is enabled
2844     @param rloc_num - number of remote locators
2845     @param rlocs - remote locator records
2846         Structure of remote locator:
2847
2848         define rloc_t {
2849           u8 is_ip4;
2850           u8 priority;
2851           u8 weight;
2852           u8 addr[16];
2853         }
2854 */
2855 define lisp_add_del_remote_mapping
2856 {
2857   u32 client_index;
2858   u32 context;
2859   u8 is_add;
2860   u8 is_src_dst;
2861   u8 del_all;
2862   u32 vni;
2863   u8 action;
2864   u8 eid_type;
2865   u8 eid[16];
2866   u8 eid_len;
2867   u8 seid[16];
2868   u8 seid_len;
2869   u32 rloc_num;
2870   u8 rlocs[0];
2871 };
2872
2873 /** \brief Reply for lisp_add_del_remote_mapping
2874     @param context - returned sender context, to match reply w/ request
2875     @param retval - return code
2876 */
2877 define lisp_add_del_remote_mapping_reply
2878 {
2879   u32 context;
2880   i32 retval;
2881 };
2882
2883 /** \brief add or delete LISP adjacency adjacency
2884     @param client_index - opaque cookie to identify the sender
2885     @param context - sender context, to match reply w/ request
2886     @param is_add - add address if non-zero, else delete
2887     @param vni - virtual network instance
2888     @param eid_type -
2889       0 : ipv4
2890       1 : ipv6
2891       2 : mac
2892     @param reid - remote EID
2893     @param leid - local EID
2894 */
2895 define lisp_add_del_adjacency
2896 {
2897   u32 client_index;
2898   u32 context;
2899   u8 is_add;
2900   u32 vni;
2901   u8 eid_type;
2902   u8 reid[16];
2903   u8 leid[16];
2904   u8 reid_len;
2905   u8 leid_len;
2906 };
2907
2908 /** \brief Reply for lisp_add_del_adjacency
2909     @param context - returned sender context, to match reply w/ request
2910     @param retval - return code
2911 */
2912 define lisp_add_del_adjacency_reply
2913 {
2914   u32 context;
2915   i32 retval;
2916 };
2917
2918 /** \brief add or delete map request itr rlocs
2919     @param client_index - opaque cookie to identify the sender
2920     @param context - sender context, to match reply w/ request
2921     @param is_add - add address if non-zero, else delete
2922     @param locator_set_name - locator set name
2923 */
2924 define lisp_add_del_map_request_itr_rlocs
2925 {
2926   u32 client_index;
2927   u32 context;
2928   u8 is_add;
2929   u8 locator_set_name[64];
2930 };
2931
2932 /** \brief Reply for lisp_add_del_map_request_itr_rlocs
2933     @param context - returned sender context, to match reply w/ request
2934     @param retval - return code
2935 */
2936
2937 define lisp_add_del_map_request_itr_rlocs_reply
2938 {
2939   u32 context;
2940   i32 retval;
2941 };
2942
2943 /** \brief map/unmap vni/bd_index to vrf
2944     @param client_index - opaque cookie to identify the sender
2945     @param context - sender context, to match reply w/ request
2946     @param is_add - add or delete mapping
2947     @param dp_table - virtual network id/bridge domain index
2948     @param vrf - vrf
2949 */
2950 define lisp_eid_table_add_del_map
2951 {
2952   u32 client_index;
2953   u32 context;
2954   u8 is_add;
2955   u32 vni;
2956   u32 dp_table;
2957   u8 is_l2;
2958 };
2959
2960 /** \brief Reply for lisp_eid_table_add_del_map
2961     @param context - returned sender context, to match reply w/ request
2962     @param retval - return code
2963 */
2964 define lisp_eid_table_add_del_map_reply
2965 {
2966   u32 context;
2967   i32 retval;
2968 };
2969
2970 /** \brief Request for map lisp locator status
2971     @param client_index - opaque cookie to identify the sender
2972     @param context - sender context, to match reply w/ request
2973     @param locator_set_index - index of locator_set
2974     @param ls_name - locator set name
2975     @param is_index_set - flag indicating whether ls_name or ls_index is set
2976  */
2977 define lisp_locator_dump
2978 {
2979   u32 client_index;
2980   u32 context;
2981   u32 ls_index;
2982   u8 ls_name[64];
2983   u8 is_index_set;
2984 };
2985
2986 /** \brief LISP locator_set status
2987     @param local - if is set, then locator is local
2988     @param locator_set_name - name of the locator_set
2989     @param sw_if_index - sw_if_index of the locator
2990     @param priority - locator priority
2991     @param weight - locator weight
2992   */
2993 define lisp_locator_details
2994 {
2995   u32 context;
2996   u8 local;
2997   u32 sw_if_index;
2998   u8 is_ipv6;
2999   u8 ip_address[16];
3000   u8 priority;
3001   u8 weight;
3002 };
3003
3004 /** \brief LISP locator_set status
3005     @param context - sender context, to match reply w/ request
3006     @param ls_index - locator set index
3007     @param ls_name - name of the locator set
3008  */
3009 define lisp_locator_set_details
3010 {
3011   u32 context;
3012   u32 ls_index;
3013   u8 ls_name[64];
3014 };
3015
3016 /** \brief Request for locator_set summary status
3017     @param client_index - opaque cookie to identify the sender
3018     @param context - sender context, to match reply w/ request
3019     @param filter - filter type
3020       Supported values:
3021         0: all locator sets
3022         1: local locator sets
3023         2: remote locator sets
3024  */
3025 define lisp_locator_set_dump
3026 {
3027   u32 client_index;
3028   u32 context;
3029   u8 filter;
3030 };
3031
3032 /** \brief Dump lisp eid-table
3033     @param client_index - opaque cookie to identify the sender
3034     @param context - sender context, to match reply w/ request
3035     @param locator_set_index - index of locator_set, if ~0 then the mapping
3036                                 is negative
3037     @param action - negative map request action
3038     @param is_local - local if non-zero, else remote
3039     @param eid_type:
3040       0 : ipv4
3041       1 : ipv6
3042       2 : mac
3043     @param is_src_dst - EID is type of source/destination
3044     @param eid - EID can be ip4, ip6 or mac
3045     @param eid_prefix_len - prefix length
3046     @param seid - source EID can be ip4, ip6 or mac
3047     @param seid_prefix_len - source prefix length
3048     @param vni - virtual network instance
3049     @param ttl - time to live
3050     @param authoritative - authoritative
3051 */
3052
3053 define lisp_eid_table_details
3054 {
3055   u32 context;
3056   u32 locator_set_index;
3057   u8 action;
3058   u8 is_local;
3059   u8 eid_type;
3060   u8 is_src_dst;
3061   u32 vni;
3062   u8 eid[16];
3063   u8 eid_prefix_len;
3064   u8 seid[16];
3065   u8 seid_prefix_len;
3066   u32 ttl;
3067   u8 authoritative;
3068 };
3069
3070 /** \brief Request for eid table summary status
3071     @param client_index - opaque cookie to identify the sender
3072     @param context - sender context, to match reply w/ request
3073     @param eid_set - if non-zero request info about specific mapping
3074     @param vni - virtual network instance; valid only if eid_set != 0
3075     @param prefix_length - prefix length if EID is IP address;
3076       valid only if eid_set != 0
3077     @param eid_type - EID type; valid only if eid_set != 0
3078       Supported values:
3079         0: EID is IPv4
3080         1: EID is IPv6
3081         2: EID is ethernet address
3082     @param eid - endpoint identifier
3083     @param filter - filter type;
3084       Support values:
3085         0: all eid
3086         1: local eid
3087         2: remote eid
3088  */
3089 define lisp_eid_table_dump
3090 {
3091   u32 client_index;
3092   u32 context;
3093   u8 eid_set;
3094   u8 prefix_length;
3095   u32 vni;
3096   u8 eid_type;
3097   u8 eid[16];
3098   u8 filter;
3099 };
3100
3101 /** \brief LISP adjacency
3102     @param eid_type -
3103       0 : ipv4
3104       1 : ipv6
3105       2 : mac
3106     @param reid - remote EID
3107     @param leid - local EID
3108     @param reid_prefix_len - remote EID IP prefix length
3109     @param leid_prefix_len - local EID IP prefix length
3110   */
3111 typeonly manual_print manual_endian define lisp_adjacency
3112 {
3113   u8 eid_type;
3114   u8 reid[16];
3115   u8 leid[16];
3116   u8 reid_prefix_len;
3117   u8 leid_prefix_len;
3118 };
3119
3120 /** \brief LISP adjacency reply
3121     @param count - number of adjacencies
3122     @param adjacencies - array of adjacencies
3123   */
3124 manual_endian manual_print define lisp_adjacencies_get_reply
3125 {
3126   u32 context;
3127   i32 retval;
3128   u32 count;
3129   vl_api_lisp_adjacency_t adjacencies[count];
3130 };
3131
3132 /** \brief Request for LISP adjacencies
3133     @param client_index - opaque cookie to identify the sender
3134     @param context - sender context, to match reply w/ request
3135     @param vni - filter adjacencies by VNI
3136  */
3137 define lisp_adjacencies_get
3138 {
3139   u32 client_index;
3140   u32 context;
3141   u32 vni;
3142 };
3143
3144 /** \brief Shows relationship between vni and vrf/bd
3145     @param dp_table - VRF index or bridge domain index
3146     @param vni - vitual network instance
3147   */
3148 define lisp_eid_table_map_details
3149 {
3150   u32 context;
3151   u32 vni;
3152   u32 dp_table;
3153 };
3154
3155 /** \brief Request for lisp_eid_table_map_details
3156     @param client_index - opaque cookie to identify the sender
3157     @param context - sender context, to match reply w/ request
3158     @param is_l2 - if set dump vni/bd mappings else vni/vrf
3159  */
3160 define lisp_eid_table_map_dump
3161 {
3162   u32 client_index;
3163   u32 context;
3164   u8 is_l2;
3165 };
3166
3167 /** \brief Dumps all VNIs used in mappings
3168     @param client_index - opaque cookie to identify the sender
3169     @param context - sender context, to match reply w/ request
3170   */
3171 define lisp_eid_table_vni_dump
3172 {
3173   u32 client_index;
3174   u32 context;
3175 };
3176
3177 /** \brief reply to lisp_eid_table_vni_dump
3178     @param client_index - opaque cookie to identify the sender
3179     @param context - sender context, to match reply w/ request
3180     @param vni - virtual network instance
3181  */
3182 define lisp_eid_table_vni_details
3183 {
3184   u32 client_index;
3185   u32 context;
3186   u32 vni;
3187 };
3188
3189 define lisp_gpe_tunnel_details
3190 {
3191   u32 context;
3192   u32 tunnels;
3193   u8 is_ipv6;
3194   u8 source_ip[16];
3195   u8 destination_ip[16];
3196   u32 encap_fib_id;
3197   u32 decap_fib_id;
3198   u32 dcap_next;
3199   u8 lisp_ver;
3200   u8 next_protocol;
3201   u8 flags;
3202   u8 ver_res;
3203   u8 res;
3204   u32 iid;
3205 };
3206
3207 /** \brief Request for gpe tunnel summary status
3208     @param client_index - opaque cookie to identify the sender
3209     @param context - sender context, to match reply w/ request
3210  */
3211 define lisp_gpe_tunnel_dump
3212 {
3213   u32 client_index;
3214   u32 context;
3215 };
3216
3217 /** \brief LISP map resolver status
3218     @param locator_set_name - name of the locator_set
3219     @param is_ipv6 - if non-zero the address is ipv6, else ipv4
3220     @param ip_address - array of address bytes
3221  */
3222 define lisp_map_resolver_details
3223 {
3224   u32 context;
3225   u8 is_ipv6;
3226   u8 ip_address[16];
3227 };
3228
3229 /** \brief Request for map resolver summary status
3230     @param client_index - opaque cookie to identify the sender
3231     @param context - sender context, to match reply w/ request
3232  */
3233 define lisp_map_resolver_dump
3234 {
3235   u32 client_index;
3236   u32 context;
3237 };
3238
3239 /** \brief Request for lisp-gpe protocol status
3240     @param client_index - opaque cookie to identify the sender
3241     @param context - sender context, to match reply w/ request
3242 */
3243 define show_lisp_status
3244 {
3245   u32 client_index;
3246   u32 context;
3247 };
3248
3249 /** \brief Status of lisp, enable or disable
3250     @param context - sender context, to match reply w/ request
3251     @param feature_status - lisp enable if non-zero, else disable
3252     @param gpe_status - lisp enable if non-zero, else disable
3253 */
3254 define show_lisp_status_reply
3255 {
3256   u32 context;
3257   i32 retval;
3258   u8 feature_status;
3259   u8 gpe_status;
3260 };
3261
3262 /** \brief Get LISP map request itr rlocs status
3263     @param context - sender context, to match reply w/ request
3264     @param locator_set_name - name of the locator_set
3265  */
3266 define lisp_get_map_request_itr_rlocs
3267 {
3268   u32 client_index;
3269   u32 context;
3270 };
3271
3272 /** \brief Request for map request itr rlocs summary status
3273  */
3274 define lisp_get_map_request_itr_rlocs_reply
3275 {
3276   u32 context;
3277   i32 retval;
3278   u8 locator_set_name[64];
3279 };
3280
3281 /** \brief Request for lisp pitr status
3282     @param client_index - opaque cookie to identify the sender
3283     @param context - sender context, to match reply w/ request
3284 */
3285 define show_lisp_pitr
3286 {
3287   u32 client_index;
3288   u32 context;
3289 };
3290
3291 /** \brief Status of lisp pitr, enable or disable
3292     @param context - sender context, to match reply w/ request
3293     @param status - lisp pitr enable if non-zero, else disable
3294     @param locator_set_name -  name of the locator_set
3295 */
3296 define show_lisp_pitr_reply
3297 {
3298   u32 context;
3299   i32 retval;
3300   u8 status;
3301   u8 locator_set_name[64];
3302 };
3303
3304 /* Gross kludge, DGMS */
3305 define interface_name_renumber
3306 {
3307   u32 client_index;
3308   u32 context;
3309   u32 sw_if_index;
3310   u32 new_show_dev_instance;
3311 };
3312
3313 define interface_name_renumber_reply
3314 {
3315   u32 context;
3316   i32 retval;
3317 };
3318
3319 /** \brief Register for ip4 arp resolution events
3320     @param client_index - opaque cookie to identify the sender
3321     @param context - sender context, to match reply w/ request
3322     @param enable_disable - 1 => register for events, 0 => cancel registration
3323     @param pid - sender's pid
3324     @param address - the exact ip4 address of interest
3325 */
3326 define want_ip4_arp_events
3327 {
3328   u32 client_index;
3329   u32 context;
3330   u8 enable_disable;
3331   u32 pid;
3332   u32 address;
3333 };
3334
3335 /** \brief Reply for interface events registration
3336     @param context - returned sender context, to match reply w/ request
3337     @param retval - return code
3338 */
3339 define want_ip4_arp_events_reply
3340 {
3341   u32 context;
3342   i32 retval;
3343 };
3344
3345 /** \brief Tell client about an ip4 arp resolution event
3346     @param client_index - opaque cookie to identify the sender
3347     @param context - sender context, to match reply w/ request
3348     @param address - the exact ip4 address of interest
3349     @param pid - client pid registered to receive notification
3350     @param sw_if_index - interface which received ARP packet
3351     @param new_mac - the new mac address 
3352     @param mac_ip - 0: resolution event, 1: mac/ip binding in bd
3353 */
3354 define ip4_arp_event
3355 {
3356   u32 client_index;
3357   u32 context;
3358   u32 address;
3359   u32 pid;
3360   u32 sw_if_index;
3361   u8 new_mac[6];
3362   u8 mac_ip;
3363 };
3364
3365 /** \brief Register for ip6 nd resolution events
3366     @param client_index - opaque cookie to identify the sender
3367     @param context - sender context, to match reply w/ request
3368     @param enable_disable - 1 => register for events, 0 => cancel registration
3369     @param pid - sender's pid
3370     @param address - the exact ip6 address of interest
3371 */
3372 define want_ip6_nd_events
3373 {
3374   u32 client_index;
3375   u32 context;
3376   u8 enable_disable;
3377   u32 pid;
3378   u8 address[16];
3379 };
3380
3381 /** \brief Reply for ip6 nd resolution events registration
3382     @param context - returned sender context, to match reply w/ request
3383     @param retval - return code
3384 */
3385 define want_ip6_nd_events_reply
3386 {
3387   u32 context;
3388   i32 retval;
3389 };
3390
3391 /** \brief Tell client about an ip6 nd resolution or mac/ip event
3392     @param client_index - opaque cookie to identify the sender
3393     @param context - sender context, to match reply w/ request
3394     @param pid - client pid registered to receive notification
3395     @param sw_if_index - interface which received ARP packet
3396     @param address - the exact ip6 address of interest
3397     @param new_mac - the new mac address 
3398     @param mac_ip - 0: resolution event, 1: mac/ip binding in bd
3399 */
3400 define ip6_nd_event
3401 {
3402   u32 client_index;
3403   u32 context;
3404   u32 pid;
3405   u32 sw_if_index;
3406   u8 address[16];
3407   u8 new_mac[6];
3408   u8 mac_ip;
3409 };
3410     
3411 /** \brief L2 bridge domain add or delete request
3412     @param client_index - opaque cookie to identify the sender
3413     @param context - sender context, to match reply w/ request
3414     @param bd_id - the bridge domain to create
3415     @param flood - enable/disable bcast/mcast flooding in the bd
3416     @param uu_flood - enable/disable uknown unicast flood in the bd
3417     @param forward - enable/disable forwarding on all interfaces in the bd
3418     @param learn - enable/disable learning on all interfaces in the bd
3419     @param arp_term - enable/disable arp termination in the bd
3420     @param is_add - add or delete flag
3421 */
3422 define bridge_domain_add_del
3423 {
3424   u32 client_index;
3425   u32 context;
3426   u32 bd_id;
3427   u8 flood;
3428   u8 uu_flood;
3429   u8 forward;
3430   u8 learn;
3431   u8 arp_term;
3432   u8 is_add;
3433 };
3434
3435 /** \brief L2 bridge domain add or delete response
3436     @param context - sender context, to match reply w/ request
3437     @param retval - return code for the set bridge flags request
3438 */
3439 define bridge_domain_add_del_reply
3440 {
3441   u32 context;
3442   i32 retval;
3443 };
3444
3445 /** \brief L2 bridge domain request operational state details
3446     @param client_index - opaque cookie to identify the sender
3447     @param context - sender context, to match reply w/ request
3448     @param bd_id - the bridge domain id desired or ~0 to request all bds
3449 */
3450 define bridge_domain_dump
3451 {
3452   u32 client_index;
3453   u32 context;
3454   u32 bd_id;
3455 };
3456
3457 /** \brief L2 bridge domain operational state response
3458     @param bd_id - the bridge domain id
3459     @param flood - bcast/mcast flooding state on all interfaces in the bd
3460     @param uu_flood - uknown unicast flooding state on all interfaces in the bd
3461     @param forward - forwarding state on all interfaces in the bd
3462     @param learn - learning state on all interfaces in the bd
3463     @param arp_term - arp termination state on all interfaces in the bd
3464     @param n_sw_ifs - number of sw_if_index's in the domain
3465 */
3466 define bridge_domain_details
3467 {
3468   u32 context;
3469   u32 bd_id;
3470   u8 flood;
3471   u8 uu_flood;
3472   u8 forward;
3473   u8 learn;
3474   u8 arp_term;
3475   u32 bvi_sw_if_index;
3476   u32 n_sw_ifs;
3477 };
3478
3479 /** \brief L2 bridge domain sw interface operational state response
3480     @param bd_id - the bridge domain id
3481     @param sw_if_index - sw_if_index in the domain
3482     @param shg - split horizon group for the interface
3483 */
3484 define bridge_domain_sw_if_details
3485 {
3486   u32 context;
3487   u32 bd_id;
3488   u32 sw_if_index;
3489   u8 shg;
3490 };
3491
3492 /** \brief DHCP Client config add / del request
3493     @param client_index - opaque cookie to identify the sender
3494     @param context - sender context, to match reply w/ request
3495     @param sw_if_index - index of the interface for DHCP client
3496     @param hostname - hostname
3497     @param is_add - add the config if non-zero, else delete
3498     @param want_dhcp_event - DHCP event sent to the sender
3499            via dhcp_compl_event API message if non-zero
3500     @param pid - sender's pid
3501 */
3502 define dhcp_client_config
3503 {
3504   u32 client_index;
3505   u32 context;
3506   u32 sw_if_index;
3507   u8 hostname[64];
3508   u8 is_add;
3509   u8 want_dhcp_event;
3510   u32 pid;
3511 };
3512
3513 /** \brief DHCP Client config response
3514     @param context - sender context, to match reply w/ request
3515     @param retval - return code for the request
3516 */
3517 define dhcp_client_config_reply
3518 {
3519   u32 context;
3520   i32 retval;
3521 };
3522
3523 /** \brief Set/unset input ACL interface
3524     @param client_index - opaque cookie to identify the sender
3525     @param context - sender context, to match reply w/ request
3526     @param sw_if_index - interface to set/unset input ACL
3527     @param ip4_table_index - ip4 classify table index (~0 for skip)
3528     @param ip6_table_index - ip6 classify table index (~0 for skip)
3529     @param l2_table_index  -  l2 classify table index (~0 for skip)
3530     @param is_add - Set input ACL if non-zero, else unset
3531     Note: User is recommeneded to use just one valid table_index per call.
3532           (ip4_table_index, ip6_table_index, or l2_table_index)
3533 */
3534 define input_acl_set_interface
3535 {
3536   u32 client_index;
3537   u32 context;
3538   u32 sw_if_index;
3539   u32 ip4_table_index;
3540   u32 ip6_table_index;
3541   u32 l2_table_index;
3542   u8 is_add;
3543 };
3544
3545 /** \brief Set/unset input ACL interface response
3546     @param context - sender context, to match reply w/ request
3547     @param retval - return code for the request
3548 */
3549 define input_acl_set_interface_reply
3550 {
3551   u32 context;
3552   i32 retval;
3553 };
3554
3555 /** \brief IPsec: Add/delete Security Policy Database
3556     @param client_index - opaque cookie to identify the sender
3557     @param context - sender context, to match reply w/ request
3558     @param is_add - add SPD if non-zero, else delete
3559     @param spd_id - SPD instance id (control plane allocated)
3560 */
3561
3562 define ipsec_spd_add_del
3563 {
3564   u32 client_index;
3565   u32 context;
3566   u8 is_add;
3567   u32 spd_id;
3568 };
3569
3570 /** \brief Reply for IPsec: Add/delete Security Policy Database entry
3571     @param context - returned sender context, to match reply w/ request
3572     @param retval - return code
3573 */
3574
3575 define ipsec_spd_add_del_reply
3576 {
3577   u32 context;
3578   i32 retval;
3579 };
3580
3581 /** \brief IPsec: Add/delete SPD from interface
3582
3583     @param client_index - opaque cookie to identify the sender
3584     @param context - sender context, to match reply w/ request
3585     @param is_add - add security mode if non-zero, else delete
3586     @param sw_if_index - index of the interface
3587     @param spd_id - SPD instance id to use for lookups
3588 */
3589
3590
3591 define ipsec_interface_add_del_spd
3592 {
3593   u32 client_index;
3594   u32 context;
3595
3596   u8 is_add;
3597   u32 sw_if_index;
3598   u32 spd_id;
3599 };
3600
3601 /** \brief Reply for IPsec: Add/delete SPD from interface
3602     @param context - returned sender context, to match reply w/ request
3603     @param retval - return code
3604 */
3605
3606 define ipsec_interface_add_del_spd_reply
3607 {
3608   u32 context;
3609   i32 retval;
3610 };
3611
3612 /** \brief IPsec: Add/delete Security Policy Database entry
3613
3614     See RFC 4301, 4.4.1.1 on how to match packet to selectors
3615
3616     @param client_index - opaque cookie to identify the sender
3617     @param context - sender context, to match reply w/ request
3618     @param is_add - add SPD if non-zero, else delete
3619     @param spd_id - SPD instance id (control plane allocated)
3620     @param priority - priority of SPD entry (non-unique value).  Used to order SPD matching - higher priorities match before lower
3621     @param is_outbound - entry applies to outbound traffic if non-zero, otherwise applies to inbound traffic
3622     @param is_ipv6 - remote/local address are IPv6 if non-zero, else IPv4
3623     @param remote_address_start - start of remote address range to match
3624     @param remote_address_stop - end of remote address range to match
3625     @param local_address_start - start of local address range to match
3626     @param local_address_stop - end of local address range to match
3627     @param protocol - protocol type to match [0 means any]
3628     @param remote_port_start - start of remote port range to match ...
3629     @param remote_port_stop - end of remote port range to match [0 to 65535 means ANY, 65535 to 0 means OPAQUE]
3630     @param local_port_start - start of local port range to match ...
3631     @param local_port_stop - end of remote port range to match [0 to 65535 means ANY, 65535 to 0 means OPAQUE]
3632     @param policy - 0 = bypass (no IPsec processing), 1 = discard (discard packet with ICMP processing), 2 = resolve (send request to control plane for SA resolving, and discard without ICMP processing), 3 = protect (apply IPsec policy using following parameters)
3633     @param sa_id - SAD instance id (control plane allocated)
3634
3635 */
3636
3637 define ipsec_spd_add_del_entry
3638 {
3639   u32 client_index;
3640   u32 context;
3641   u8 is_add;
3642
3643   u32 spd_id;
3644   i32 priority;
3645   u8 is_outbound;
3646
3647   // Selector
3648   u8 is_ipv6;
3649   u8 is_ip_any;
3650   u8 remote_address_start[16];
3651   u8 remote_address_stop[16];
3652   u8 local_address_start[16];
3653   u8 local_address_stop[16];
3654
3655   u8 protocol;
3656
3657   u16 remote_port_start;
3658   u16 remote_port_stop;
3659   u16 local_port_start;
3660   u16 local_port_stop;
3661
3662   // Policy
3663   u8 policy;
3664   u32 sa_id;
3665 };
3666
3667 /** \brief Reply for IPsec: Add/delete Security Policy Database entry
3668     @param context - returned sender context, to match reply w/ request
3669     @param retval - return code
3670 */
3671
3672 define ipsec_spd_add_del_entry_reply
3673 {
3674   u32 context;
3675   i32 retval;
3676 };
3677
3678 /** \brief IPsec: Add/delete Security Association Database entry
3679     @param client_index - opaque cookie to identify the sender
3680     @param context - sender context, to match reply w/ request
3681     @param is_add - add SAD entry if non-zero, else delete
3682
3683     @param sad_id - sad id
3684
3685     @param spi - security parameter index
3686
3687     @param protocol - 0 = AH, 1 = ESP
3688
3689     @param crypto_algorithm - 0 = Null, 1 = AES-CBC-128, 2 = AES-CBC-192, 3 = AES-CBC-256, 4 = 3DES-CBC
3690     @param crypto_key_length - length of crypto_key in bytes
3691     @param crypto_key - crypto keying material
3692
3693     @param integrity_algorithm - 0 = None, 1 = MD5-96, 2 = SHA1-96, 3 = SHA-256, 4 = SHA-384, 5=SHA-512
3694     @param integrity_key_length - length of integrity_key in bytes
3695     @param integrity_key - integrity keying material
3696
3697     @param use_extended_sequence_number - use ESN when non-zero
3698
3699     @param is_tunnel - IPsec tunnel mode if non-zero, else transport mode
3700     @param is_tunnel_ipv6 - IPsec tunnel mode is IPv6 if non-zero, else IPv4 tunnel only valid if is_tunnel is non-zero
3701     @param tunnel_src_address - IPsec tunnel source address IPv6 if is_tunnel_ipv6 is non-zero, else IPv4. Only valid if is_tunnel is non-zero
3702     @param tunnel_dst_address - IPsec tunnel destination address IPv6 if is_tunnel_ipv6 is non-zero, else IPv4. Only valid if is_tunnel is non-zero
3703
3704     To be added:
3705      Anti-replay
3706      IPsec tunnel address copy mode (to support GDOI)
3707  */
3708
3709 define ipsec_sad_add_del_entry
3710 {
3711   u32 client_index;
3712   u32 context;
3713   u8 is_add;
3714
3715   u32 sad_id;
3716
3717   u32 spi;
3718
3719   u8 protocol;
3720
3721   u8 crypto_algorithm;
3722   u8 crypto_key_length;
3723   u8 crypto_key[128];
3724
3725   u8 integrity_algorithm;
3726   u8 integrity_key_length;
3727   u8 integrity_key[128];
3728
3729   u8 use_extended_sequence_number;
3730
3731   u8 is_tunnel;
3732   u8 is_tunnel_ipv6;
3733   u8 tunnel_src_address[16];
3734   u8 tunnel_dst_address[16];
3735 };
3736
3737 /** \brief Reply for IPsec: Add/delete Security Association Database entry
3738     @param context - returned sender context, to match reply w/ request
3739     @param retval - return code
3740 */
3741
3742 define ipsec_sad_add_del_entry_reply
3743 {
3744   u32 context;
3745   i32 retval;
3746 };
3747
3748 /** \brief IPsec: Update Security Association keys
3749     @param client_index - opaque cookie to identify the sender
3750     @param context - sender context, to match reply w/ request
3751
3752     @param sa_id - sa id
3753
3754     @param crypto_key_length - length of crypto_key in bytes
3755     @param crypto_key - crypto keying material
3756
3757     @param integrity_key_length - length of integrity_key in bytes
3758     @param integrity_key - integrity keying material
3759 */
3760
3761 define ipsec_sa_set_key
3762 {
3763   u32 client_index;
3764   u32 context;
3765
3766   u32 sa_id;
3767
3768   u8 crypto_key_length;
3769   u8 crypto_key[128];
3770
3771   u8 integrity_key_length;
3772   u8 integrity_key[128];
3773 };
3774
3775 /** \brief Reply for IPsec: Update Security Association keys
3776     @param context - returned sender context, to match reply w/ request
3777     @param retval - return code
3778 */
3779
3780 define ipsec_sa_set_key_reply
3781 {
3782   u32 context;
3783   i32 retval;
3784 };
3785
3786 /** \brief IKEv2: Add/delete profile
3787     @param client_index - opaque cookie to identify the sender
3788     @param context - sender context, to match reply w/ request
3789
3790     @param name - IKEv2 profile name
3791     @param is_add - Add IKEv2 profile if non-zero, else delete
3792 */
3793 define ikev2_profile_add_del
3794 {
3795   u32 client_index;
3796   u32 context;
3797
3798   u8 name[64];
3799   u8 is_add;
3800 };
3801
3802 /** \brief Reply for IKEv2: Add/delete profile
3803     @param context - returned sender context, to match reply w/ request
3804     @param retval - return code
3805 */
3806 define ikev2_profile_add_del_reply
3807 {
3808   u32 context;
3809   i32 retval;
3810 };
3811
3812 /** \brief IKEv2: Set IKEv2 profile authentication method
3813     @param client_index - opaque cookie to identify the sender
3814     @param context - sender context, to match reply w/ request
3815
3816     @param name - IKEv2 profile name
3817     @param auth_method - IKEv2 authentication method (shared-key-mic/rsa-sig)
3818     @param is_hex - Authentication data in hex format if non-zero, else string
3819     @param data_len - Authentication data length
3820     @param data - Authentication data (for rsa-sig cert file path)
3821 */
3822 define ikev2_profile_set_auth
3823 {
3824   u32 client_index;
3825   u32 context;
3826
3827   u8 name[64];
3828   u8 auth_method;
3829   u8 is_hex;
3830   u32 data_len;
3831   u8 data[0];
3832 };
3833
3834 /** \brief Reply for IKEv2: Set IKEv2 profile authentication method
3835     @param context - returned sender context, to match reply w/ request
3836     @param retval - return code
3837 */
3838 define ikev2_profile_set_auth_reply
3839 {
3840   u32 context;
3841   i32 retval;
3842 };
3843
3844 /** \brief IKEv2: Set IKEv2 profile local/remote identification
3845     @param client_index - opaque cookie to identify the sender
3846     @param context - sender context, to match reply w/ request
3847
3848     @param name - IKEv2 profile name
3849     @param is_local - Identification is local if non-zero, else remote
3850     @param id_type - Identification type
3851     @param data_len - Identification data length
3852     @param data - Identification data
3853 */
3854 define ikev2_profile_set_id
3855 {
3856   u32 client_index;
3857   u32 context;
3858
3859   u8 name[64];
3860   u8 is_local;
3861   u8 id_type;
3862   u32 data_len;
3863   u8 data[0];
3864 };
3865
3866 /** \brief Reply for IKEv2:
3867     @param context - returned sender context, to match reply w/ request
3868     @param retval - return code
3869 */
3870 define ikev2_profile_set_id_reply
3871 {
3872   u32 context;
3873   i32 retval;
3874 };
3875
3876 /** \brief IKEv2: Set IKEv2 profile traffic selector parameters
3877     @param client_index - opaque cookie to identify the sender
3878     @param context - sender context, to match reply w/ request
3879
3880     @param name - IKEv2 profile name
3881     @param is_local - Traffic selector is local if non-zero, else remote
3882     @param proto - Traffic selector IP protocol (if zero not relevant)
3883     @param start_port - The smallest port number allowed by traffic selector
3884     @param end_port - The largest port number allowed by traffic selector
3885     @param start_addr - The smallest address included in traffic selector
3886     @param end_addr - The largest address included in traffic selector
3887 */
3888 define ikev2_profile_set_ts
3889 {
3890   u32 client_index;
3891   u32 context;
3892
3893   u8 name[64];
3894   u8 is_local;
3895   u8 proto;
3896   u16 start_port;
3897   u16 end_port;
3898   u32 start_addr;
3899   u32 end_addr;
3900 };
3901
3902 /** \brief Reply for IKEv2: Set IKEv2 profile traffic selector parameters
3903     @param context - returned sender context, to match reply w/ request
3904     @param retval - return code
3905 */
3906 define ikev2_profile_set_ts_reply
3907 {
3908   u32 context;
3909   i32 retval;
3910 };
3911
3912 /** \brief IKEv2: Set IKEv2 local RSA private key
3913     @param client_index - opaque cookie to identify the sender
3914     @param context - sender context, to match reply w/ request
3915
3916     @param key_file - Key file absolute path
3917 */
3918 define ikev2_set_local_key
3919 {
3920   u32 client_index;
3921   u32 context;
3922
3923   u8 key_file[256];
3924 };
3925
3926 /** \brief Reply for IKEv2: Set IKEv2 local key
3927     @param context - returned sender context, to match reply w/ request
3928     @param retval - return code
3929 */
3930 define ikev2_set_local_key_reply
3931 {
3932   u32 context;
3933   i32 retval;
3934 };
3935
3936 /** \brief Tell client about a DHCP completion event
3937     @param client_index - opaque cookie to identify the sender
3938     @param pid - client pid registered to receive notification
3939     @param is_ipv6 - if non-zero the address is ipv6, else ipv4
3940     @param host_address - Host IP address
3941     @param router_address - Router IP address
3942     @param host_mac - Host MAC address
3943 */
3944 define dhcp_compl_event
3945 {
3946   u32 client_index;
3947   u32 pid;
3948   u8 hostname[64];
3949   u8 is_ipv6;
3950   u8 host_address[16];
3951   u8 router_address[16];
3952   u8 host_mac[6];
3953 };
3954
3955 /** \brief Add MAP domains
3956     @param client_index - opaque cookie to identify the sender
3957     @param context - sender context, to match reply w/ request
3958     @param ip6_prefix - Rule IPv6 prefix
3959     @param ip4_prefix - Rule IPv4 prefix
3960     @param ip6_src - MAP domain IPv6 BR address / Tunnel source
3961     @param ip6_prefix_len - Rule IPv6 prefix length
3962     @param ip4_prefix_len - Rule IPv4 prefix length
3963     @param ea_bits_len - Embedded Address bits length
3964     @param psid_offset - Port Set Identifider (PSID) offset
3965     @param psid_length - PSID length
3966     @param is_translation - MAP-E / MAP-T
3967     @param mtu - MTU
3968 */
3969 define map_add_domain
3970 {
3971   u32 client_index;
3972   u32 context;
3973   u8 ip6_prefix[16];
3974   u8 ip4_prefix[4];
3975   u8 ip6_src[16];
3976   u8 ip6_prefix_len;
3977   u8 ip4_prefix_len;
3978   u8 ip6_src_prefix_len;
3979   u8 ea_bits_len;
3980   u8 psid_offset;
3981   u8 psid_length;
3982   u8 is_translation;
3983   u16 mtu;
3984 };
3985
3986 /** \brief Reply for MAP domain add
3987     @param context - returned sender context, to match reply w/ request
3988     @param index - MAP domain index
3989     @param retval - return code
3990 */
3991 define map_add_domain_reply
3992 {
3993   u32 context;
3994   u32 index;
3995   i32 retval;
3996 };
3997
3998 /** \brief Delete MAP domain
3999     @param client_index - opaque cookie to identify the sender
4000     @param context - sender context, to match reply w/ request
4001     @param index - MAP Domain index
4002 */
4003 define map_del_domain
4004 {
4005   u32 client_index;
4006   u32 context;
4007   u32 index;
4008 };
4009
4010 /** \brief Reply for MAP domain del
4011     @param context - returned sender context, to match reply w/ request
4012     @param retval - return code
4013 */
4014 define map_del_domain_reply
4015 {
4016   u32 context;
4017   i32 retval;
4018 };
4019
4020 /** \brief Add or Delete MAP rule from a domain (Only used for shared IPv4 per subscriber)
4021     @param client_index - opaque cookie to identify the sender
4022     @param context - sender context, to match reply w/ request
4023     @param index - MAP Domain index
4024     @param is_add - If 1 add rule, if 0 delete rule
4025     @param ip6_dst - MAP CE IPv6 address
4026     @param psid - Rule PSID
4027 */
4028 define map_add_del_rule
4029 {
4030   u32 client_index;
4031   u32 context;
4032   u32 index;
4033   u32 is_add;
4034   u8 ip6_dst[16];
4035   u16 psid;
4036 };
4037
4038 /** \brief Reply for MAP rule add/del
4039     @param context - returned sender context, to match reply w/ request
4040     @param retval - return code
4041 */
4042 define map_add_del_rule_reply
4043 {
4044   u32 context;
4045   i32 retval;
4046 };
4047
4048 /** \brief Get list of map domains
4049     @param client_index - opaque cookie to identify the sender
4050 */
4051 define map_domain_dump
4052 {
4053   u32 client_index;
4054   u32 context;
4055 };
4056
4057 define map_domain_details
4058 {
4059   u32 context;
4060   u32 domain_index;
4061   u8 ip6_prefix[16];
4062   u8 ip4_prefix[4];
4063   u8 ip6_src[16];
4064   u8 ip6_prefix_len;
4065   u8 ip4_prefix_len;
4066   u8 ip6_src_len;
4067   u8 ea_bits_len;
4068   u8 psid_offset;
4069   u8 psid_length;
4070   u8 flags;
4071   u16 mtu;
4072   u8 is_translation;
4073 };
4074
4075 define map_rule_dump
4076 {
4077   u32 client_index;
4078   u32 context;
4079   u32 domain_index;
4080 };
4081
4082 define map_rule_details
4083 {
4084   u32 context;
4085   u8 ip6_dst[16];
4086   u16 psid;
4087 };
4088
4089 /** \brief Request for a single block of summary stats
4090     @param client_index - opaque cookie to identify the sender
4091     @param context - sender context, to match reply w/ request
4092 */
4093 define map_summary_stats
4094 {
4095   u32 client_index;
4096   u32 context;
4097 };
4098
4099 /** \brief Reply for map_summary_stats request
4100     @param context - sender context, to match reply w/ request
4101     @param retval - return code for request
4102     @param total_bindings -  
4103     @param total_pkts -  
4104     @param total_ip4_fragments -
4105     @param total_security_check - 
4106 */
4107 define map_summary_stats_reply
4108 {
4109   u32 context;
4110   i32 retval;
4111   u64 total_bindings;
4112   u64 total_pkts[2];
4113   u64 total_bytes[2];
4114   u64 total_ip4_fragments;
4115   u64 total_security_check[2];
4116 };
4117
4118 /** \brief cop: enable/disable junk filtration features on an interface
4119     @param client_index - opaque cookie to identify the sender
4120     @param context - sender context, to match reply w/ request
4121     @param sw_if_inded - desired interface
4122     @param enable_disable - 1 => enable, 0 => disable
4123 */
4124
4125 define cop_interface_enable_disable
4126 {
4127   u32 client_index;
4128   u32 context;
4129   u32 sw_if_index;
4130   u8 enable_disable;
4131 };
4132
4133 /** \brief cop: interface enable/disable junk filtration reply
4134     @param context - returned sender context, to match reply w/ request
4135     @param retval - return code
4136 */
4137
4138 define cop_interface_enable_disable_reply
4139 {
4140   u32 context;
4141   i32 retval;
4142 };
4143
4144 /** \brief cop: enable/disable whitelist filtration features on an interface
4145     Note: the supplied fib_id must match in order to remove the feature!
4146     
4147     @param client_index - opaque cookie to identify the sender
4148     @param context - sender context, to match reply w/ request
4149     @param sw_if_index - interface handle, physical interfaces only
4150     @param fib_id - fib identifier for the whitelist / blacklist fib
4151     @param ip4 - 1 => enable ip4 filtration, 0=> disable ip4 filtration
4152     @param ip6 - 1 => enable ip6 filtration, 0=> disable ip6 filtration
4153     @param default_cop -  1 => enable non-ip4, non-ip6 filtration 0=> disable it
4154 */
4155
4156 define cop_whitelist_enable_disable
4157 {
4158   u32 client_index;
4159   u32 context;
4160   u32 sw_if_index;
4161   u32 fib_id;
4162   u8 ip4;
4163   u8 ip6;
4164   u8 default_cop;
4165 };
4166
4167 /** \brief cop: interface enable/disable junk filtration reply
4168     @param context - returned sender context, to match reply w/ request
4169     @param retval - return code
4170 */
4171
4172 define cop_whitelist_enable_disable_reply
4173 {
4174   u32 context;
4175   i32 retval;
4176 };
4177
4178 /** \brief get_node_graph - get a copy of the vpp node graph
4179     including the current set of graph arcs.
4180
4181     @param client_index - opaque cookie to identify the sender
4182     @param context - sender context, to match reply w/ request
4183 */
4184
4185 define get_node_graph
4186 {
4187   u32 client_index;
4188   u32 context;
4189 };
4190
4191 /** \brief get_node_graph_reply
4192     @param context - returned sender context, to match reply w/ request
4193     @param retval - return code
4194     @param reply_in_shmem - result from vlib_node_serialize, in shared
4195     memory. Process with vlib_node_unserialize, remember to switch
4196     heaps and free the result.
4197 */
4198
4199 define get_node_graph_reply
4200 {
4201   u32 context;
4202   i32 retval;
4203   u64 reply_in_shmem;
4204 };
4205
4206 /** \brief Clear interface statistics
4207     @param client_index - opaque cookie to identify the sender
4208     @param context - sender context, to match reply w/ request
4209     @param sw_if_index - index of the interface to clear statistics
4210 */
4211 define sw_interface_clear_stats
4212 {
4213   u32 client_index;
4214   u32 context;
4215   u32 sw_if_index;
4216 };
4217
4218 /** \brief Reply to sw_interface_clear_stats 
4219     @param context - sender context which was passed in the request
4220     @param retval - return code of the set flags request
4221 */
4222 define sw_interface_clear_stats_reply
4223 {
4224   u32 context;
4225   i32 retval;
4226 };
4227
4228 /** \brief IOAM enable : Enable in-band OAM
4229     @param id - profile id
4230     @param seqno - To enable Seqno Processing
4231     @param analyse - Enabling analysis of iOAM at decap node 
4232     @param pow_enable - Proof of Work enabled or not flag
4233     @param trace_enable - iOAM Trace enabled or not flag
4234 */
4235 define ioam_enable
4236 {
4237   u32 client_index;
4238   u32 context;
4239   u16 id;
4240   u8 seqno;
4241   u8 analyse;
4242   u8 pot_enable;
4243   u8 trace_enable;
4244   u32 node_id;
4245 };
4246
4247 /** \brief iOAM Trace profile add / del response
4248     @param context - sender context, to match reply w/ request
4249     @param retval - return value for request
4250 */
4251 define ioam_enable_reply
4252 {
4253   u32 context;
4254   i32 retval;
4255 };
4256
4257 /** \brief iOAM disable
4258     @param client_index - opaque cookie to identify the sender
4259     @param context - sender context, to match reply w/ request
4260     @param index - MAP Domain index
4261 */
4262 define ioam_disable
4263 {
4264   u32 client_index;
4265   u32 context;
4266   u16 id;
4267 };
4268
4269 /** \brief iOAM disable response
4270     @param context - sender context, to match reply w/ request
4271     @param retval - return value for request
4272 */
4273 define ioam_disable_reply
4274 {
4275   u32 context;
4276   i32 retval;
4277 };
4278
4279 /** \brief Create host-interface
4280     @param client_index - opaque cookie to identify the sender
4281     @param context - sender context, to match reply w/ request
4282     @param host_if_name - interface name
4283     @param hw_addr - interface MAC
4284     @param use_random_hw_addr - use random generated MAC
4285 */
4286 define af_packet_create
4287 {
4288   u32 client_index;
4289   u32 context;
4290
4291   u8 host_if_name[64];
4292   u8 hw_addr[6];
4293   u8 use_random_hw_addr;
4294 };
4295
4296 /** \brief Create host-interface response
4297     @param context - sender context, to match reply w/ request
4298     @param retval - return value for request
4299 */
4300 define af_packet_create_reply
4301 {
4302   u32 context;
4303   i32 retval;
4304   u32 sw_if_index;
4305 };
4306
4307 /** \brief Delete host-interface
4308     @param client_index - opaque cookie to identify the sender
4309     @param context - sender context, to match reply w/ request
4310     @param host_if_name - interface name
4311 */
4312 define af_packet_delete
4313 {
4314   u32 client_index;
4315   u32 context;
4316
4317   u8 host_if_name[64];
4318 };
4319
4320 /** \brief Delete host-interface response
4321     @param context - sender context, to match reply w/ request
4322     @param retval - return value for request
4323 */
4324 define af_packet_delete_reply
4325 {
4326   u32 context;
4327   i32 retval;
4328 };
4329
4330 /** \brief Add/del policer
4331     @param client_index - opaque cookie to identify the sender
4332     @param context - sender context, to match reply w/ request
4333     @param is_add - add policer if non-zero, else delete
4334     @param name - policer name
4335     @param cir - CIR
4336     @param eir - EIR
4337     @param cb - Committed Burst
4338     @param eb - Excess or Peak Burst
4339     @param rate_type - rate type
4340     @param round_type - rounding type
4341     @param type - policer algorithm
4342     @param color_aware - 0=color-blind, 1=color-aware
4343     @param conform_action_type - conform action type
4344     @param conform_dscp - DSCP for conform mar-and-transmit action
4345     @param exceed_action_type - exceed action type
4346     @param exceed_dscp - DSCP for exceed mar-and-transmit action
4347     @param violate_action_type - violate action type
4348     @param violate_dscp - DSCP for violate mar-and-transmit action
4349 */
4350 define policer_add_del
4351 {
4352   u32 client_index;
4353   u32 context;
4354
4355   u8 is_add;
4356   u8 name[64];
4357   u32 cir;
4358   u32 eir;
4359   u64 cb;
4360   u64 eb;
4361   u8 rate_type;
4362   u8 round_type;
4363   u8 type;
4364   u8 color_aware;
4365   u8 conform_action_type;
4366   u8 conform_dscp;
4367   u8 exceed_action_type;
4368   u8 exceed_dscp;
4369   u8 violate_action_type;
4370   u8 violate_dscp;
4371 };
4372
4373 /** \brief Add/del policer response
4374     @param context - sender context, to match reply w/ request
4375     @param retval - return value for request
4376     @param policer_index - for add, returned index of the new policer
4377 */
4378 define policer_add_del_reply
4379 {
4380   u32 context;
4381   i32 retval;
4382   u32 policer_index;
4383 };
4384
4385 /** \brief Get list of policers
4386     @param client_index - opaque cookie to identify the sender
4387     @param context - sender context, to match reply w/ request
4388     @param match_name_valid - if 0 request all policers otherwise use match_name
4389     @param match_name - policer name
4390 */
4391 define policer_dump
4392 {
4393   u32 client_index;
4394   u32 context;
4395
4396   u8 match_name_valid;
4397   u8 match_name[64];
4398 };
4399
4400 /** \brief Policer operational state response.
4401     @param context - sender context, to match reply w/ request
4402     @param name - policer name
4403     @param cir - CIR
4404     @param eir - EIR
4405     @param cb - Committed Burst
4406     @param eb - Excess or Peak Burst
4407     @param rate_type - rate type
4408     @param round_type - rounding type
4409     @param type - policer algorithm
4410     @param conform_action_type - conform action type
4411     @param conform_dscp - DSCP for conform mar-and-transmit action
4412     @param exceed_action_type - exceed action type
4413     @param exceed_dscp - DSCP for exceed mar-and-transmit action
4414     @param violate_action_type - violate action type
4415     @param violate_dscp - DSCP for violate mar-and-transmit action
4416     @param single_rate - 1 = single rate policer, 0 = two rate policer
4417     @param color_aware - for hierarchical policing
4418     @param scale - power-of-2 shift amount for lower rates
4419     @param cir_tokens_per_period - number of tokens for each period
4420     @param pir_tokens_per_period - number of tokens for each period for 2-rate policer
4421     @param current_limit - current limit
4422     @param current_bucket - current bucket
4423     @param extended_limit - extended limit
4424     @param extended_bucket - extended bucket
4425     @param last_update_time - last update time
4426 */
4427 define policer_details
4428 {
4429   u32 context;
4430
4431   u8 name[64];
4432   u32 cir;
4433   u32 eir;
4434   u64 cb;
4435   u64 eb;
4436   u8 rate_type;
4437   u8 round_type;
4438   u8 type;
4439   u8 conform_action_type;
4440   u8 conform_dscp;
4441   u8 exceed_action_type;
4442   u8 exceed_dscp;
4443   u8 violate_action_type;
4444   u8 violate_dscp;
4445   u8 single_rate;
4446   u8 color_aware;
4447   u32 scale;
4448   u32 cir_tokens_per_period;
4449   u32 pir_tokens_per_period;
4450   u32 current_limit;
4451   u32 current_bucket;
4452   u32 extended_limit;
4453   u32 extended_bucket;
4454   u64 last_update_time;
4455 };
4456
4457 /** \brief Set/unset policer classify interface
4458     @param client_index - opaque cookie to identify the sender
4459     @param context - sender context, to match reply w/ request
4460     @param sw_if_index - interface to set/unset policer classify
4461     @param ip4_table_index - ip4 classify table index (~0 for skip)
4462     @param ip6_table_index - ip6 classify table index (~0 for skip)
4463     @param l2_table_index  -  l2 classify table index (~0 for skip)
4464     @param is_add - Set if non-zero, else unset
4465     Note: User is recommeneded to use just one valid table_index per call.
4466           (ip4_table_index, ip6_table_index, or l2_table_index)
4467 */
4468 define policer_classify_set_interface
4469 {
4470   u32 client_index;
4471   u32 context;
4472   u32 sw_if_index;
4473   u32 ip4_table_index;
4474   u32 ip6_table_index;
4475   u32 l2_table_index;
4476   u8 is_add;
4477 };
4478
4479 /** \brief Set/unset policer classify interface response
4480     @param context - sender context, to match reply w/ request
4481     @param retval - return value for request
4482 */
4483 define policer_classify_set_interface_reply
4484 {
4485   u32 context;
4486   i32 retval;
4487 };
4488
4489 /** \brief Get list of policer classify interfaces and tables
4490     @param client_index - opaque cookie to identify the sender
4491     @param context - sender context, to match reply w/ request
4492     @param type - classify table type
4493 */
4494 define policer_classify_dump
4495 {
4496   u32 client_index;
4497   u32 context;
4498   u8 type;
4499 };
4500
4501 /** \brief Policer iclassify operational state response.
4502     @param context - sender context, to match reply w/ request
4503     @param sw_if_index - software interface index
4504     @param table_index - classify table index
4505 */
4506 define policer_classify_details
4507 {
4508   u32 context;
4509   u32 sw_if_index;
4510   u32 table_index;
4511 };
4512
4513 /** \brief Create netmap
4514     @param client_index - opaque cookie to identify the sender
4515     @param context - sender context, to match reply w/ request
4516     @param netmap_if_name - interface name
4517     @param hw_addr - interface MAC
4518     @param use_random_hw_addr - use random generated MAC
4519     @param is_pipe - is pipe
4520     @param is_master - 0=slave, 1=master
4521 */
4522 define netmap_create
4523 {
4524   u32 client_index;
4525   u32 context;
4526
4527   u8 netmap_if_name[64];
4528   u8 hw_addr[6];
4529   u8 use_random_hw_addr;
4530   u8 is_pipe;
4531   u8 is_master;
4532 };
4533
4534 /** \brief Create netmap response
4535     @param context - sender context, to match reply w/ request
4536     @param retval - return value for request
4537 */
4538 define netmap_create_reply
4539 {
4540   u32 context;
4541   i32 retval;
4542 };
4543
4544 /** \brief Delete netmap
4545     @param client_index - opaque cookie to identify the sender
4546     @param context - sender context, to match reply w/ request
4547     @param netmap_if_name - interface name
4548 */
4549 define netmap_delete
4550 {
4551   u32 client_index;
4552   u32 context;
4553
4554   u8 netmap_if_name[64];
4555 };
4556
4557 /** \brief Delete netmap response
4558     @param context - sender context, to match reply w/ request
4559     @param retval - return value for request
4560 */
4561 define netmap_delete_reply
4562 {
4563   u32 context;
4564   i32 retval;
4565 };
4566
4567 /** \brief Dump mpls gre tunnel table
4568     @param client_index - opaque cookie to identify the sender
4569     @param tunnel_index - gre tunnel identifier or -1 in case of all tunnels
4570 */
4571 define mpls_gre_tunnel_dump
4572 {
4573   u32 client_index;
4574   u32 context;
4575   i32 tunnel_index;
4576 };
4577
4578 /** \brief mpls gre tunnel operational state response
4579     @param tunnel_index - gre tunnel identifier
4580     @param intfc_address - interface ipv4 addr
4581     @param mask_width - interface ipv4 addr mask
4582     @param hw_if_index - interface id
4583     @param l2_only -
4584     @param tunnel_src - tunnel source ipv4 addr
4585     @param tunnel_dst - tunnel destination ipv4 addr
4586     @param outer_fib_index - gre tunnel identifier
4587     @param encap_index - reference to mpls label table
4588     @param nlabels - number of resolved labels
4589     @param labels - resolved labels
4590 */
4591 define mpls_gre_tunnel_details
4592 {
4593   u32 context;
4594   u32 tunnel_index;
4595
4596   u32 intfc_address;
4597   u32 inner_fib_index;
4598   u32 mask_width;
4599   u32 encap_index;
4600   u32 hw_if_index;
4601   u8 l2_only;
4602   u32 tunnel_src;
4603   u32 tunnel_dst;
4604   u32 outer_fib_index;
4605   u32 nlabels;
4606   u32 labels[nlabels];
4607 };
4608
4609 /** \brief Dump mpls eth tunnel table
4610     @param client_index - opaque cookie to identify the sender
4611     @param tunnel_index - eth tunnel identifier or -1 in case of all tunnels
4612 */
4613 define mpls_eth_tunnel_dump
4614 {
4615   u32 client_index;
4616   u32 context;
4617   i32 tunnel_index;
4618 };
4619
4620 /** \brief mpls eth tunnel operational state response
4621     @param tunnel_index - eth tunnel identifier
4622     @param intfc_address - interface ipv4 addr
4623     @param mask_width - interface ipv4 addr mask
4624     @param hw_if_index - interface id
4625     @param l2_only -
4626     @param tunnel_dst_mac -
4627     @param tx_sw_if_index -
4628     @param encap_index - reference to mpls label table
4629     @param nlabels - number of resolved labels
4630     @param labels - resolved labels
4631 */
4632 define mpls_eth_tunnel_details
4633 {
4634   u32 context;
4635   u32 tunnel_index;
4636
4637   u32 intfc_address;
4638   u32 inner_fib_index;
4639   u32 mask_width;
4640   u32 encap_index;
4641   u32 hw_if_index;
4642   u8 l2_only;
4643   u8 tunnel_dst_mac[6];
4644   u32 tx_sw_if_index;
4645   u32 nlabels;
4646   u32 labels[nlabels];
4647 };
4648
4649 /** \brief Dump mpls fib table
4650     @param client_index - opaque cookie to identify the sender
4651     @param fib_index    - mpls fib entry identifier or -1 in case of all entries
4652 */
4653 define mpls_fib_encap_dump
4654 {
4655   u32 client_index;
4656   u32 context;
4657 };
4658
4659 /** \brief mpls fib encap table response
4660     @param fib_index - fib table id
4661     @param dest - destination ipv4 addr
4662     @param s_bit -
4663     @param entry_index - reference to mpls label table
4664     @param nlabels - number of resolved labels
4665     @param labels - resolved labels
4666 */
4667 define mpls_fib_encap_details
4668 {
4669   u32 context;
4670
4671   u32 fib_index;
4672   u32 entry_index;
4673   u32 dest;
4674   u32 s_bit;
4675   u32 nlabels;
4676   u32 labels[nlabels];
4677 };
4678
4679 /** \brief Classify get table IDs request
4680     @param client_index - opaque cookie to identify the sender
4681     @param context - sender context, to match reply w/ request
4682 */
4683 define classify_table_ids
4684 {
4685   u32 client_index;
4686   u32 context;
4687 };
4688
4689 /** \brief Reply for classify get table IDs request
4690     @param context - sender context which was passed in the request
4691     @param count - number of ids returned in response
4692     @param ids - array of classify table ids
4693 */
4694 define classify_table_ids_reply
4695 {
4696   u32 context;
4697   i32 retval;
4698   u32 count;
4699   u32 ids[count];
4700 };
4701
4702 /** \brief Classify table ids by interface index request
4703     @param client_index - opaque cookie to identify the sender
4704     @param context - sender context, to match reply w/ request
4705     @param sw_if_index - index of the interface
4706 */
4707 define classify_table_by_interface
4708 {
4709   u32 client_index;
4710   u32 context;
4711   u32 sw_if_index;
4712 };
4713
4714 /** \brief Reply for classify table id by interface index request
4715     @param context - sender context which was passed in the request
4716     @param count - number of ids returned in response
4717     @param sw_if_index - index of the interface
4718     @param l2_table_id - l2 classify table index
4719     @param ip4_table_id - ip4 classify table index
4720     @param ip6_table_id - ip6 classify table index
4721 */
4722 define classify_table_by_interface_reply
4723 {
4724   u32 context;
4725   i32 retval;
4726   u32 sw_if_index;
4727   u32 l2_table_id;
4728   u32 ip4_table_id;
4729   u32 ip6_table_id;
4730 };
4731
4732 /** \brief Classify table info
4733     @param client_index - opaque cookie to identify the sender
4734     @param context - sender context, to match reply w/ request
4735     @param table_id - classify table index
4736 */
4737 define classify_table_info
4738 {
4739   u32 client_index;
4740   u32 context;
4741   u32 table_id;
4742 };
4743
4744 /** \brief Reply for classify table info request
4745     @param context - sender context which was passed in the request
4746     @param count - number of ids returned in response
4747     @param table_id - classify table index
4748     @param nbuckets - number of buckets when adding a table
4749     @param match_n_vectors - number of match vectors
4750     @param skip_n_vectors - number of skip_n_vectors
4751     @param active_sessions - number of sessions (active entries)
4752     @param next_table_index - index of next table
4753     @param miss_next_index - index of miss table
4754     @param mask[] - match mask
4755 */
4756 define classify_table_info_reply
4757 {
4758   u32 context;
4759   i32 retval;
4760   u32 table_id;
4761   u32 nbuckets;
4762   u32 match_n_vectors;
4763   u32 skip_n_vectors;
4764   u32 active_sessions;
4765   u32 next_table_index;
4766   u32 miss_next_index;
4767   u32 mask_length;
4768   u8 mask[mask_length];
4769 };
4770
4771 /** \brief Classify sessions dump request
4772     @param client_index - opaque cookie to identify the sender
4773     @param context - sender context, to match reply w/ request
4774     @param table_id - classify table index
4775 */
4776 define classify_session_dump
4777 {
4778   u32 client_index;
4779   u32 context;
4780   u32 table_id;
4781 };
4782
4783 /** \brief Reply for classify table session dump request
4784     @param context - sender context which was passed in the request
4785     @param count - number of ids returned in response
4786     @param table_id - classify table index
4787     @param hit_next_index - hit_next_index of session
4788     @param opaque_index - for add, opaque_index of session
4789     @param advance - advance value of session
4790     @param match[] - match value for session
4791 */
4792 define classify_session_details
4793 {
4794   u32 context;
4795   i32 retval;
4796   u32 table_id;
4797   u32 hit_next_index;
4798   i32 advance;
4799   u32 opaque_index;
4800   u32 match_length;
4801   u8 match[match_length];
4802 };
4803
4804 /** \brief Configure IPFIX exporter process request
4805     @param client_index - opaque cookie to identify the sender
4806     @param context - sender context, to match reply w/ request
4807     @param collector_address - address of IPFIX collector
4808     @param collector_port - port of IPFIX collector
4809     @param src_address - address of IPFIX exporter
4810     @param vrf_id - VRF / fib table ID
4811     @param path_mtu - Path MTU between exporter and collector
4812     @param template_interval - number of seconds after which to resend template
4813     @param udp_checksum - UDP checksum calculation enable flag
4814 */
4815 define set_ipfix_exporter
4816 {
4817   u32 client_index;
4818   u32 context;
4819   u8 collector_address[16];
4820   u16 collector_port;
4821   u8 src_address[16];
4822   u32 vrf_id;
4823   u32 path_mtu;
4824   u32 template_interval;
4825   u8 udp_checksum;
4826 };
4827
4828 /** \brief Reply to IPFIX exporter configure request
4829     @param context - sender context which was passed in the request
4830 */
4831 define set_ipfix_exporter_reply
4832 {
4833   u32 context;
4834   i32 retval;
4835 };
4836
4837 /** \brief IPFIX exporter dump request
4838     @param client_index - opaque cookie to identify the sender
4839     @param context - sender context, to match reply w/ request
4840 */
4841 define ipfix_exporter_dump
4842 {
4843   u32 client_index;
4844   u32 context;
4845 };
4846
4847 /** \brief Reply to IPFIX exporter dump request
4848     @param context - sender context which was passed in the request
4849     @param collector_address - address of IPFIX collector
4850     @param collector_port - port of IPFIX collector
4851     @param src_address - address of IPFIX exporter
4852     @param fib_index - fib table index
4853     @param path_mtu - Path MTU between exporter and collector
4854     @param template_interval - number of seconds after which to resend template
4855     @param udp_checksum - UDP checksum calculation enable flag
4856 */
4857 define ipfix_exporter_details
4858 {
4859   u32 context;
4860   u8 collector_address[16];
4861   u16 collector_port;
4862   u8 src_address[16];
4863   u32 vrf_id;
4864   u32 path_mtu;
4865   u32 template_interval;
4866   u8 udp_checksum;
4867 };
4868
4869 /** \brief IPFIX classify stream configure request
4870     @param client_index - opaque cookie to identify the sender
4871     @param context - sender context, to match reply w/ request
4872     @param domain_id - domain ID reported in IPFIX messages for classify stream
4873     @param src_port - source port of UDP session for classify stream
4874 */
4875 define set_ipfix_classify_stream {
4876     u32 client_index;
4877     u32 context;
4878     u32 domain_id;
4879     u16 src_port;
4880 };
4881
4882 /** \brief IPFIX classify stream configure response
4883     @param context - sender context, to match reply w/ request
4884     @param retval - return value for request
4885 */
4886 define set_ipfix_classify_stream_reply {
4887     u32 context;
4888     i32 retval;
4889 };
4890
4891 /** \brief IPFIX classify stream dump request
4892     @param client_index - opaque cookie to identify the sender
4893     @param context - sender context, to match reply w/ request
4894 */
4895 define ipfix_classify_stream_dump {
4896     u32 client_index;
4897     u32 context;
4898 };
4899
4900 /** \brief Reply to IPFIX classify stream dump request
4901     @param context - sender context, to match reply w/ request
4902     @param domain_id - domain ID reported in IPFIX messages for classify stream
4903     @param src_port - source port of UDP session for classify stream
4904 */
4905 define ipfix_classify_stream_details {
4906     u32 context;
4907     u32 domain_id;
4908     u16 src_port;
4909 };
4910
4911 /** \brief IPFIX add or delete classifier table request
4912     @param client_index - opaque cookie to identify the sender
4913     @param context - sender context, to match reply w/ request
4914     @param table_id - classifier table ID
4915     @param ip_version - version of IP used in the classifier table
4916     @param transport_protocol - transport protocol used in the classifier table or 255 for unspecified
4917 */
4918 define ipfix_classify_table_add_del {
4919     u32 client_index;
4920     u32 context;
4921     u32 table_id;
4922     u8 ip_version;
4923     u8 transport_protocol;
4924     u8 is_add;
4925 };
4926
4927 /** \brief IPFIX add classifier table response
4928     @param context - sender context which was passed in the request
4929 */
4930 define ipfix_classify_table_add_del_reply {
4931     u32 context;
4932     i32 retval;
4933 };
4934
4935 /** \brief IPFIX classify tables dump request
4936     @param client_index - opaque cookie to identify the sender
4937     @param context - sender context, to match reply w/ request
4938 */
4939 define ipfix_classify_table_dump {
4940     u32 client_index;
4941     u32 context;
4942 };
4943
4944 /** \brief Reply to IPFIX classify tables dump request
4945     @param context - sender context, to match reply w/ request
4946     @param table_id - classifier table ID
4947     @param ip_version - version of IP used in the classifier table
4948     @param transport_protocol - transport protocol used in the classifier table or 255 for unspecified
4949 */
4950 define ipfix_classify_table_details {
4951     u32 context;
4952     u32 table_id;
4953     u8 ip_version;
4954     u8 transport_protocol;
4955 };
4956
4957 /** \brief Set/unset flow classify interface
4958     @param client_index - opaque cookie to identify the sender
4959     @param context - sender context, to match reply w/ request
4960     @param sw_if_index - interface to set/unset flow classify
4961     @param ip4_table_index - ip4 classify table index (~0 for skip)
4962     @param ip6_table_index - ip6 classify table index (~0 for skip)
4963     @param l2_table_index  -  l2 classify table index (~0 for skip)
4964     @param is_add - Set if non-zero, else unset
4965     Note: User is recommeneded to use just one valid table_index per call.
4966           (ip4_table_index, ip6_table_index, or l2_table_index)
4967 */
4968 define flow_classify_set_interface {
4969     u32 client_index;
4970     u32 context;
4971     u32 sw_if_index;
4972     u32 ip4_table_index;
4973     u32 ip6_table_index;
4974     u8  is_add;
4975 };
4976
4977 /** \brief Set/unset flow classify interface response
4978     @param context - sender context, to match reply w/ request
4979     @param retval - return value for request
4980 */
4981 define flow_classify_set_interface_reply {
4982     u32 context;
4983     i32 retval;
4984 };
4985
4986 /** \brief Get list of flow classify interfaces and tables
4987     @param client_index - opaque cookie to identify the sender
4988     @param context - sender context, to match reply w/ request
4989     @param type - classify table type
4990 */
4991 define flow_classify_dump {
4992     u32 client_index;
4993     u32 context;
4994     u8 type;
4995 };
4996
4997 /** \brief Flow classify operational state response.
4998     @param context - sender context, to match reply w/ request
4999     @param sw_if_index - software interface index
5000     @param table_index - classify table index
5001 */
5002 define flow_classify_details {
5003     u32 context;
5004     u32 sw_if_index;
5005     u32 table_index;
5006 };
5007
5008 /** \brief Enable/Disable span to mirror traffic from one interface to another
5009     @param client_index - opaque cookie to identify the sender
5010     @param context - sender context which was passed in the request
5011     @param sw_if_index_from - interface to be mirorred
5012     @param sw_if_index_to - interface where the traffic is mirrored
5013     @param enable - 1 enable SPAN, 0 SPAN on given interface
5014 */
5015 define sw_interface_span_enable_disable{
5016     u32 client_index;
5017     u32 context;
5018     u32 sw_if_index_from;
5019     u32 sw_if_index_to;
5020     u8  enable;
5021 };
5022
5023 /** \brief Reply to SPAN enable/disable request
5024     @param context - sender context which was passed in the request
5025 */
5026 define sw_interface_span_enable_disable_reply {
5027     u32 context;
5028     i32 retval;
5029 };
5030
5031 /** \brief SPAN dump request
5032     @param client_index - opaque cookie to identify the sender
5033     @param context - sender context, to match reply w/ request
5034 */
5035 define sw_interface_span_dump {
5036     u32 client_index;
5037     u32 context;
5038 };
5039
5040 /** \brief Reply to SPAN dump request
5041     @param context - sender context which was passed in the request
5042     @param sw_if_index_from - mirorred interface
5043     @param sw_if_index_to - interface where the traffic is mirrored
5044 */
5045 define sw_interface_span_details {
5046     u32 context;
5047     u32 sw_if_index_from;
5048     u32 sw_if_index_to;
5049 };
5050
5051 /** \brief Query relative index via node names
5052     @param client_index - opaque cookie to identify the sender
5053     @param context - sender context, to match reply w/ request
5054     @param node_name - name of node to find relative index from
5055     @param next_name - next node from node_name to find relative index of
5056 */
5057 define get_next_index
5058 {
5059   u32 client_index;
5060   u32 context;
5061   u8 node_name[64];
5062   u8 next_name[64];
5063 };
5064
5065 /** \brief Reply for get next node index
5066     @param context - sender context which was passed in the request
5067     @param retval - return value
5068     @param next_index - index of the next_node
5069 */
5070 define get_next_index_reply
5071 {
5072   u32 context;
5073   i32 retval;
5074   u32 next_index;
5075 };
5076
5077 /** \brief PacketGenerator create interface request
5078     @param client_index - opaque cookie to identify the sender
5079     @param context - sender context, to match reply w/ request
5080     @param interface_id - interface index
5081 */
5082 define pg_create_interface
5083 {
5084   u32 client_index;
5085   u32 context;
5086   u32 interface_id;
5087 };
5088
5089 /** \brief PacketGenerator create interface response
5090     @param context - sender context, to match reply w/ request
5091     @param retval - return value for request
5092 */
5093 define pg_create_interface_reply
5094 {
5095   u32 context;
5096   i32 retval;
5097   u32 sw_if_index;
5098 };
5099
5100 /** \brief PacketGenerator capture packets on given interface request
5101     @param client_index - opaque cookie to identify the sender
5102     @param context - sender context, to match reply w/ request
5103     @param interface_id - pg interface index
5104     @param is_enabled - 1 if enabling streams, 0 if disabling
5105     @param count - number of packets to be captured
5106     @param pcap_file - pacp file name to store captured packets
5107 */
5108 define pg_capture
5109 {
5110   u32 client_index;
5111   u32 context;
5112   u32 interface_id;
5113   u8 is_enabled;
5114   u32 count;
5115   u32 pcap_name_length;
5116   u8 pcap_file_name[pcap_name_length];
5117 };
5118
5119 /** \brief PacketGenerator capture packets response
5120     @param context - sender context, to match reply w/ request
5121     @param retval - return value for request
5122 */
5123 define pg_capture_reply
5124 {
5125   u32 context;
5126   i32 retval;
5127 };
5128
5129 /** \brief Enable / disable packet generator request
5130     @param client_index - opaque cookie to identify the sender
5131     @param context - sender context, to match reply w/ request
5132     @param is_enabled - 1 if enabling streams, 0 if disabling
5133     @param stream - stream name to be enable/disabled, if not specified handle all streams
5134 */
5135 define pg_enable_disable
5136 {
5137   u32 client_index;
5138   u32 context;
5139   u8 is_enabled;
5140   u32 stream_name_length;
5141   u8 stream_name[stream_name_length];
5142 };
5143
5144 /** \brief Reply for enable / disable packet generator
5145     @param context - returned sender context, to match reply w/ request
5146     @param retval - return code
5147 */
5148 define pg_enable_disable_reply
5149 {
5150   u32 context;
5151   i32 retval;
5152 };
5153
5154 /** \brief Configure IP source and L4 port-range check
5155     @param client_index - opaque cookie to identify the sender
5156     @param context - sender context, to match reply w/ request
5157     @param is_ip6 - 1 if source address type is IPv6
5158     @param is_add - 1 if add, 0 if delete
5159     @param mask_length - mask length for address entry
5160     @param address - array of address bytes
5161     @param number_of_ranges - length of low_port and high_port arrays (must match)
5162     @param low_ports[32] - up to 32 low end of port range entries (must have corresponding high_ports entry)
5163     @param high_ports[32] - up to 32 high end of port range entries (must have corresponding low_ports entry)
5164     @param vrf_id - fib table/vrf id to associate the source and port-range check with
5165     @note To specify a single port set low_port and high_port entry the same
5166 */
5167 define ip_source_and_port_range_check_add_del
5168 {
5169   u32 client_index;
5170   u32 context;
5171   u8 is_ipv6;
5172   u8 is_add;
5173   u8 mask_length;
5174   u8 address[16];
5175   u8 number_of_ranges;
5176   u16 low_ports[32];
5177   u16 high_ports[32];
5178   u32 vrf_id;
5179 };
5180
5181 /** \brief Configure IP source and L4 port-range check reply
5182     @param context - returned sender context, to match reply w/ request
5183     @param retval - return code
5184 */
5185 define ip_source_and_port_range_check_add_del_reply
5186 {
5187   u32 context;
5188   i32 retval;
5189 };
5190
5191 /** \brief Set interface source and L4 port-range request
5192     @param client_index - opaque cookie to identify the sender
5193     @param context - sender context, to match reply w/ request
5194     @param interface_id - interface index
5195     @param tcp_vrf_id - VRF associated with source and TCP port-range check
5196     @param udp_vrf_id - VRF associated with source and TCP port-range check
5197 */
5198 define ip_source_and_port_range_check_interface_add_del
5199 {
5200   u32 client_index;
5201   u32 context;
5202   u8 is_add;
5203   u32 sw_if_index;
5204   u32 tcp_in_vrf_id;
5205   u32 tcp_out_vrf_id;
5206   u32 udp_in_vrf_id;
5207   u32 udp_out_vrf_id;
5208 };
5209
5210 /** \brief Set interface source and L4 port-range response
5211     @param context - sender context, to match reply w/ request
5212     @param retval - return value for request
5213 */
5214 define ip_source_and_port_range_check_interface_add_del_reply
5215 {
5216   u32 context;
5217   i32 retval;
5218 };
5219
5220 /** \brief Add / del ipsec gre tunnel request
5221     @param client_index - opaque cookie to identify the sender
5222     @param context - sender context, to match reply w/ request
5223     @param local_sa_id - local SA id
5224     @param remote_sa_id - remote SA id
5225     @param is_add - 1 if adding the tunnel, 0 if deleting
5226     @param src_address - tunnel source address
5227     @param dst_address - tunnel destination address
5228 */
5229 define ipsec_gre_add_del_tunnel {
5230     u32 client_index;
5231     u32 context;
5232     u32 local_sa_id;
5233     u32 remote_sa_id;
5234     u8 is_add;
5235     u8 src_address[4];
5236     u8 dst_address[4];
5237 };
5238
5239 /** \brief Reply for add / del ipsec gre tunnel request
5240     @param context - returned sender context, to match reply w/ request
5241     @param retval - return code
5242     @param sw_if_index - software index of the new ipsec gre tunnel
5243 */
5244 define ipsec_gre_add_del_tunnel_reply {
5245     u32 context;
5246     i32 retval;
5247     u32 sw_if_index;
5248 };
5249
5250 /** \brief Dump ipsec gre tunnel table
5251     @param client_index - opaque cookie to identify the sender
5252     @param context - sender context, to match reply w/ request
5253     @param tunnel_index - gre tunnel identifier or -1 in case of all tunnels
5254 */
5255 define ipsec_gre_tunnel_dump {
5256     u32 client_index;
5257     u32 context;
5258     u32 sw_if_index;
5259 };
5260
5261 /** \brief mpls gre tunnel operational state response
5262     @param context - returned sender context, to match reply w/ request
5263     @param sw_if_index - software index of the ipsec gre tunnel
5264     @param local_sa_id - local SA id
5265     @param remote_sa_id - remote SA id
5266     @param src_address - tunnel source address
5267     @param dst_address - tunnel destination address
5268 */
5269 define ipsec_gre_tunnel_details {
5270     u32 context;
5271     u32 sw_if_index;
5272     u32 local_sa_id;
5273     u32 remote_sa_id;
5274     u8 src_address[4];
5275     u8 dst_address[4];
5276 };
5277
5278 /** \brief Delete sub interface request
5279     @param client_index - opaque cookie to identify the sender
5280     @param context - sender context, to match reply w/ request
5281     @param sw_if_index - sw index of the interface that was created by create_subif
5282 */
5283 define delete_subif {
5284   u32 client_index;
5285   u32 context;
5286   u32 sw_if_index;
5287 };
5288
5289 /** \brief Delete sub interface response
5290     @param context - sender context, to match reply w/ request
5291     @param retval - return code for the request
5292 */
5293 define delete_subif_reply {
5294   u32 context;
5295   i32 retval;
5296 };
5297
5298 /** \brief DPDK interface HQoS pipe profile set request
5299     @param client_index - opaque cookie to identify the sender
5300     @param context - sender context, to match reply w/ request
5301     @param sw_if_index - the interface
5302     @param subport - subport ID
5303     @param pipe - pipe ID within its subport
5304     @param profile - pipe profile ID
5305 */
5306 define sw_interface_set_dpdk_hqos_pipe {
5307     u32 client_index;
5308     u32 context;
5309     u32 sw_if_index;
5310     u32 subport;
5311     u32 pipe;
5312     u32 profile;
5313 };
5314
5315 /** \brief DPDK interface HQoS pipe profile set reply
5316     @param context - sender context, to match reply w/ request
5317     @param retval - request return code
5318 */
5319 define sw_interface_set_dpdk_hqos_pipe_reply {
5320     u32 context;
5321     i32 retval;
5322 };
5323
5324 /** \brief DPDK interface HQoS subport parameters set request
5325     @param client_index - opaque cookie to identify the sender
5326     @param context - sender context, to match reply w/ request
5327     @param sw_if_index - the interface
5328     @param subport - subport ID
5329     @param tb_rate - subport token bucket rate (measured in bytes/second)
5330     @param tb_size - subport token bucket size (measured in credits)
5331     @param tc_rate - subport traffic class 0 .. 3 rates (measured in bytes/second)
5332     @param tc_period - enforcement period for rates (measured in milliseconds)
5333 */
5334 define sw_interface_set_dpdk_hqos_subport {
5335     u32 client_index;
5336     u32 context;
5337     u32 sw_if_index;
5338     u32 subport;
5339     u32 tb_rate;
5340     u32 tb_size;
5341     u32 tc_rate[4];
5342     u32 tc_period;
5343 };
5344
5345 /** \brief DPDK interface HQoS subport parameters set reply
5346     @param context - sender context, to match reply w/ request
5347     @param retval - request return code
5348 */
5349 define sw_interface_set_dpdk_hqos_subport_reply {
5350     u32 context;
5351     i32 retval;
5352 };
5353
5354 /** \brief DPDK interface HQoS tctbl entry set request
5355     @param client_index - opaque cookie to identify the sender
5356     @param context - sender context, to match reply w/ request
5357     @param sw_if_index - the interface
5358     @param entry - entry index ID
5359     @param tc - traffic class (0 .. 3)
5360     @param queue - traffic class queue (0 .. 3)
5361 */
5362 define sw_interface_set_dpdk_hqos_tctbl {
5363     u32 client_index;
5364     u32 context;
5365     u32 sw_if_index;
5366     u32 entry;
5367     u32 tc;
5368     u32 queue;
5369 };
5370
5371 /** \brief DPDK interface HQoS tctbl entry set reply
5372     @param context - sender context, to match reply w/ request
5373     @param retval - request return code
5374 */
5375 define sw_interface_set_dpdk_hqos_tctbl_reply {
5376     u32 context;
5377     i32 retval;
5378 };
5379
5380 /** \brief L2 interface pbb tag rewrite configure request
5381     @param client_index - opaque cookie to identify the sender
5382     @param context - sender context, to match reply w/ request
5383     @param sw_if_index - interface the operation is applied to
5384     @param vtr_op - Choose from l2_vtr_op_t enum values
5385     @param inner_tag - needed for translate_qinq vtr op only
5386     @param outer_tag - needed for translate_qinq vtr op only 
5387     @param b_dmac - B-tag remote mac address, needed for any push or translate_qinq vtr op
5388     @param b_smac - B-tag local mac address, needed for any push or translate qinq vtr op
5389     @param b_vlanid - B-tag vlanid, needed for any push or translate qinq vtr op
5390     @param i_sid - I-tag service id, needed for any push or translate qinq vtr op
5391 */
5392 define l2_interface_pbb_tag_rewrite
5393 {
5394   u32 client_index;
5395   u32 context;
5396   u32 sw_if_index;
5397   u32 vtr_op;
5398   u16 outer_tag;
5399   u8  b_dmac[6];
5400   u8  b_smac[6];
5401   u16 b_vlanid;
5402   u32 i_sid;
5403 };
5404
5405 /** \brief L2 interface pbb tag rewrite response
5406     @param context - sender context, to match reply w/ request
5407     @param retval - return code for the request
5408 */
5409 define l2_interface_pbb_tag_rewrite_reply
5410 {
5411   u32 context;
5412   i32 retval;
5413 };
5414
5415 /** \brief Punt traffic to the host
5416     @param client_index - opaque cookie to identify the sender
5417     @param context - sender context, to match reply w/ request
5418     @param is_add - add punt if non-zero, else delete
5419     @param ipv - L3 protocol 4 - IPv4, 6 - IPv6, ~0 - All
5420     @param l4_protocol - L4 protocol to be punted, only UDP (0x11) is supported
5421     @param l4_port - TCP/UDP port to be punted
5422 */
5423 define punt {
5424     u32 client_index;
5425     u32 context;
5426     u8 is_add;
5427     u8 ipv;
5428     u8 l4_protocol;
5429     u16 l4_port;
5430 };
5431
5432 /** \brief Reply to the punt request
5433     @param context - sender context which was passed in the request
5434     @param retval - return code of punt request
5435 */
5436 define punt_reply
5437 {
5438     u32 context;
5439     i32 retval;
5440 };
5441
5442 /** \brief Dump ipsec policy database data
5443     @param client_index - opaque cookie to identify the sender
5444     @param context - sender context, to match reply w/ request
5445     @param spd_id - SPD instance id
5446     @param sa_id - SA id, optional, set to ~0 to see all policies in SPD
5447 */
5448 define ipsec_spd_dump {
5449     u32 client_index;
5450     u32 context;
5451     u32 spd_id;
5452     u32 sa_id;
5453 };
5454
5455 /** \brief IPsec policy database response
5456     @param context - sender context which was passed in the request
5457     @param spd_id - SPD instance id
5458     @param priority - numeric value to control policy evaluation order
5459     @param is_outbound - [1|0] to indicate if direction is [out|in]bound
5460     @param is_ipv6 - [1|0] to indicate if address family is ipv[6|4]
5461     @param local_start_addr - first address in local traffic selector range
5462     @param local_stop_addr - last address in local traffic selector range
5463     @param local_start_port - first port in local traffic selector range
5464     @param local_stop_port - last port in local traffic selector range
5465     @param remote_start_addr - first address in remote traffic selector range
5466     @param remote_stop_addr - last address in remote traffic selector range
5467     @param remote_start_port - first port in remote traffic selector range
5468     @param remote_stop_port - last port in remote traffic selector range
5469     @param protocol - traffic selector protocol
5470     @param policy - policy action
5471     @param sa_id - SA id
5472     @param bytes - byte count of packets matching this policy
5473     @param packets - count of packets matching this policy
5474 */
5475
5476 define ipsec_spd_details {
5477     u32 context;
5478     u32 spd_id;
5479     i32 priority;
5480     u8 is_outbound;
5481     u8 is_ipv6;
5482     u8 local_start_addr[16];
5483     u8 local_stop_addr[16];
5484     u16 local_start_port;
5485     u16 local_stop_port;
5486     u8 remote_start_addr[16];
5487     u8 remote_stop_addr[16];
5488     u16 remote_start_port;
5489     u16 remote_stop_port;
5490     u8 protocol;
5491     u8 policy;
5492     u32 sa_id;
5493     u64 bytes;
5494     u64 packets;
5495 };
5496
5497 /** \brief Feature path enable/disable request
5498     @param client_index - opaque cookie to identify the sender
5499     @param context - sender context, to match reply w/ request
5500     @param sw_if_index - the interface
5501     @param enable - 1 = on, 0 = off
5502 */
5503 define feature_enable_disable {
5504     u32 client_index;
5505     u32 context;
5506     u32 sw_if_index;
5507     u8 enable;
5508     u8 arc_name[64];
5509     u8 feature_name[64];
5510 };
5511
5512 /** \brief Reply to the eature path enable/disable request
5513     @param context - sender context which was passed in the request
5514     @param retval - return code for the request
5515 */
5516 define feature_enable_disable_reply
5517 {
5518     u32 context;
5519     i32 retval;
5520 };