diff options
author | Guy Harris <guy@alum.mit.edu> | 2017-02-12 02:03:13 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2017-02-12 10:03:36 +0000 |
commit | 6bbbc3456b132a8ba62202b988bf9abb1d923d0f (patch) | |
tree | ba02dc34c9a6d1efcfbc8f1085c65ca3a4378458 /epan/dissectors | |
parent | 6a3762576b88e5ecbd1ce1019d40b96c6dd1da1d (diff) |
Fill in pseudo-header fields in order, and add the group ID for 11ac.
Change-Id: I0011917b77b1adc0cb6effd5d9d902f541675d78
Reviewed-on: https://code.wireshark.org/review/20066
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors')
-rw-r--r-- | epan/dissectors/packet-ieee80211-prism.c | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/epan/dissectors/packet-ieee80211-prism.c b/epan/dissectors/packet-ieee80211-prism.c index e442a5f5fe..432d6f4389 100644 --- a/epan/dissectors/packet-ieee80211-prism.c +++ b/epan/dissectors/packet-ieee80211-prism.c @@ -459,23 +459,23 @@ prism_rate_return_sig(guint32 rate_phy1, guint32 rate_phy2, struct ieee_802_11_p phdr->phy = PHDR_802_11_PHY_11N; sig_a_1 = (rate_phy1 >> 4) & 0xFFFF; sig_a_2 = (rate_phy2) & 0xFFF; - bw = 20 << ((sig_a_1 >> 7) & 1); - phdr->phy_info.info_11n.has_bandwidth = 1; - phdr->phy_info.info_11n.bandwidth = ((sig_a_1 >> 7) & 1); mcs = sig_a_1 & 0x7f; phdr->phy_info.info_11n.has_mcs_index = 1; phdr->phy_info.info_11n.mcs_index = mcs; + bw = 20 << ((sig_a_1 >> 7) & 1); + phdr->phy_info.info_11n.has_bandwidth = 1; + phdr->phy_info.info_11n.bandwidth = ((sig_a_1 >> 7) & 1); sgi = (sig_a_2 >> 7) & 1; phdr->phy_info.info_11n.has_short_gi = 1; phdr->phy_info.info_11n.short_gi = sgi; - phdr->phy_info.info_11n.has_ness = 1; - phdr->phy_info.info_11n.ness = (sig_a_2 >> 8) & 3; ldpc = (sig_a_2 >> 6) & 1; phdr->phy_info.info_11n.has_fec = 1; phdr->phy_info.info_11n.fec = ldpc; stbc = ((sig_a_2 >> 4) & 3)?1:0; phdr->phy_info.info_11n.has_stbc_streams = 1; phdr->phy_info.info_11n.stbc_streams = stbc; + phdr->phy_info.info_11n.has_ness = 1; + phdr->phy_info.info_11n.ness = (sig_a_2 >> 8) & 3; nss = (mcs >> 3) + 1; /* Check limits */ disp_rate = 0; @@ -511,19 +511,21 @@ prism_rate_return_sig(guint32 rate_phy1, guint32 rate_phy2, struct ieee_802_11_p phdr->phy = PHDR_802_11_PHY_11AC; sig_a_1 = (rate_phy1 >> 4) & 0xFFFFFF; sig_a_2 = (rate_phy2) & 0xFFFFFF; - bw = 20 << (sig_a_1 & 3); - phdr->phy_info.info_11ac.has_bandwidth = 1; - phdr->phy_info.info_11ac.bandwidth = bw_map[(sig_a_1 & 3)]; + stbc = (sig_a_1 >> 3) & 1; + phdr->phy_info.info_11ac.has_stbc = 1; + phdr->phy_info.info_11ac.stbc = stbc; sgi = sig_a_2 & 1; phdr->phy_info.info_11ac.has_short_gi = 1; phdr->phy_info.info_11ac.short_gi = sgi; + bw = 20 << (sig_a_1 & 3); + phdr->phy_info.info_11ac.has_bandwidth = 1; + phdr->phy_info.info_11ac.bandwidth = bw_map[(sig_a_1 & 3)]; ldpc = (sig_a_2 >> 2) & 1; phdr->phy_info.info_11ac.has_fec = 1; phdr->phy_info.info_11ac.fec = ldpc; - stbc = (sig_a_1 >> 3) & 1; - phdr->phy_info.info_11ac.has_stbc = 1; - phdr->phy_info.info_11ac.stbc = stbc; groupid = (sig_a_1 >> 4) & 0x3F; + phdr->phy_info.info_11ac.has_group_id = 1; + phdr->phy_info.info_11ac.group_id = groupid; if (groupid == 0 || groupid == 63) su_ppdu = TRUE; |