session: async rx event notifications
[vpp.git] / src / vnet / CMakeLists.txt
1 # Copyright (c) 2018-2020 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 unset(VNET_SOURCES)
15 unset(VNET_HEADERS)
16 unset(VNET_API_FILES)
17 unset(VNET_MULTIARCH_SOURCES)
18
19 option(VPP_IP_FIB_MTRIE_16 "IP FIB's MTRIE Stride is 16-8-8 (if not set it's 8-8-8-8)" ON)
20
21 ##############################################################################
22 # Generic stuff
23 ##############################################################################
24 list(APPEND VNET_SOURCES
25   buffer.c
26   config.c
27   devices/devices.c
28   devices/netlink.c
29   error.c
30   flow/flow.c
31   flow/flow_cli.c
32   flow/flow_api.c
33   handoff.c
34   interface.c
35   interface_api.c
36   interface_cli.c
37   interface_format.c
38   interface_output.c
39   interface/caps.c
40   interface/rx_queue.c
41   interface/tx_queue.c
42   interface/runtime.c
43   interface/monitor.c
44   interface/stats.c
45   interface_stats.c
46   misc.c
47 )
48
49 list(APPEND VNET_MULTIARCH_SOURCES
50   interface_output.c
51   interface_stats.c
52   handoff.c
53 )
54
55 list(APPEND VNET_HEADERS
56   api_errno.h
57   error.h
58   buffer.h
59   config.h
60   devices/devices.h
61   devices/netlink.h
62   flow/flow.h
63   global_funcs.h
64   interface/rx_queue_funcs.h
65   interface/tx_queue_funcs.h
66   interface.h
67   interface_funcs.h
68   interface_output.h
69   ip/ip4_to_ip6.h
70   ip/ip6_to_ip4.h
71   ip/ip_types_api.h
72   l3_types.h
73   plugin/plugin.h
74   pipeline.h
75   vnet.h
76   util/radix.h
77   util/refcount.h
78   format_fns.h
79   ip/ip_format_fns.h
80   ip/ip_sas.h
81   ethernet/ethernet_format_fns.h
82   ethernet/ethernet_types_api.h
83 )
84
85 list(APPEND VNET_API_FILES
86   interface.api
87   interface_types.api
88   ip/ip_types.api
89   flow/flow_types.api
90   flow/flow.api
91 )
92
93 ##############################################################################
94 # Policer infra
95 ##############################################################################
96 list(APPEND VNET_SOURCES
97   policer/node_funcs.c
98   policer/policer.c
99   policer/xlate.c
100   policer/policer_api.c
101 )
102
103 list(APPEND VNET_MULTIARCH_SOURCES
104   policer/node_funcs.c
105 )
106
107 list(APPEND VNET_HEADERS
108   policer/police.h
109   policer/policer.h
110   policer/xlate.h
111 )
112
113 list(APPEND VNET_API_FILES
114   policer/policer.api
115   policer/policer_types.api
116 )
117
118 ##############################################################################
119 # Layer 2 protocols go here
120 ##############################################################################
121
122 ##############################################################################
123 # Layer 2 protocol: Ethernet
124 ##############################################################################
125 list(APPEND VNET_SOURCES
126   ethernet/arp_packet.c
127   ethernet/ethernet_types_api.c
128   ethernet/format.c
129   ethernet/init.c
130   ethernet/interface.c
131   ethernet/mac_address.c
132   ethernet/node.c
133   ethernet/pg.c
134   ethernet/sfp.c
135   ethernet/p2p_ethernet.c
136   ethernet/p2p_ethernet_input.c
137   ethernet/p2p_ethernet_api.c
138 )
139
140 list(APPEND VNET_MULTIARCH_SOURCES
141   ethernet/node.c
142   ethernet/p2p_ethernet_input.c
143 )
144
145 list(APPEND VNET_HEADERS
146   ethernet/error.def
147   ethernet/ethernet.h
148   ethernet/mac_address.h
149   ethernet/packet.h
150   ethernet/types.def
151   ethernet/sfp.h
152   ethernet/p2p_ethernet.h
153   ethernet/arp_packet.h
154 )
155
156 list(APPEND VNET_API_FILES
157   ethernet/p2p_ethernet.api
158   ethernet/ethernet_types.api)
159
160 ##############################################################################
161 # Layer 2 protocol: Ethernet bridging
162 ##############################################################################
163 list(APPEND VNET_SOURCES
164   l2/feat_bitmap.c
165   l2/l2_api.c
166   l2/l2_arp_term.c
167   l2/l2_bd.c
168   l2/l2_bvi.c
169   l2/l2_bvi_node.c
170   l2/l2_input_classify.c
171   l2/l2_output_classify.c
172   l2/l2_efp_filter.c
173   l2/l2_fib.c
174   l2/l2_flood.c
175   l2/l2_fwd.c
176   l2/l2_input.c
177   l2/l2_input_node.c
178   l2/l2_input_vtr.c
179   l2/l2_learn.c
180   l2/l2_output.c
181   l2/l2_in_out_acl.c
182   l2/l2_in_out_feat_arc.c
183   l2/l2_patch.c
184   l2/l2_rw.c
185   l2/l2_uu_fwd.c
186   l2/l2_vtr.c
187   l2/l2_xcrw.c
188 )
189
190 list(APPEND VNET_MULTIARCH_SOURCES
191   l2/l2_bvi_node.c
192   l2/l2_fwd.c
193   l2/l2_learn.c
194   l2/l2_output.c
195   l2/l2_patch.c
196   l2/l2_in_out_feat_arc.c
197   l2/l2_input_classify.c
198   l2/l2_input_node.c
199   l2/l2_output_classify.c
200   l2/l2_flood.c
201   l2/l2_uu_fwd.c
202   l2/l2_efp_filter.c
203   l2/l2_rw.c
204   l2/l2_xcrw.c
205   l2/l2_in_out_acl.c
206   l2/l2_input_vtr.c
207 )
208
209 list(APPEND VNET_HEADERS
210   l2/feat_bitmap.h
211   l2/l2_input.h
212   l2/l2_output.h
213   l2/l2_vtr.h
214   l2/l2_input_vtr.h
215   l2/l2_efp_filter.h
216   l2/l2_fwd.h
217   l2/l2_bd.h
218   l2/l2_bvi.h
219   l2/l2_flood.h
220   l2/l2_fib.h
221   l2/l2_rw.h
222   l2/l2_xcrw.h
223   l2/l2_classify.h
224 )
225
226 list(APPEND VNET_API_FILES l2/l2.api)
227
228 ##############################################################################
229 # Layer 2 protocol: SRP
230 ##############################################################################
231 list(APPEND VNET_SOURCES
232   srp/format.c
233   srp/interface.c
234   srp/node.c
235   srp/pg.c
236 )
237
238 list(APPEND VNET_HEADERS
239   srp/packet.h
240   srp/srp.h
241 )
242
243 ##############################################################################
244 # Layer 2 protocol: PPP
245 ##############################################################################
246 list(APPEND VNET_SOURCES
247   ppp/node.c
248   ppp/pg.c
249   ppp/ppp.c
250 )
251
252 list(APPEND VNET_HEADERS
253   ppp/error.def
254   ppp/ppp.h
255   ppp/packet.h
256 )
257
258 ##############################################################################
259 # Layer 2 protocol: HDLC
260 ##############################################################################
261 list(APPEND VNET_SOURCES
262   hdlc/node.c
263   hdlc/pg.c
264   hdlc/hdlc.c
265 )
266
267 list(APPEND VNET_HEADERS
268   hdlc/error.def
269   hdlc/hdlc.h
270   hdlc/packet.h
271 )
272
273 ##############################################################################
274 # Layer 2 protocol: LLC
275 ##############################################################################
276 list(APPEND VNET_SOURCES
277   llc/llc.c
278   llc/node.c
279   llc/pg.c
280 )
281
282 list(APPEND VNET_HEADERS
283   llc/llc.h
284 )
285
286 ##############################################################################
287 # Layer 2 protocol: SNAP
288 ##############################################################################
289 list(APPEND VNET_SOURCES
290   snap/snap.c
291   snap/node.c
292   snap/pg.c
293 )
294
295 list(APPEND VNET_HEADERS
296   snap/snap.h
297 )
298
299 ##############################################################################
300 # Layer 2 / Bonding
301 ##############################################################################
302 list(APPEND VNET_SOURCES
303   bonding/cli.c
304   bonding/node.c
305   bonding/device.c
306   bonding/bond_api.c
307 )
308
309 list(APPEND VNET_HEADERS
310   bonding/node.h
311 )
312
313 list(APPEND VNET_MULTIARCH_SOURCES bonding/node.c bonding/device.c)
314 list(APPEND VNET_API_FILES bonding/bond.api)
315
316 ##############################################################################
317 # Layer 2/3 "classify"
318 ##############################################################################
319 list(APPEND VNET_SOURCES
320   classify/vnet_classify.c
321   classify/trace_classify.h
322   classify/ip_classify.c
323   classify/in_out_acl.c
324   classify/policer_classify.c
325   classify/flow_classify.c
326   classify/flow_classify_node.c
327   classify/vnet_classify.h
328   classify/classify_api.c
329 )
330
331 list(APPEND VNET_MULTIARCH_SOURCES
332   classify/ip_classify.c
333   classify/flow_classify_node.c
334 )
335
336 list(APPEND VNET_HEADERS
337   classify/vnet_classify.h
338   classify/trace_classify.h
339   classify/in_out_acl.h
340   classify/policer_classify.h
341   classify/flow_classify.h
342 )
343
344 list(APPEND VNET_API_FILES classify/classify.api)
345
346 ##############################################################################
347 # Layer 3 protocols go here
348 ##############################################################################
349
350 ##############################################################################
351 # Layer 3 protocol: IP v4/v6
352 ##############################################################################
353 list(APPEND VNET_SOURCES
354   ip/format.c
355   ip/icmp4.c
356   ip/icmp6.c
357   ip/ip46_cli.c
358   ip/ip_types_api.c
359   ip/ip46_address.c
360   ip/ip4_format.c
361   ip/ip4_forward.c
362   ip/ip4_punt_drop.c
363   ip/ip4_input.c
364   ip/ip4_options.c
365   ip/ip4_mtrie.c
366   ip/ip4_pg.c
367   ip/ip4_source_and_port_range_check.c
368   ip/reass/ip4_full_reass.c
369   ip/reass/ip4_sv_reass.c
370   ip/ip6_format.c
371   ip/ip6_forward.c
372   ip/ip6_ll_table.c
373   ip/ip6_ll_types.c
374   ip/ip6_punt_drop.c
375   ip/ip6_hop_by_hop.c
376   ip/ip6_input.c
377   ip/ip6_link.c
378   ip/ip6_pg.c
379   ip/reass/ip6_full_reass.c
380   ip/reass/ip6_sv_reass.c
381   ip/ip_api.c
382   ip/ip_checksum.c
383   ip/ip_container_proxy.c
384   ip/ip_frag.c
385   ip/ip.c
386   ip/ip_interface.c
387   ip/ip_init.c
388   ip/ip_in_out_acl.c
389   ip/ip_path_mtu.c
390   ip/ip_path_mtu_node.c
391   ip/ip_punt_drop.c
392   ip/ip_types.c
393   ip/lookup.c
394   ip/punt_api.c
395   ip/punt.c
396   ip/punt_node.c
397   ip/vtep.c
398   ip/ip_sas.c
399 )
400
401 list(APPEND VNET_MULTIARCH_SOURCES
402   ip/ip4_punt_drop.c
403   ip/reass/ip4_full_reass.c
404   ip/ip6_hop_by_hop.c
405   ip/reass/ip6_full_reass.c
406   ip/reass/ip4_sv_reass.c
407   ip/ip6_hop_by_hop.c
408   ip/reass/ip6_full_reass.c
409   ip/reass/ip6_sv_reass.c
410   ip/ip6_input.c
411   ip/ip6_punt_drop.c
412   ip/punt_node.c
413   ip/ip_in_out_acl.c
414   ip/ip_path_mtu_node.c
415 )
416
417 list(APPEND VNET_HEADERS
418   ip/format.h
419   ip/icmp46_packet.h
420   ip/icmp4.h
421   ip/icmp6.h
422   ip/igmp_packet.h
423   ip/ip4.h
424   ip/ip4_mtrie.h
425   ip/ip4_inlines.h
426   ip/ip4_packet.h
427   ip/ip46_address.h
428   ip/ip6.h
429   ip/ip6_hop_by_hop.h
430   ip/ip6_hop_by_hop_packet.h
431   ip/ip6_inlines.h
432   ip/ip6_packet.h
433   ip/ip.h
434   ip/ip_container_proxy.h
435   ip/ip_flow_hash.h
436   ip/ip_table.h
437   ip/ip_interface.h
438   ip/ip_packet.h
439   ip/ip_psh_cksum.h
440   ip/ip_source_and_port_range_check.h
441   ip/ip_types.h
442   ip/lookup.h
443   ip/ports.def
444   ip/protocols.def
445   ip/punt_error.def
446   ip/punt.h
447   ip/reass/ip4_sv_reass.h
448   ip/reass/ip6_sv_reass.h
449 )
450
451 list(APPEND VNET_API_FILES
452   ip/ip.api
453   ip/punt.api
454 )
455
456 list(APPEND VNET_MULTIARCH_SOURCES
457   ip/ip4_forward.c
458   ip/ip6_forward.c
459   ip/ip4_input.c
460 )
461
462 ##############################################################################
463 # Layer 3 neighbours
464 ##############################################################################
465 list(APPEND VNET_SOURCES
466   ip-neighbor/ip_neighbor.c
467   ip-neighbor/ip_neighbor_api.c
468   ip-neighbor/ip_neighbor_dp.c
469   ip-neighbor/ip_neighbor_types.c
470   ip-neighbor/ip_neighbor_watch.c
471   ip-neighbor/ip4_neighbor.c
472   ip-neighbor/ip6_neighbor.c
473 )
474
475 list(APPEND VNET_HEADERS
476   ip-neighbor/ip_neighbor.h
477   ip-neighbor/ip_neighbor_types.h
478 )
479
480 list(APPEND VNET_API_FILES
481   ip-neighbor/ip_neighbor.api
482 )
483
484 ##############################################################################
485 # Bidirectional Forwarding Detection
486 ##############################################################################
487
488 list(APPEND VNET_HEADERS
489   bfd/bfd_protocol.h
490   bfd/bfd_main.h
491   bfd/bfd_api.h
492   bfd/bfd_udp.h
493 )
494
495 list(APPEND VNET_SOURCES
496   bfd/bfd_api.h
497   bfd/bfd_udp.c
498   bfd/bfd_main.c
499   bfd/bfd_protocol.c
500   bfd/bfd_cli.c
501   bfd/bfd_api.c
502 )
503
504 list(APPEND VNET_API_FILES bfd/bfd.api)
505
506 ##############################################################################
507 # Crypto
508 ##############################################################################
509
510 list(APPEND VNET_SOURCES
511   crypto/cli.c
512   crypto/crypto.c
513   crypto/format.c
514   crypto/node.c
515   crypto/crypto_api.c
516 )
517
518 list(APPEND VNET_HEADERS
519   crypto/crypto.h
520 )
521
522 list(APPEND VNET_MULTIARCH_SOURCES crypto/node.c)
523
524 list(APPEND VNET_API_FILES crypto/crypto.api)
525
526 ##############################################################################
527 # Layer 3 protocol: IPSec
528 ##############################################################################
529 list(APPEND VNET_SOURCES
530   ipsec/ipsec.c
531   ipsec/ipsec_cli.c
532   ipsec/ipsec_format.c
533   ipsec/ipsec_handoff.c
534   ipsec/ipsec_input.c
535   ipsec/ipsec_itf.c
536   ipsec/ipsec_punt.c
537   ipsec/ipsec_sa.c
538   ipsec/ipsec_spd.c
539   ipsec/ipsec_spd_policy.c
540   ipsec/ipsec_tun.c
541   ipsec/ipsec_tun_in.c
542   ipsec/esp_format.c
543   ipsec/esp_encrypt.c
544   ipsec/esp_decrypt.c
545   ipsec/ah_decrypt.c
546   ipsec/ah_encrypt.c
547   ipsec/ipsec_api.c
548   ipsec/ipsec_types_api.c
549 )
550
551 list(APPEND VNET_MULTIARCH_SOURCES
552   ipsec/esp_encrypt.c
553   ipsec/esp_decrypt.c
554   ipsec/ah_decrypt.c
555   ipsec/ah_encrypt.c
556   ipsec/ipsec_handoff.c
557   ipsec/ipsec_output.c
558   ipsec/ipsec_input.c
559   ipsec/ipsec_tun_in.c
560 )
561
562 list(APPEND VNET_API_FILES ipsec/ipsec_types.api)
563 list(APPEND VNET_API_FILES ipsec/ipsec.api)
564
565 list(APPEND VNET_SOURCES
566   ipsec/ipsec_output.c
567 )
568
569 list(APPEND VNET_HEADERS
570   ipsec/ipsec.h
571   ipsec/ipsec_spd.h
572   ipsec/ipsec_spd_policy.h
573   ipsec/ipsec_sa.h
574   ipsec/ipsec_tun.h
575   ipsec/ipsec_types_api.h
576   ipsec/ipsec_punt.h
577   ipsec/esp.h
578   ipsec/ah.h
579 )
580
581 ##############################################################################
582 # Layer 3 protocol: osi
583 ##############################################################################
584 list(APPEND VNET_SOURCES
585   osi/node.c
586   osi/osi.c
587   osi/pg.c
588 )
589
590 list(APPEND VNET_HEADERS
591   osi/osi.h
592 )
593
594 ##############################################################################
595 # Layer 4 protocol: tcp
596 ##############################################################################
597 list(APPEND VNET_SOURCES
598   tcp/tcp_api.c
599   tcp/tcp_format.c
600   tcp/tcp_pg.c
601   tcp/tcp_syn_filter4.c
602   tcp/tcp_output.c
603   tcp/tcp_input.c
604   tcp/tcp_newreno.c
605   tcp/tcp_bt.c
606   tcp/tcp_cli.c
607   tcp/tcp_cubic.c
608   tcp/tcp_debug.c
609   tcp/tcp_sack.c
610   tcp/tcp_timer.c
611   tcp/tcp.c
612 )
613
614 list(APPEND VNET_MULTIARCH_SOURCES
615   tcp/tcp_input.c
616   tcp/tcp_output.c
617   tcp/tcp_syn_filter4.c
618 )
619
620 list(APPEND VNET_HEADERS
621   tcp/tcp_packet.h
622   tcp/tcp_timer.h
623   tcp/tcp_bt.h
624   tcp/tcp_cc.h
625   tcp/tcp_debug.h
626   tcp/tcp_inlines.h
627   tcp/tcp_sack.h
628   tcp/tcp_types.h
629   tcp/tcp.h
630   tcp/tcp_error.def
631 )
632
633 list(APPEND VNET_API_FILES tcp/tcp.api)
634
635 ##############################################################################
636 # Layer 4 protocol: udp
637 ##############################################################################
638 list(APPEND VNET_SOURCES
639   udp/udp.c
640   udp/udp_cli.c
641   udp/udp_input.c
642   udp/udp_format.c
643   udp/udp_local.c
644   udp/udp_pg.c
645   udp/udp_encap_node.c
646   udp/udp_encap.c
647   udp/udp_decap.c
648   udp/udp_api.c
649   udp/udp_output.c
650 )
651
652 list(APPEND VNET_MULTIARCH_SOURCES
653   udp/udp_local.c
654   udp/udp_encap_node.c
655 )
656
657 list(APPEND VNET_HEADERS
658   udp/udp_error.def
659   udp/udp.h
660   udp/udp_encap.h
661   udp/udp_packet.h
662   udp/udp_inlines.h
663   udp/udp_local.h
664 )
665
666 list(APPEND VNET_API_FILES udp/udp.api)
667
668 ##############################################################################
669 # Tunnel protocol: gre
670 ##############################################################################
671 list(APPEND VNET_HEADERS
672   gre/packet.h
673 )
674
675 ##############################################################################
676 # Tunnel protocol: ipip
677 ##############################################################################
678 list(APPEND VNET_SOURCES
679   ipip/ipip.c
680   ipip/node.c
681   ipip/sixrd.c
682   ipip/ipip_api.c
683   ipip/ipip_cli.c
684 )
685
686 list(APPEND VNET_MULTIARCH_SOURCES
687   ipip/node.c
688 )
689
690 list(APPEND VNET_HEADERS
691   ipip/ipip.h
692 )
693
694 list(APPEND VNET_API_FILES
695   ipip/ipip.api
696 )
697
698 ##############################################################################
699 # Tunnel infra
700 ##############################################################################
701 list(APPEND VNET_SOURCES
702   tunnel/tunnel.c
703   tunnel/tunnel_types_api.c
704 )
705
706 list(APPEND VNET_API_FILES
707   tunnel/tunnel_types.api
708 )
709
710 list(APPEND VNET_HEADERS
711   tunnel/tunnel.h
712   tunnel/tunnel_dp.h
713   tunnel/tunnel_types_api.h
714 )
715
716 ##############################################################################
717 # Tunnel protocol: gre+mpls
718 ##############################################################################
719 list(APPEND VNET_SOURCES
720   mpls/mpls.c
721   mpls/mpls_lookup.c
722   mpls/mpls_output.c
723   mpls/mpls_features.c
724   mpls/mpls_input.c
725   mpls/interface.c
726   mpls/mpls_tunnel.c
727   mpls/pg.c
728   mpls/mpls_api.c
729 )
730
731 list(APPEND VNET_MULTIARCH_SOURCES
732   mpls/mpls_output.c
733   mpls/mpls_input.c
734   mpls/mpls_lookup.c
735   mpls/mpls_features.c
736 )
737
738 list(APPEND VNET_HEADERS
739   mpls/mpls.h
740   mpls/mpls_lookup.h
741   mpls/mpls_types.h
742   mpls/mpls_tunnel.h
743   mpls/packet.h
744 )
745
746 list(APPEND VNET_API_FILES mpls/mpls.api)
747
748 ##############################################################################
749 # Tunnel protocol: vxlan-gpe
750 ##############################################################################
751
752 list(APPEND VNET_SOURCES
753   vxlan-gpe/vxlan_gpe.c
754   vxlan-gpe/encap.c
755   vxlan-gpe/decap.c
756   vxlan-gpe/vxlan_gpe_api.c
757 )
758
759 list (APPEND VNET_MULTIARCH_SOURCES
760   vxlan-gpe/decap.c
761 )
762
763 list(APPEND VNET_HEADERS
764   vxlan-gpe/vxlan_gpe.h
765   vxlan-gpe/vxlan_gpe_packet.h
766   vxlan-gpe/vxlan_gpe_error.def
767 )
768
769 list(APPEND VNET_API_FILES vxlan-gpe/vxlan_gpe.api)
770
771 ##############################################################################
772 # ipv6 segment routing
773 ##############################################################################
774
775 list(APPEND VNET_SOURCES
776   srv6/sr.c
777   srv6/sr_localsid.c
778   srv6/sr_policy_rewrite.c
779   srv6/sr_steering.c
780   srv6/sr_api.c
781   srv6/sr_pt.c
782   srv6/sr_pt_node.c
783   srv6/sr_pt_api.c
784 )
785
786 list(APPEND VNET_HEADERS
787   srv6/sr_packet.h
788   srv6/sr.h
789   srv6/sr_pt.h
790 )
791
792 list(APPEND VNET_API_FILES
793   srv6/sr.api
794   srv6/sr_types.api
795   srv6/sr_pt.api
796 )
797
798 ##############################################################################
799 # mpls segment routing
800 ##############################################################################
801
802 list(APPEND VNET_SOURCES
803   srmpls/sr_mpls_policy.c
804   srmpls/sr_mpls_steering.c
805   srmpls/sr_mpls_api.c
806 )
807
808 list(APPEND VNET_HEADERS
809   srmpls/sr_mpls.h
810 )
811
812 list(APPEND VNET_API_FILES
813   srmpls/sr_mpls.api
814 )
815
816 ##############################################################################
817 # IPFIX / netflow v10
818 ##############################################################################
819 list(APPEND VNET_SOURCES
820   ipfix-export/flow_report.c
821   ipfix-export/flow_api.c
822 )
823
824 list(APPEND VNET_HEADERS
825   ipfix-export/flow_report.h
826   ipfix-export/ipfix_info_elements.h
827   ipfix-export/ipfix_packet.h
828 )
829
830 list(APPEND VNET_API_FILES ipfix-export/ipfix_export.api)
831
832 ##############################################################################
833 # HASH
834 ##############################################################################
835 list(APPEND VNET_SOURCES
836   hash/hash.c
837   hash/cli.c
838   hash/crc32_5tuple.c
839   hash/handoff_eth.c
840   hash/hash_eth.c
841 )
842
843 list(APPEND VNET_HEADERS
844   hash/hash.h
845 )
846
847 ##############################################################################
848 # GSO
849 ##############################################################################
850 list(APPEND VNET_SOURCES
851   gso/cli.c
852   gso/gso.c
853   gso/gso_api.c
854   gso/node.c
855 )
856
857 list(APPEND VNET_HEADERS
858   gso/gro.h
859   gso/gro_func.h
860   gso/hdr_offset_parser.h
861   gso/gso.h
862 )
863
864 list(APPEND VNET_API_FILES
865   gso/gso.api
866 )
867
868 ##############################################################################
869 # IPFIX classify code
870 ##############################################################################
871
872 list(APPEND VNET_SOURCES
873   ipfix-export/flow_report_classify.c
874 )
875
876 list(APPEND VNET_HEADERS
877   ipfix-export/flow_report_classify.h
878 )
879
880 ##############################################################################
881 # lawful intercept
882 ##############################################################################
883
884 list(APPEND VNET_SOURCES
885   lawful-intercept/lawful_intercept.c
886   lawful-intercept/node.c
887 )
888
889 list(APPEND VNET_MULTIARCH_SOURCES
890   lawful-intercept/node.c
891 )
892
893 list(APPEND VNET_HEADERS
894   lawful-intercept/lawful_intercept.h
895 )
896
897 ##############################################################################
898 # SPAN (port mirroring)
899 ##############################################################################
900
901 list(APPEND VNET_SOURCES
902   span/span_api.c
903   span/span.c
904   span/node.c
905 )
906
907 list(APPEND VNET_MULTIARCH_SOURCES
908   span/node.c
909 )
910
911 list(APPEND VNET_HEADERS
912   span/span.h
913 )
914
915 list(APPEND VNET_API_FILES span/span.api)
916
917 ##############################################################################
918 # Packet generator
919 ##############################################################################
920
921 list(APPEND VNET_SOURCES
922   pg/cli.c
923   pg/edit.c
924   pg/init.c
925   pg/input.c
926   pg/output.c
927   pg/stream.c
928   pg/pg_api.c
929 )
930
931 list(APPEND VNET_HEADERS
932   pg/pg.h
933   pg/edit.h
934 )
935
936 list(APPEND VNET_API_FILES pg/pg.api)
937
938 ##############################################################################
939 # virtio
940 ##############################################################################
941
942 list(APPEND VNET_SOURCES
943   devices/virtio/cli.c
944   devices/virtio/device.c
945   devices/virtio/format.c
946   devices/virtio/node.c
947   devices/virtio/pci.c
948   devices/virtio/virtio.c
949   devices/virtio/virtio_api.c
950   devices/virtio/virtio_pci_legacy.c
951   devices/virtio/virtio_pci_modern.c
952   devices/virtio/virtio_pre_input.c
953   devices/virtio/virtio_types_api.c
954 )
955
956 list(APPEND VNET_HEADERS
957   devices/virtio/pci.h
958   devices/virtio/virtio.h
959   devices/virtio/virtio_buffering.h
960   devices/virtio/virtio_std.h
961   devices/virtio/virtio_pci_legacy.h
962   devices/virtio/virtio_pci_modern.h
963   devices/virtio/vhost_std.h
964   devices/virtio/virtio_types_api.h
965 )
966
967 list(APPEND VNET_MULTIARCH_SOURCES
968   devices/virtio/node.c
969   devices/virtio/device.c
970 )
971
972 list(APPEND VNET_API_FILES
973   devices/virtio/virtio.api
974   devices/virtio/virtio_types.api
975 )
976
977 ##############################################################################
978 # tap interface (with virtio backend)
979 ##############################################################################
980
981 list(APPEND VNET_SOURCES
982   devices/tap/cli.c
983   devices/tap/tap.c
984   devices/tap/tapv2_api.c
985 )
986
987 list(APPEND VNET_HEADERS
988   devices/tap/tap.h
989 )
990
991 list(APPEND VNET_API_FILES
992   devices/tap/tapv2.api
993 )
994
995 ##############################################################################
996 # tap interface (with virtio backend)
997 ##############################################################################
998
999 list(APPEND VNET_SOURCES
1000   devices/pipe/pipe_api.c
1001   devices/pipe/pipe.c
1002 )
1003
1004 list(APPEND VNET_HEADERS
1005   devices/pipe/pipe.h
1006 )
1007
1008 list(APPEND VNET_API_FILES devices/pipe/pipe.api)
1009
1010 ##############################################################################
1011 # session managmeent
1012 ##############################################################################
1013
1014 list(APPEND VNET_SOURCES
1015   session/session.c
1016   session/session_debug.c
1017   session/session_table.c
1018   session/session_rules_table.c
1019   session/session_lookup.c
1020   session/session_node.c
1021   session/session_input.c
1022   session/transport.c
1023   session/application.c
1024   session/application_worker.c
1025   session/session_cli.c
1026   session/application_interface.c
1027   session/application_local.c
1028   session/application_namespace.c
1029   session/segment_manager.c
1030   session/session_api.c
1031 )
1032
1033 list(APPEND VNET_HEADERS
1034   session/session.h
1035   session/session_table.h
1036   session/session_rules_table.h
1037   session/session_types.h
1038   session/session_lookup.h
1039   session/application.h
1040   session/transport.h
1041   session/transport_types.h
1042   session/application_interface.h
1043   session/application_local.h
1044   session/application_namespace.h
1045   session/session_debug.h
1046   session/segment_manager.h
1047   session/mma_template.h
1048   session/mma_template.c
1049   session/mma_16.h
1050   session/mma_40.h
1051 )
1052
1053 list(APPEND VNET_API_FILES session/session.api)
1054
1055 ##############################################################################
1056 # TLS protocol
1057 ##############################################################################
1058
1059 list(APPEND VNET_SOURCES
1060   tls/tls.c
1061 )
1062
1063 list(APPEND VNET_HEADERS
1064   tls/tls.h
1065   tls/tls_test.h
1066 )
1067
1068
1069 ##############################################################################
1070 # Driver feature graph arc support
1071 ##############################################################################
1072
1073 list(APPEND VNET_SOURCES
1074   feature/feature.c
1075   feature/feature_api.c
1076   feature/registration.c
1077 )
1078
1079 list(APPEND VNET_HEADERS
1080   feature/feature.h
1081 )
1082
1083 list(APPEND VNET_API_FILES feature/feature.api)
1084
1085 ##############################################################################
1086 # Unix kernel related
1087 ##############################################################################
1088
1089 # FIXME: unix/hgshm.c
1090
1091 list(APPEND VNET_SOURCES
1092   unix/gdb_funcs.c
1093   unix/tuntap.c
1094 )
1095
1096 list(APPEND VNET_HEADERS
1097   unix/tuntap.h
1098 )
1099
1100 ##############################################################################
1101 # FIB
1102 ##############################################################################
1103
1104 list(APPEND VNET_SOURCES
1105   fib/fib.c
1106   fib/ip4_fib_hash.c
1107   fib/ip4_fib.c
1108   fib/ip4_fib_16.c
1109   fib/ip4_fib_8.c
1110   fib/ip6_fib.c
1111   fib/mpls_fib.c
1112   fib/fib_table.c
1113   fib/fib_walk.c
1114   fib/fib_types.c
1115   fib/fib_node.c
1116   fib/fib_node_list.c
1117   fib/fib_entry.c
1118   fib/fib_entry_src.c
1119   fib/fib_entry_src_adj.c
1120   fib/fib_entry_src_api.c
1121   fib/fib_entry_src_drop.c
1122   fib/fib_entry_src_interface.c
1123   fib/fib_entry_src_interpose.c
1124   fib/fib_entry_src_lisp.c
1125   fib/fib_entry_src_mpls.c
1126   fib/fib_entry_src_simple.c
1127   fib/fib_entry_src_rr.c
1128   fib/fib_entry_cover.c
1129   fib/fib_entry_delegate.c
1130   fib/fib_entry_track.c
1131   fib/fib_path_list.c
1132   fib/fib_path.c
1133   fib/fib_path_ext.c
1134   fib/fib_sas.c
1135   fib/fib_source.c
1136   fib/fib_urpf_list.c
1137   fib/fib_attached_export.c
1138   fib/fib_api.c
1139   fib/fib_bfd.c
1140 )
1141
1142 list(APPEND VNET_HEADERS
1143   fib/fib.h
1144   fib/fib_api.h
1145   fib/fib_entry_track.h
1146   fib/ip4_fib.h
1147   fib/ip4_fib_8.h
1148   fib/ip4_fib_16.h
1149   fib/ip4_fib_hash.h
1150   fib/ip6_fib.h
1151   fib/fib_types.h
1152   fib/fib_table.h
1153   fib/fib_node.h
1154   fib/fib_node_list.h
1155   fib/fib_entry.h
1156   fib/fib_entry_delegate.h
1157   fib/fib_path.h
1158   fib/fib_path_list.h
1159   fib/fib_sas.h
1160   fib/fib_source.h
1161 )
1162
1163 list(APPEND VNET_API_FILES
1164   fib/fib_types.api
1165   fib/fib.api
1166 )
1167
1168 ##############################################################################
1169 # ADJ
1170 ##############################################################################
1171
1172 list(APPEND VNET_SOURCES
1173   adj/adj_nbr.c
1174   adj/adj_glean.c
1175   adj/adj_midchain.c
1176   adj/adj_midchain_node.c
1177   adj/adj_midchain_delegate.c
1178   adj/adj_mcast.c
1179   adj/adj_l2.c
1180   adj/adj_nsh.c
1181   adj/adj.c
1182   adj/rewrite.c
1183   adj/adj_bfd.c
1184   adj/adj_delegate.c
1185 )
1186
1187 list(APPEND VNET_MULTIARCH_SOURCES
1188   adj/adj_nsh.c
1189   adj/adj_l2.c
1190   adj/adj_midchain_node.c
1191 )
1192
1193 list(APPEND VNET_HEADERS
1194   adj/adj.h
1195   adj/adj_types.h
1196   adj/adj_glean.h
1197   adj/adj_nsh.h
1198   adj/adj_nbr.h
1199   adj/adj_midchain.h
1200   adj/rewrite.h
1201 )
1202
1203 ##############################################################################
1204 # Data-Plane Objects
1205 ##############################################################################
1206
1207 list(APPEND VNET_SOURCES
1208   dpo/dpo.c
1209   dpo/drop_dpo.c
1210   dpo/ip_null_dpo.c
1211   dpo/ip6_ll_dpo.c
1212   dpo/punt_dpo.c
1213   dpo/receive_dpo.c
1214   dpo/load_balance.c
1215   dpo/load_balance_map.c
1216   dpo/lookup_dpo.c
1217   dpo/classify_dpo.c
1218   dpo/replicate_dpo.c
1219   dpo/interface_rx_dpo.c
1220   dpo/interface_tx_dpo.c
1221   dpo/mpls_disposition.c
1222   dpo/mpls_label_dpo.c
1223   dpo/l3_proxy_dpo.c
1224   dpo/dvr_dpo.c
1225   dpo/pw_cw.c
1226 )
1227
1228 list(APPEND VNET_MULTIARCH_SOURCES
1229   dpo/lookup_dpo.h
1230   dpo/mpls_disposition.c
1231   dpo/dvr_dpo.c
1232   dpo/mpls_label_dpo.c
1233   dpo/interface_rx_dpo.c
1234 )
1235
1236 list(APPEND VNET_HEADERS
1237   dpo/load_balance.h
1238   dpo/load_balance_map.h
1239   dpo/drop_dpo.h
1240   dpo/lookup_dpo.h
1241   dpo/punt_dpo.h
1242   dpo/classify_dpo.h
1243   dpo/receive_dpo.h
1244   dpo/ip_null_dpo.h
1245   dpo/replicate_dpo.h
1246   dpo/dpo.h
1247 )
1248
1249 ##############################################################################
1250 # Multicast FIB
1251 ##############################################################################
1252
1253 list(APPEND VNET_SOURCES
1254   mfib/mfib_forward.c
1255   mfib/ip4_mfib.c
1256   mfib/ip6_mfib.c
1257   mfib/mfib_api.c
1258   mfib/mfib_types.c
1259   mfib/mfib_signal.c
1260   mfib/mfib_itf.c
1261   mfib/mfib_entry.c
1262   mfib/mfib_entry.c
1263   mfib/mfib_entry_cover.c
1264   mfib/mfib_entry_delegate.c
1265   mfib/mfib_entry_src.c
1266   mfib/mfib_entry_src_rr.c
1267   mfib/mfib_table.c
1268 )
1269
1270 list(APPEND VNET_MULTIARCH_SOURCES
1271   mfib/mfib_forward.c
1272 )
1273
1274 list(APPEND VNET_HEADERS
1275   mfib/ip4_mfib.h
1276   mfib/mfib_types.h
1277   mfib/mfib_table.h
1278 )
1279
1280 list(APPEND VNET_API_FILES mfib/mfib_types.api)
1281
1282 ##############################################################################
1283 # Utilities
1284 ##############################################################################
1285
1286 list(APPEND VNET_SOURCES
1287   util/radix.c
1288   util/refcount.c
1289   util/throttle.c
1290 )
1291
1292 list(APPEND VNET_HEADERS
1293   util/throttle.h
1294 )
1295
1296 ##############################################################################
1297 # QoS
1298 ##############################################################################
1299
1300 list(APPEND VNET_SOURCES
1301   qos/qos_types.c
1302   qos/qos_api.c
1303   qos/qos_egress_map.c
1304   qos/qos_record.c
1305   qos/qos_record_node.c
1306   qos/qos_store.c
1307   qos/qos_store_node.c
1308   qos/qos_mark.c
1309   qos/qos_mark_node.c
1310 )
1311
1312 list(APPEND VNET_MULTIARCH_SOURCES
1313   qos/qos_record_node.c
1314   qos/qos_mark_node.c
1315 )
1316
1317 list(APPEND VNET_API_FILES qos/qos.api)
1318
1319 ##############################################################################
1320 # BIER
1321 ##############################################################################
1322
1323 list(APPEND VNET_SOURCES
1324   bier/bier_bit_string.c
1325   bier/bier_entry.c
1326   bier/bier_fmask.c
1327   bier/bier_fmask_db.c
1328   bier/bier_input.c
1329   bier/bier_lookup.c
1330   bier/bier_output.c
1331   bier/bier_table.c
1332   bier/bier_types.c
1333   bier/bier_api.c
1334   bier/bier_drop.c
1335   bier/bier_update.c
1336   bier/bier_imp_node.c
1337   bier/bier_imp.c
1338   bier/bier_disp_entry.c
1339   bier/bier_disp_lookup_node.c
1340   bier/bier_disp_dispatch_node.c
1341   bier/bier_disp_table.c
1342   bier/bier_bift_table.c
1343 )
1344
1345 list(APPEND VNET_MULTIARCH_SOURCES
1346   bier/bier_disp_dispatch_node.c
1347   bier/bier_disp_lookup_node.c
1348   bier/bier_imp_node.c
1349 )
1350
1351 list(APPEND VNET_HEADERS
1352   bier/bier_bit_string.h
1353   bier/bier_entry.h
1354   bier/bier_fwd.h
1355   bier/bier_hdr_inlines.h
1356   bier/bier_update.h
1357   bier/bier_table.h
1358   bier/bier_types.h
1359 )
1360
1361 list(APPEND VNET_API_FILES bier/bier.api)
1362
1363 ##############################################################################
1364 # SYSLOG
1365 ##############################################################################
1366
1367 list (APPEND VNET_SOURCES
1368   syslog/syslog_api.c
1369   syslog/syslog_udp.c
1370   syslog/syslog.c
1371 )
1372
1373 list(APPEND VNET_HEADERS
1374   syslog/syslog_udp.h
1375   syslog/syslog.h
1376 )
1377
1378 list(APPEND VNET_API_FILES syslog/syslog.api)
1379
1380 ##############################################################################
1381 # Tunnel Endpoint Information Base
1382 ##############################################################################
1383
1384 list (APPEND VNET_SOURCES
1385   teib/teib_api.c
1386   teib/teib_cli.c
1387   teib/teib.c
1388 )
1389
1390 list(APPEND VNET_HEADERS
1391   teib/teib.h
1392 )
1393
1394 list(APPEND VNET_API_FILES teib/teib.api)
1395
1396 ##############################################################################
1397 # ARP/ND
1398 ##############################################################################
1399
1400 list (APPEND VNET_SOURCES
1401   arp/arp_api.c
1402   arp/arp.c
1403   arp/arp_proxy.c
1404 )
1405
1406 list(APPEND VNET_HEADERS
1407   arp/arp.h
1408 )
1409
1410 list(APPEND VNET_API_FILES arp/arp.api)
1411
1412 list (APPEND VNET_SOURCES
1413   ip6-nd/ip6_mld.c
1414   ip6-nd/ip6_nd.c
1415   ip6-nd/ip6_nd_api.c
1416   ip6-nd/ip6_nd_proxy.c
1417   ip6-nd/ip6_nd_mirror_proxy.c
1418   ip6-nd/ip6_ra.c
1419   ip6-nd/rd_cp.c
1420   ip6-nd/rd_cp_api.c
1421 )
1422
1423 list(APPEND VNET_HEADERS
1424   ip6-nd/ip6_nd.h
1425 )
1426
1427 list(APPEND VNET_API_FILES
1428   ip6-nd/ip6_nd.api
1429   ip6-nd/rd_cp.api
1430 )
1431
1432 ##############################################################################
1433 # VNET Library
1434 ##############################################################################
1435
1436 add_vpp_library(vnet
1437   SOURCES ${VNET_SOURCES}
1438   MULTIARCH_SOURCES ${VNET_MULTIARCH_SOURCES}
1439   INSTALL_HEADERS ${VNET_HEADERS}
1440   API_FILES ${VNET_API_FILES}
1441   LINK_LIBRARIES vppinfra svm vlib
1442   DEPENDS vpp_version_h api_headers
1443 )
1444
1445 ##############################################################################
1446 # vpp api test client library
1447 ##############################################################################
1448
1449 add_vpp_library (vatclient
1450   SOURCES ip/ip_types_api.c
1451   DEPENDS api_headers
1452 )
1453
1454 add_vat_test_library(vnet
1455   interface_test.c
1456   ip/ip_test.c
1457   arp/arp_test.c
1458   ip6-nd/ip6_nd_test.c
1459   srmpls/sr_mpls_test.c
1460   session/session_test.c
1461   l2/l2_test.c
1462   ipsec/ipsec_test.c
1463 )
1464
1465 ##############################################################################
1466 # VAT2 plugins
1467 ##############################################################################
1468 add_vpp_test_library(vnet
1469   ${VNET_API_FILES}
1470 )
1471
1472 ##############################################################################