diff options
author | Johannes Berg <johannes.berg@intel.com> | 2012-11-08 09:29:28 -0500 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-11-09 11:26:41 -0500 |
commit | 08643315e55fd781cf2d533d33d41a280b33133f (patch) | |
tree | cfa4b63a8733aee8745c74344180cfcf3f7f62ac /net/mac80211/debugfs_netdev.c | |
parent | 1c963bec3534b175eed6f216a9d6ed6f082fe740 (diff) |
mac80211: add debugfs file for HW queues
Add a debugfs file showing which HW queues were
allocated to a virtual interface, including the
CAB queue for AP interfaces.
Change-Id: I486924e961b6ad6785a79db09620919ee644e703
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/debugfs_netdev.c')
-rw-r--r-- | net/mac80211/debugfs_netdev.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/net/mac80211/debugfs_netdev.c b/net/mac80211/debugfs_netdev.c index 9b6afb3698f6..ba9bd0ef119a 100644 --- a/net/mac80211/debugfs_netdev.c +++ b/net/mac80211/debugfs_netdev.c | |||
@@ -173,6 +173,26 @@ IEEE80211_IF_FILE(txpower, vif.bss_conf.txpower, DEC); | |||
173 | IEEE80211_IF_FILE(ap_power_level, ap_power_level, DEC); | 173 | IEEE80211_IF_FILE(ap_power_level, ap_power_level, DEC); |
174 | IEEE80211_IF_FILE(user_power_level, user_power_level, DEC); | 174 | IEEE80211_IF_FILE(user_power_level, user_power_level, DEC); |
175 | 175 | ||
176 | static ssize_t | ||
177 | ieee80211_if_fmt_hw_queues(const struct ieee80211_sub_if_data *sdata, | ||
178 | char *buf, int buflen) | ||
179 | { | ||
180 | int len; | ||
181 | |||
182 | len = scnprintf(buf, buflen, "AC queues: VO:%d VI:%d BE:%d BK:%d\n", | ||
183 | sdata->vif.hw_queue[IEEE80211_AC_VO], | ||
184 | sdata->vif.hw_queue[IEEE80211_AC_VI], | ||
185 | sdata->vif.hw_queue[IEEE80211_AC_BE], | ||
186 | sdata->vif.hw_queue[IEEE80211_AC_BK]); | ||
187 | |||
188 | if (sdata->vif.type == NL80211_IFTYPE_AP) | ||
189 | len += scnprintf(buf + len, buflen - len, "cab queue: %d\n", | ||
190 | sdata->vif.cab_queue); | ||
191 | |||
192 | return len; | ||
193 | } | ||
194 | __IEEE80211_IF_FILE(hw_queues, NULL); | ||
195 | |||
176 | /* STA attributes */ | 196 | /* STA attributes */ |
177 | IEEE80211_IF_FILE(bssid, u.mgd.bssid, MAC); | 197 | IEEE80211_IF_FILE(bssid, u.mgd.bssid, MAC); |
178 | IEEE80211_IF_FILE(aid, u.mgd.aid, DEC); | 198 | IEEE80211_IF_FILE(aid, u.mgd.aid, DEC); |
@@ -511,6 +531,7 @@ static void add_common_files(struct ieee80211_sub_if_data *sdata) | |||
511 | DEBUGFS_ADD(rc_rateidx_mask_5ghz); | 531 | DEBUGFS_ADD(rc_rateidx_mask_5ghz); |
512 | DEBUGFS_ADD(rc_rateidx_mcs_mask_2ghz); | 532 | DEBUGFS_ADD(rc_rateidx_mcs_mask_2ghz); |
513 | DEBUGFS_ADD(rc_rateidx_mcs_mask_5ghz); | 533 | DEBUGFS_ADD(rc_rateidx_mcs_mask_5ghz); |
534 | DEBUGFS_ADD(hw_queues); | ||
514 | } | 535 | } |
515 | 536 | ||
516 | static void add_sta_files(struct ieee80211_sub_if_data *sdata) | 537 | static void add_sta_files(struct ieee80211_sub_if_data *sdata) |