From da3c7310a0a38eedc803c9fe7cd292bb3aa1193a Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Sun, 10 Aug 2014 11:35:16 -0700 Subject: [PATCH] monitor: Add support for decoding connection quality monitor attributes --- monitor/nlmon.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/monitor/nlmon.c b/monitor/nlmon.c index a22f83d4..e9dd419a 100644 --- a/monitor/nlmon.c +++ b/monitor/nlmon.c @@ -418,6 +418,19 @@ static const struct attr_entry frame_types_table[] = { { } }; +static const struct attr_entry cqm_table[] = { + { NL80211_ATTR_CQM_RSSI_THOLD, "RSSI threshold", ATTR_U32 }, + { NL80211_ATTR_CQM_RSSI_HYST, "RSSI hysteresis", ATTR_U32 }, + { NL80211_ATTR_CQM_RSSI_THRESHOLD_EVENT, + "RSSI threshold event", ATTR_U32 }, + { NL80211_ATTR_CQM_PKT_LOSS_EVENT, + "Packet loss event", ATTR_U32 }, + { NL80211_ATTR_CQM_TXE_RATE, "TX error rate", ATTR_U32 }, + { NL80211_ATTR_CQM_TXE_PKTS, "TX error packets", ATTR_U32 }, + { NL80211_ATTR_CQM_TXE_INTVL, "TX error interval", ATTR_U32 }, + { } +}; + static const struct attr_entry attr_table[] = { { NL80211_ATTR_WIPHY, "Wiphy", ATTR_U32 }, @@ -612,7 +625,7 @@ static const struct attr_entry attr_table[] = { { NL80211_ATTR_PS_STATE, "PS State", ATTR_U32 }, { NL80211_ATTR_CQM, - "CQM" }, + "CQM", ATTR_NESTED, { cqm_table } }, { NL80211_ATTR_LOCAL_STATE_CHANGE, "Local State Change", ATTR_FLAG }, { NL80211_ATTR_AP_ISOLATE,