mac80211: split PS buffers into ACs
For uAPSD support we'll need to have per-AC PS buffers. As this is a major undertaking, split the buffers before really adding support for uAPSD. This already makes some reference to the uapsd_queues variable, but for now that will never be non-zero. Since book-keeping is complicated, also change the logic for keeping a maximum of frames only and allow 64 frames per AC (up from 128 for a station). Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
committed by
John W. Linville
parent
6075039712
commit
948d887dec
@@ -78,8 +78,14 @@ static ssize_t sta_num_ps_buf_frames_read(struct file *file,
|
||||
size_t count, loff_t *ppos)
|
||||
{
|
||||
struct sta_info *sta = file->private_data;
|
||||
return mac80211_format_buffer(userbuf, count, ppos, "%u\n",
|
||||
skb_queue_len(&sta->ps_tx_buf));
|
||||
char buf[17*IEEE80211_NUM_ACS], *p = buf;
|
||||
int ac;
|
||||
|
||||
for (ac = 0; ac < IEEE80211_NUM_ACS; ac++)
|
||||
p += scnprintf(p, sizeof(buf)+buf-p, "AC%d: %d\n", ac,
|
||||
skb_queue_len(&sta->ps_tx_buf[ac]) +
|
||||
skb_queue_len(&sta->tx_filtered[ac]));
|
||||
return simple_read_from_buffer(userbuf, count, ppos, buf, p - buf);
|
||||
}
|
||||
STA_OPS(num_ps_buf_frames);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user