diff options
author | Ivo van Doorn <ivdoorn@gmail.com> | 2008-01-10 16:40:13 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:09:48 -0500 |
commit | 89539ebe2f2eb3a0d77b92884b092f2eb2575bd9 (patch) | |
tree | efa1eb958569e87faa0111755a6cabb7d132420c /drivers | |
parent | 40561b8426c27f187e2ae496ed603e7c4e3ab818 (diff) |
rt2x00: Fix queue_idx initialization
For TX rings the queue_idx should start at
IEEE80211_TX_QUEUE_DATA0 and for each followup
ring this index needs to be increased.
For the RX ring the queue_idx should be set
to 0. We don't need to initialize the tx_params.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00dev.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c index 72cfe6f866f8..c4be2ac4d7a4 100644 --- a/drivers/net/wireless/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/rt2x00/rt2x00dev.c | |||
@@ -1239,11 +1239,16 @@ static int rt2x00lib_alloc_rings(struct rt2x00_dev *rt2x00dev) | |||
1239 | 1239 | ||
1240 | /* | 1240 | /* |
1241 | * Initialize ring parameters. | 1241 | * Initialize ring parameters. |
1242 | * cw_min: 2^5 = 32. | 1242 | * RX: queue_idx = 0 |
1243 | * cw_max: 2^10 = 1024. | 1243 | * TX: queue_idx = IEEE80211_TX_QUEUE_DATA0 + index |
1244 | * TX: cw_min: 2^5 = 32. | ||
1245 | * TX: cw_max: 2^10 = 1024. | ||
1244 | */ | 1246 | */ |
1245 | index = 0; | 1247 | rt2x00dev->rx->rt2x00dev = rt2x00dev; |
1246 | ring_for_each(rt2x00dev, ring) { | 1248 | rt2x00dev->rx->queue_idx = 0; |
1249 | |||
1250 | index = IEEE80211_TX_QUEUE_DATA0; | ||
1251 | txring_for_each(rt2x00dev, ring) { | ||
1247 | ring->rt2x00dev = rt2x00dev; | 1252 | ring->rt2x00dev = rt2x00dev; |
1248 | ring->queue_idx = index++; | 1253 | ring->queue_idx = index++; |
1249 | ring->tx_params.aifs = 2; | 1254 | ring->tx_params.aifs = 2; |