diff options
author | Kalle Valo <kalle.valo@iki.fi> | 2010-02-07 12:51:00 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-02-08 16:51:00 -0500 |
commit | 8b2bbe66abfdc60f73b094a56ab29bfbf939201c (patch) | |
tree | e964523cb00ee9dc17b2d574f104877076b2a864 /drivers | |
parent | 3b27521a5be8b700451d54d4fa670f754e7f9720 (diff) |
b43legacy: remove get_tx_stats() mac80211 op
get_tx_stats() will be removed from mac80211.
Compile-tested only.
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: Kalle Valo <kalle.valo@iki.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/b43legacy/dma.c | 20 | ||||
-rw-r--r-- | drivers/net/wireless/b43legacy/dma.h | 10 | ||||
-rw-r--r-- | drivers/net/wireless/b43legacy/main.c | 24 | ||||
-rw-r--r-- | drivers/net/wireless/b43legacy/pio.c | 13 | ||||
-rw-r--r-- | drivers/net/wireless/b43legacy/pio.h | 11 |
5 files changed, 0 insertions, 78 deletions
diff --git a/drivers/net/wireless/b43legacy/dma.c b/drivers/net/wireless/b43legacy/dma.c index 0a86bdf53154..8b9387c6ff36 100644 --- a/drivers/net/wireless/b43legacy/dma.c +++ b/drivers/net/wireless/b43legacy/dma.c | |||
@@ -1411,7 +1411,6 @@ int b43legacy_dma_tx(struct b43legacy_wldev *dev, | |||
1411 | b43legacyerr(dev->wl, "DMA tx mapping failure\n"); | 1411 | b43legacyerr(dev->wl, "DMA tx mapping failure\n"); |
1412 | goto out_unlock; | 1412 | goto out_unlock; |
1413 | } | 1413 | } |
1414 | ring->nr_tx_packets++; | ||
1415 | if ((free_slots(ring) < SLOTS_PER_PACKET) || | 1414 | if ((free_slots(ring) < SLOTS_PER_PACKET) || |
1416 | should_inject_overflow(ring)) { | 1415 | should_inject_overflow(ring)) { |
1417 | /* This TX ring is full. */ | 1416 | /* This TX ring is full. */ |
@@ -1527,25 +1526,6 @@ void b43legacy_dma_handle_txstatus(struct b43legacy_wldev *dev, | |||
1527 | spin_unlock(&ring->lock); | 1526 | spin_unlock(&ring->lock); |
1528 | } | 1527 | } |
1529 | 1528 | ||
1530 | void b43legacy_dma_get_tx_stats(struct b43legacy_wldev *dev, | ||
1531 | struct ieee80211_tx_queue_stats *stats) | ||
1532 | { | ||
1533 | const int nr_queues = dev->wl->hw->queues; | ||
1534 | struct b43legacy_dmaring *ring; | ||
1535 | unsigned long flags; | ||
1536 | int i; | ||
1537 | |||
1538 | for (i = 0; i < nr_queues; i++) { | ||
1539 | ring = priority_to_txring(dev, i); | ||
1540 | |||
1541 | spin_lock_irqsave(&ring->lock, flags); | ||
1542 | stats[i].len = ring->used_slots / SLOTS_PER_PACKET; | ||
1543 | stats[i].limit = ring->nr_slots / SLOTS_PER_PACKET; | ||
1544 | stats[i].count = ring->nr_tx_packets; | ||
1545 | spin_unlock_irqrestore(&ring->lock, flags); | ||
1546 | } | ||
1547 | } | ||
1548 | |||
1549 | static void dma_rx(struct b43legacy_dmaring *ring, | 1529 | static void dma_rx(struct b43legacy_dmaring *ring, |
1550 | int *slot) | 1530 | int *slot) |
1551 | { | 1531 | { |
diff --git a/drivers/net/wireless/b43legacy/dma.h b/drivers/net/wireless/b43legacy/dma.h index 2f186003c31e..f9681041c2d8 100644 --- a/drivers/net/wireless/b43legacy/dma.h +++ b/drivers/net/wireless/b43legacy/dma.h | |||
@@ -243,8 +243,6 @@ struct b43legacy_dmaring { | |||
243 | int used_slots; | 243 | int used_slots; |
244 | /* Currently used slot in the ring. */ | 244 | /* Currently used slot in the ring. */ |
245 | int current_slot; | 245 | int current_slot; |
246 | /* Total number of packets sent. Statistics only. */ | ||
247 | unsigned int nr_tx_packets; | ||
248 | /* Frameoffset in octets. */ | 246 | /* Frameoffset in octets. */ |
249 | u32 frameoffset; | 247 | u32 frameoffset; |
250 | /* Descriptor buffer size. */ | 248 | /* Descriptor buffer size. */ |
@@ -292,9 +290,6 @@ void b43legacy_dma_free(struct b43legacy_wldev *dev); | |||
292 | void b43legacy_dma_tx_suspend(struct b43legacy_wldev *dev); | 290 | void b43legacy_dma_tx_suspend(struct b43legacy_wldev *dev); |
293 | void b43legacy_dma_tx_resume(struct b43legacy_wldev *dev); | 291 | void b43legacy_dma_tx_resume(struct b43legacy_wldev *dev); |
294 | 292 | ||
295 | void b43legacy_dma_get_tx_stats(struct b43legacy_wldev *dev, | ||
296 | struct ieee80211_tx_queue_stats *stats); | ||
297 | |||
298 | int b43legacy_dma_tx(struct b43legacy_wldev *dev, | 293 | int b43legacy_dma_tx(struct b43legacy_wldev *dev, |
299 | struct sk_buff *skb); | 294 | struct sk_buff *skb); |
300 | void b43legacy_dma_handle_txstatus(struct b43legacy_wldev *dev, | 295 | void b43legacy_dma_handle_txstatus(struct b43legacy_wldev *dev, |
@@ -315,11 +310,6 @@ void b43legacy_dma_free(struct b43legacy_wldev *dev) | |||
315 | { | 310 | { |
316 | } | 311 | } |
317 | static inline | 312 | static inline |
318 | void b43legacy_dma_get_tx_stats(struct b43legacy_wldev *dev, | ||
319 | struct ieee80211_tx_queue_stats *stats) | ||
320 | { | ||
321 | } | ||
322 | static inline | ||
323 | int b43legacy_dma_tx(struct b43legacy_wldev *dev, | 313 | int b43legacy_dma_tx(struct b43legacy_wldev *dev, |
324 | struct sk_buff *skb) | 314 | struct sk_buff *skb) |
325 | { | 315 | { |
diff --git a/drivers/net/wireless/b43legacy/main.c b/drivers/net/wireless/b43legacy/main.c index b4e89a35e3fb..08523a45e23b 100644 --- a/drivers/net/wireless/b43legacy/main.c +++ b/drivers/net/wireless/b43legacy/main.c | |||
@@ -2446,29 +2446,6 @@ static int b43legacy_op_conf_tx(struct ieee80211_hw *hw, u16 queue, | |||
2446 | return 0; | 2446 | return 0; |
2447 | } | 2447 | } |
2448 | 2448 | ||
2449 | static int b43legacy_op_get_tx_stats(struct ieee80211_hw *hw, | ||
2450 | struct ieee80211_tx_queue_stats *stats) | ||
2451 | { | ||
2452 | struct b43legacy_wl *wl = hw_to_b43legacy_wl(hw); | ||
2453 | struct b43legacy_wldev *dev = wl->current_dev; | ||
2454 | unsigned long flags; | ||
2455 | int err = -ENODEV; | ||
2456 | |||
2457 | if (!dev) | ||
2458 | goto out; | ||
2459 | spin_lock_irqsave(&wl->irq_lock, flags); | ||
2460 | if (likely(b43legacy_status(dev) >= B43legacy_STAT_STARTED)) { | ||
2461 | if (b43legacy_using_pio(dev)) | ||
2462 | b43legacy_pio_get_tx_stats(dev, stats); | ||
2463 | else | ||
2464 | b43legacy_dma_get_tx_stats(dev, stats); | ||
2465 | err = 0; | ||
2466 | } | ||
2467 | spin_unlock_irqrestore(&wl->irq_lock, flags); | ||
2468 | out: | ||
2469 | return err; | ||
2470 | } | ||
2471 | |||
2472 | static int b43legacy_op_get_stats(struct ieee80211_hw *hw, | 2449 | static int b43legacy_op_get_stats(struct ieee80211_hw *hw, |
2473 | struct ieee80211_low_level_stats *stats) | 2450 | struct ieee80211_low_level_stats *stats) |
2474 | { | 2451 | { |
@@ -3513,7 +3490,6 @@ static const struct ieee80211_ops b43legacy_hw_ops = { | |||
3513 | .bss_info_changed = b43legacy_op_bss_info_changed, | 3490 | .bss_info_changed = b43legacy_op_bss_info_changed, |
3514 | .configure_filter = b43legacy_op_configure_filter, | 3491 | .configure_filter = b43legacy_op_configure_filter, |
3515 | .get_stats = b43legacy_op_get_stats, | 3492 | .get_stats = b43legacy_op_get_stats, |
3516 | .get_tx_stats = b43legacy_op_get_tx_stats, | ||
3517 | .start = b43legacy_op_start, | 3493 | .start = b43legacy_op_start, |
3518 | .stop = b43legacy_op_stop, | 3494 | .stop = b43legacy_op_stop, |
3519 | .set_tim = b43legacy_op_beacon_set_tim, | 3495 | .set_tim = b43legacy_op_beacon_set_tim, |
diff --git a/drivers/net/wireless/b43legacy/pio.c b/drivers/net/wireless/b43legacy/pio.c index 51866c9a2769..017c0e9c37ef 100644 --- a/drivers/net/wireless/b43legacy/pio.c +++ b/drivers/net/wireless/b43legacy/pio.c | |||
@@ -477,7 +477,6 @@ int b43legacy_pio_tx(struct b43legacy_wldev *dev, | |||
477 | 477 | ||
478 | list_move_tail(&packet->list, &queue->txqueue); | 478 | list_move_tail(&packet->list, &queue->txqueue); |
479 | queue->nr_txfree--; | 479 | queue->nr_txfree--; |
480 | queue->nr_tx_packets++; | ||
481 | B43legacy_WARN_ON(queue->nr_txfree >= B43legacy_PIO_MAXTXPACKETS); | 480 | B43legacy_WARN_ON(queue->nr_txfree >= B43legacy_PIO_MAXTXPACKETS); |
482 | 481 | ||
483 | tasklet_schedule(&queue->txtask); | 482 | tasklet_schedule(&queue->txtask); |
@@ -546,18 +545,6 @@ void b43legacy_pio_handle_txstatus(struct b43legacy_wldev *dev, | |||
546 | tasklet_schedule(&queue->txtask); | 545 | tasklet_schedule(&queue->txtask); |
547 | } | 546 | } |
548 | 547 | ||
549 | void b43legacy_pio_get_tx_stats(struct b43legacy_wldev *dev, | ||
550 | struct ieee80211_tx_queue_stats *stats) | ||
551 | { | ||
552 | struct b43legacy_pio *pio = &dev->pio; | ||
553 | struct b43legacy_pioqueue *queue; | ||
554 | |||
555 | queue = pio->queue1; | ||
556 | stats[0].len = B43legacy_PIO_MAXTXPACKETS - queue->nr_txfree; | ||
557 | stats[0].limit = B43legacy_PIO_MAXTXPACKETS; | ||
558 | stats[0].count = queue->nr_tx_packets; | ||
559 | } | ||
560 | |||
561 | static void pio_rx_error(struct b43legacy_pioqueue *queue, | 548 | static void pio_rx_error(struct b43legacy_pioqueue *queue, |
562 | int clear_buffers, | 549 | int clear_buffers, |
563 | const char *error) | 550 | const char *error) |
diff --git a/drivers/net/wireless/b43legacy/pio.h b/drivers/net/wireless/b43legacy/pio.h index 464fec05a06d..8e6773ea6e75 100644 --- a/drivers/net/wireless/b43legacy/pio.h +++ b/drivers/net/wireless/b43legacy/pio.h | |||
@@ -74,10 +74,6 @@ struct b43legacy_pioqueue { | |||
74 | * posted to the device. We are waiting for the txstatus. | 74 | * posted to the device. We are waiting for the txstatus. |
75 | */ | 75 | */ |
76 | struct list_head txrunning; | 76 | struct list_head txrunning; |
77 | /* Total number or packets sent. | ||
78 | * (This counter can obviously wrap). | ||
79 | */ | ||
80 | unsigned int nr_tx_packets; | ||
81 | struct tasklet_struct txtask; | 77 | struct tasklet_struct txtask; |
82 | struct b43legacy_pio_txpacket | 78 | struct b43legacy_pio_txpacket |
83 | tx_packets_cache[B43legacy_PIO_MAXTXPACKETS]; | 79 | tx_packets_cache[B43legacy_PIO_MAXTXPACKETS]; |
@@ -106,8 +102,6 @@ int b43legacy_pio_tx(struct b43legacy_wldev *dev, | |||
106 | struct sk_buff *skb); | 102 | struct sk_buff *skb); |
107 | void b43legacy_pio_handle_txstatus(struct b43legacy_wldev *dev, | 103 | void b43legacy_pio_handle_txstatus(struct b43legacy_wldev *dev, |
108 | const struct b43legacy_txstatus *status); | 104 | const struct b43legacy_txstatus *status); |
109 | void b43legacy_pio_get_tx_stats(struct b43legacy_wldev *dev, | ||
110 | struct ieee80211_tx_queue_stats *stats); | ||
111 | void b43legacy_pio_rx(struct b43legacy_pioqueue *queue); | 105 | void b43legacy_pio_rx(struct b43legacy_pioqueue *queue); |
112 | 106 | ||
113 | /* Suspend TX queue in hardware. */ | 107 | /* Suspend TX queue in hardware. */ |
@@ -140,11 +134,6 @@ void b43legacy_pio_handle_txstatus(struct b43legacy_wldev *dev, | |||
140 | { | 134 | { |
141 | } | 135 | } |
142 | static inline | 136 | static inline |
143 | void b43legacy_pio_get_tx_stats(struct b43legacy_wldev *dev, | ||
144 | struct ieee80211_tx_queue_stats *stats) | ||
145 | { | ||
146 | } | ||
147 | static inline | ||
148 | void b43legacy_pio_rx(struct b43legacy_pioqueue *queue) | 137 | void b43legacy_pio_rx(struct b43legacy_pioqueue *queue) |
149 | { | 138 | { |
150 | } | 139 | } |