summaryrefslogtreecommitdiff
path: root/iwinfo_nl80211.c
diff options
context:
space:
mode:
authorDavid Bauer <mail@david-bauer.net>2021-04-17 23:05:16 +0200
committerDavid Bauer <mail@david-bauer.net>2021-05-02 00:20:54 +0200
commitc45f0b584b4b86f8250f90ea19afca271c114fa2 (patch)
treea952946871da252ca62d4426e905f285870e2a14 /iwinfo_nl80211.c
parentcd23727f72b7859ba572c4e273247578c2124926 (diff)
downloadiwinfo-c45f0b584b4b86f8250f90ea19afca271c114fa2.tar.gz
iwinfo: add 802.11ax HE rate information
This adds 802.11ax HE specific rate information to iwinfo. Add fields for HE status of a STA as well as DCM and guard interval fields specific to HE operation. Signed-off-by: David Bauer <mail@david-bauer.net>
Diffstat (limited to 'iwinfo_nl80211.c')
-rw-r--r--iwinfo_nl80211.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/iwinfo_nl80211.c b/iwinfo_nl80211.c
index aeff778..eea521e 100644
--- a/iwinfo_nl80211.c
+++ b/iwinfo_nl80211.c
@@ -1869,7 +1869,19 @@ static void nl80211_parse_rateinfo(struct nlattr **ri,
else if (ri[NL80211_RATE_INFO_BITRATE])
re->rate = nla_get_u16(ri[NL80211_RATE_INFO_BITRATE]) * 100;
- if (ri[NL80211_RATE_INFO_VHT_MCS])
+ if (ri[NL80211_RATE_INFO_HE_MCS])
+ {
+ re->is_he = 1;
+ re->mcs = nla_get_u8(ri[NL80211_RATE_INFO_HE_MCS]);
+
+ if (ri[NL80211_RATE_INFO_HE_NSS])
+ re->nss = nla_get_u8(ri[NL80211_RATE_INFO_HE_NSS]);
+ if (ri[NL80211_RATE_INFO_HE_GI])
+ re->he_gi = nla_get_u8(ri[NL80211_RATE_INFO_HE_GI]);
+ if (ri[NL80211_RATE_INFO_HE_DCM])
+ re->he_dcm = nla_get_u8(ri[NL80211_RATE_INFO_HE_DCM]);
+ }
+ else if (ri[NL80211_RATE_INFO_VHT_MCS])
{
re->is_vht = 1;
re->mcs = nla_get_u8(ri[NL80211_RATE_INFO_VHT_MCS]);