X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvppinfra%2Fpcap.h;h=c3e1fef71f3e03ef7609d0495410d8557c3994ea;hb=c025329bb244952938c8575a1d5602a1e54e5fe7;hp=5889a793401132a48aaefc1c16332f66f360220a;hpb=3ae2873e568dd441a22903ab9f8c7954835b0bf1;p=vpp.git diff --git a/src/vppinfra/pcap.h b/src/vppinfra/pcap.h index 5889a793401..c3e1fef71f3 100644 --- a/src/vppinfra/pcap.h +++ b/src/vppinfra/pcap.h @@ -49,7 +49,7 @@ #include /** - * @brief Packet types supported by PCAP + * @brief Known libpcap encap types * * These codes end up in the pcap file header. * If you decide to build a wireshark dissector, @@ -58,22 +58,16 @@ * * For example: * - * { 160, WTAP_ENCAP_USER13 }, + * { 280, WTAP_ENCAP_VPP }, * - * A file with (vpp) packet type PCAP_PACKET_TYPE_user13 - * aka 160, will need a top-level dissector registered to - * deal with WTAP_ENCAP_USER13 [=58]. + * A file with the officially-allocated vpp packet type PCAP_PACKET_TYPE_vpp + * aka 280, will need a top-level dissector registered to + * deal with WTAP_ENCAP_VPP [=206]. * * Something like so: * - * dissector_add_uint("wtap_encap", WTAP_ENCAP_USER13, vpp_dissector_handle); + * dissector_add_uint("wtap_encap", WTAP_ENCAP_VPP, vpp_dissector_handle); * - * null 0 - * ethernet 1 - * ppp 9 - * ip 12 - * hdlc 104 - * user0 147 ... user15 162 */ #define foreach_vnet_pcap_packet_type \ _ (null, 0) \ @@ -96,7 +90,8 @@ _ (user12, 159) \ _ (user13, 160) \ _ (user14, 161) \ - _ (user15, 162) + _ (user15, 162) \ + _ (vpp, 280) \ typedef enum { @@ -198,6 +193,8 @@ typedef struct u32 min_packet_bytes, max_packet_bytes; } pcap_main_t; +#define PCAP_DEF_PKT_TO_CAPTURE (100) + #endif /* included_vppinfra_pcap_h */ /*