aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ixveriwave.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2015-07-07 00:39:50 -0700
committerGuy Harris <guy@alum.mit.edu>2015-07-07 07:40:31 +0000
commit53fcaabe66a7a307f231412111f7890b29bcb6d2 (patch)
tree974bf8c981c17daee0e2070b537328e66ac2bab8 /epan/dissectors/packet-ixveriwave.c
parent21754f43e1e7139bcd3d673714c2a191681a63e9 (diff)
Use the NSS provided by the Ixia Veriwave hardware.
It doesn't appear to provide the FEC type, although radiotap does, so add a flag to indicate whether we have that. Change-Id: I298d79bc6b640ee2408c3d70075c32bf331a210c Reviewed-on: https://code.wireshark.org/review/9533 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-ixveriwave.c')
-rw-r--r--epan/dissectors/packet-ixveriwave.c26
1 files changed, 18 insertions, 8 deletions
diff --git a/epan/dissectors/packet-ixveriwave.c b/epan/dissectors/packet-ixveriwave.c
index 04cab895db..d56c936002 100644
--- a/epan/dissectors/packet-ixveriwave.c
+++ b/epan/dissectors/packet-ixveriwave.c
@@ -650,8 +650,9 @@ wlantap_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_tree
tvbuff_t *next_tvb;
guint length;
gint8 dbm;
+ guint8 plcp_type;
guint8 mcs_index;
- guint8 ness;
+ guint8 nss;
float phyRate;
guint i;
@@ -719,10 +720,11 @@ wlantap_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_tree
offset +=2;
phyRate = (float)tvb_get_letohs(tvb, offset) / 10;
offset +=2;
- ness = tvb_get_guint8(tvb, offset);
+ plcp_type = tvb_get_guint8(tvb, offset);
offset++;
mcs_index = tvb_get_guint8(tvb, offset);
offset++;
+ nss = tvb_get_guint8(tvb, offset);
offset++;
if ((vw_rflags & FLAGS_CHAN_HT) || (vw_rflags & FLAGS_CHAN_VHT)) {
@@ -733,19 +735,23 @@ wlantap_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_tree
phdr.phy_info.info_11ac.short_gi = ((vw_rflags & FLAGS_CHAN_SHORTGI) != 0);
/*
* XXX - this probably has only one user, so only one MCS index
- * and only one NSS, but where's the NSS?
+ * and only one NSS.
*/
- for (i = 0; i < 4; i++)
+ phdr.phy_info.info_11ac.nss[0] = nss;
+ phdr.phy_info.info_11ac.mcs[0] = mcs_index;
+ for (i = 1; i < 4; i++)
phdr.phy_info.info_11ac.nss[i] = 0;
} else {
+ /*
+ * XXX - where's the number of extension spatial streams?
+ * The code in wiretap/vwr.c doesn't seem to provide it.
+ */
phdr.phy = PHDR_802_11_PHY_11N;
phdr.phy_info.info_11n.presence_flags =
PHDR_802_11N_HAS_MCS_INDEX |
- PHDR_802_11N_HAS_SHORT_GI |
- PHDR_802_11N_HAS_NESS;
+ PHDR_802_11N_HAS_SHORT_GI;
phdr.phy_info.info_11n.mcs_index = mcs_index;
phdr.phy_info.info_11n.short_gi = ((vw_rflags & FLAGS_CHAN_SHORTGI) != 0);
- phdr.phy_info.info_11n.ness = ness;
}
if (tree) {
proto_tree_add_item(tap_tree, hf_radiotap_mcsindex,
@@ -759,7 +765,11 @@ wlantap_dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_tree
"%.1f (MCS %d)", phyRate, mcs_index);
}
} else {
- /* XXX - CHAN_OFDM could be 11a or 11g */
+ /*
+ * XXX - CHAN_OFDM could be 11a or 11g.
+ *
+ * XXX - use the PLCP type?
+ */
if (vw_chanflags & CHAN_CCK) {
phdr.phy = PHDR_802_11_PHY_11B;
}