Added support for HPVM (Integrity Virtual Machines) guest AVIO (Accelerated Virtual IO) driver IGSSN.
Cleaned up the trace record checks.
Made the default ethernet if the nettl subsystem is not recognized.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@27549
f5534014-38df-0310-8fa8-
9805f1628bb7
{ 269, "HSSN" },
{ 270, "IGSSN" },
{ 271, "ICXGBE" },
{ 269, "HSSN" },
{ 270, "IGSSN" },
{ 271, "ICXGBE" },
{ 513, "KL_VM" },
{ 514, "KL_PKM" },
{ 515, "KL_DLKM" },
{ 513, "KL_VM" },
{ 514, "KL_PKM" },
{ 515, "KL_DLKM" },
call_dissector(data_handle, tvb, pinfo, tree);
break;
case WTAP_ENCAP_NETTL_RAW_IP:
call_dissector(data_handle, tvb, pinfo, tree);
break;
case WTAP_ENCAP_NETTL_RAW_IP:
- if ( ( (pinfo->pseudo_header->nettl.kind
- & ~NETTL_HDR_SUBSYSTEM_BITS_MASK)
- & (NETTL_HDR_PROCEDURE_TRACE |
- NETTL_HDR_STATE_TRACE |
- NETTL_HDR_ERROR_TRACE) ) != 0)
- /* not really a data packet */
+ if ( (pinfo->pseudo_header->nettl.kind & NETTL_HDR_PDU_MASK) == 0 )
+ /* not actually a data packet (PDU) trace record */
call_dissector(data_handle, tvb, pinfo, tree);
else if (pinfo->pseudo_header->nettl.subsys == NETTL_SUBSYS_NS_LS_SCTP )
call_dissector(sctp_handle, tvb, pinfo, tree);
call_dissector(data_handle, tvb, pinfo, tree);
else if (pinfo->pseudo_header->nettl.subsys == NETTL_SUBSYS_NS_LS_SCTP )
call_dissector(sctp_handle, tvb, pinfo, tree);
return -1;
offset += hdr_len;
return -1;
offset += hdr_len;
- if ( ( (pntohl(&rec_hdr.kind) & ~NETTL_HDR_SUBSYSTEM_BITS_MASK)
- & (NETTL_HDR_PROCEDURE_TRACE |
- NETTL_HDR_STATE_TRACE |
- NETTL_HDR_ERROR_TRACE) ) != 0) {
- /* not actually a packet trace record */
+ if ( (pntohl(&rec_hdr.kind) & NETTL_HDR_PDU_MASK) == 0 ) {
+ /* not actually a data packet (PDU) trace record */
phdr->pkt_encap = WTAP_ENCAP_NETTL_RAW_IP;
length = pntohl(&rec_hdr.length);
caplen = pntohl(&rec_hdr.caplen);
phdr->pkt_encap = WTAP_ENCAP_NETTL_RAW_IP;
length = pntohl(&rec_hdr.length);
caplen = pntohl(&rec_hdr.caplen);
case NETTL_SUBSYS_IGELAN :
case NETTL_SUBSYS_IETHER :
case NETTL_SUBSYS_IXGBE :
case NETTL_SUBSYS_IGELAN :
case NETTL_SUBSYS_IETHER :
case NETTL_SUBSYS_IXGBE :
+ case NETTL_SUBSYS_HSSN :
case NETTL_SUBSYS_IGSSN :
case NETTL_SUBSYS_ICXGBE :
case NETTL_SUBSYS_IGSSN :
case NETTL_SUBSYS_ICXGBE :
+ case NETTL_SUBSYS_IEXGBE :
case NETTL_SUBSYS_HPPB_FDDI :
case NETTL_SUBSYS_EISA_FDDI :
case NETTL_SUBSYS_PCI_FDDI :
case NETTL_SUBSYS_HPPB_FDDI :
case NETTL_SUBSYS_EISA_FDDI :
case NETTL_SUBSYS_PCI_FDDI :
+ /* We're going to assume it's ethernet if we don't recognize the
+ subsystem -- We'll probably spew junks and core if it isn't... */
wth->file_encap = WTAP_ENCAP_PER_PACKET;
wth->file_encap = WTAP_ENCAP_PER_PACKET;
- phdr->pkt_encap = WTAP_ENCAP_NETTL_UNKNOWN;
+ phdr->pkt_encap = WTAP_ENCAP_NETTL_ETHERNET;
length = pntohl(&rec_hdr.length);
caplen = pntohl(&rec_hdr.caplen);
padlen = 0;
length = pntohl(&rec_hdr.length);
caplen = pntohl(&rec_hdr.caplen);
padlen = 0;
#define NETTL_SUBSYS_IGELAN 252
#define NETTL_SUBSYS_IETHER 253
#define NETTL_SUBSYS_IXGBE 265
#define NETTL_SUBSYS_IGELAN 252
#define NETTL_SUBSYS_IETHER 253
#define NETTL_SUBSYS_IXGBE 265
-#define NETTL_SUBSYS_IGSSN 270
#define NETTL_SUBSYS_ICXGBE 271
#define NETTL_SUBSYS_ICXGBE 271
+#define NETTL_SUBSYS_IEXGBE 275
/* FDDI cards */
#define NETTL_SUBSYS_HPPB_FDDI 95
/* FDDI cards */
#define NETTL_SUBSYS_HPPB_FDDI 95
#define NETTL_SUBSYS_TOKEN 31
#define NETTL_SUBSYS_PCI_TR 187
#define NETTL_SUBSYS_TOKEN 31
#define NETTL_SUBSYS_PCI_TR 187
+/* Accelerated Virtual I/O (AVIO) drivers */
+#define NETTL_SUBSYS_HSSN 269
+#define NETTL_SUBSYS_IGSSN 270
+
/* from /usr/include/sys/subsys_id.h */
#define NETTL_HDR_HDRIN 0x80000000
/* from /usr/include/sys/subsys_id.h */
#define NETTL_HDR_HDRIN 0x80000000
#define NETTL_HDR_PTOP 0x00400000
#define NETTL_HDR_SUBSYSTEM_BITS_MASK 0x000fffff
#define NETTL_HDR_PTOP 0x00400000
#define NETTL_HDR_SUBSYSTEM_BITS_MASK 0x000fffff
+#define NETTL_HDR_PDU_MASK 0x30000000
+
int nettl_open(wtap *wth, int *err, gchar **err_info);
gboolean nettl_dump_open(wtap_dumper *wdh, gboolean cant_seek _U_, int *err);
int nettl_dump_can_write_encap(int encap);
int nettl_open(wtap *wth, int *err, gchar **err_info);
gboolean nettl_dump_open(wtap_dumper *wdh, gboolean cant_seek _U_, int *err);
int nettl_dump_can_write_encap(int encap);