aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2003-05-23 02:23:48 (GMT)
committerJouni Malinen <j@w1.fi>2003-05-23 02:23:48 (GMT)
commit0d9b49ac7e5a1b3185b2602a7c8b73ea4e2439a4 (patch)
tree5d52a400950978168e610c9c18ed2899a7ead694
parentf43acabbd8861fcfa0e1aa45c3ec3aee3b4d440d (diff)
downloadhostap-history-0d9b49ac7e5a1b3185b2602a7c8b73ea4e2439a4.zip
hostap-history-0d9b49ac7e5a1b3185b2602a7c8b73ea4e2439a4.tar.gz
hostap-history-0d9b49ac7e5a1b3185b2602a7c8b73ea4e2439a4.tar.bz2
TX callback handler is now called from a tasklet, not hw irq handler.
Remove tx_callback_list and separate tasklet for processing these frames since there is no need to avoid spending more time in hw irq handler anymore.
-rw-r--r--driver/modules/hostap_hw.c38
-rw-r--r--driver/modules/hostap_wlan.h4
2 files changed, 1 insertions, 41 deletions
diff --git a/driver/modules/hostap_hw.c b/driver/modules/hostap_hw.c
index db695bb..2b37bb9 100644
--- a/driver/modules/hostap_hw.c
+++ b/driver/modules/hostap_hw.c
@@ -2357,28 +2357,6 @@ static void prism2_alloc_ev(struct net_device *dev)
}
-/* TX callback data stored in skb->cb; this must not grow over the maximum
- * skb->cb size (48 bytes) */
-struct hostap_tx_callback_skb_cb {
- struct hostap_tx_callback_info *cb;
- int ok;
-};
-
-
-/* Called only as a tasklet (software IRQ) */
-static void hostap_tx_callback_tasklet(unsigned long data)
-{
- local_info_t *local = (local_info_t *) data;
- struct sk_buff *skb;
- struct hostap_tx_callback_skb_cb *cb_data;
-
- while ((skb = skb_dequeue(&local->tx_callback_list)) != NULL) {
- cb_data = (struct hostap_tx_callback_skb_cb *) skb->cb;
- cb_data->cb->func(skb, cb_data->ok, cb_data->cb->data);
- }
-}
-
-
/* Called only as a tasklet (software IRQ) */
static void hostap_tx_callback(local_info_t *local,
struct hfa384x_tx_frame *txdesc, int ok,
@@ -2387,7 +2365,6 @@ static void hostap_tx_callback(local_info_t *local,
u16 sw_support, hdrlen, len;
struct sk_buff *skb;
struct hostap_tx_callback_info *cb;
- struct hostap_tx_callback_skb_cb *cb_data;
/* Make sure that frame was from us. */
if (memcmp(txdesc->addr2, local->dev->dev_addr, ETH_ALEN)) {
@@ -2426,13 +2403,7 @@ static void hostap_tx_callback(local_info_t *local,
skb->dev = local->dev;
skb->mac.raw = skb->data;
- /* Store TX callback info pointer to private data in the skb and finish
- * TX callback handling in tasklet so that hw IRQ can be ACKed now */
- cb_data = (struct hostap_tx_callback_skb_cb *) skb->cb;
- cb_data->cb = cb;
- cb_data->ok = ok;
- skb_queue_tail(&local->tx_callback_list, skb);
- HOSTAP_TASKLET_SCHEDULE(&local->tx_callback_tasklet);
+ cb->func(skb, ok, cb->data);
}
@@ -3312,10 +3283,6 @@ prism2_init_local_data(struct prism2_helper_functions *funcs, int card_idx)
(unsigned long) local);
hostap_info_init(local);
- HOSTAP_TASKLET_INIT(&local->tx_callback_tasklet,
- hostap_tx_callback_tasklet, (unsigned long) local);
- skb_queue_head_init(&local->tx_callback_list);
-
HOSTAP_TASKLET_INIT(&local->rx_tasklet,
hostap_rx_tasklet, (unsigned long) local);
skb_queue_head_init(&local->rx_list);
@@ -3417,9 +3384,6 @@ static void prism2_free_local_data(local_info_t *local)
while ((skb = skb_dequeue(&local->info_list)) != NULL)
dev_kfree_skb(skb);
- while ((skb = skb_dequeue(&local->tx_callback_list)) != NULL)
- dev_kfree_skb(skb);
-
while ((skb = skb_dequeue(&local->rx_list)) != NULL)
dev_kfree_skb(skb);
diff --git a/driver/modules/hostap_wlan.h b/driver/modules/hostap_wlan.h
index 64b7727..438fdd6 100644
--- a/driver/modules/hostap_wlan.h
+++ b/driver/modules/hostap_wlan.h
@@ -1250,10 +1250,6 @@ struct local_info {
struct sk_buff_head info_list; /* info frames as skb's for
* info_tasklet */
- HOSTAP_TASKLET tx_callback_tasklet;
- struct sk_buff_head tx_callback_list; /* queued TX ACK/no-ACK data
- * frames for tx_callback_tasklet
- */
struct hostap_tx_callback_info *tx_callback; /* registered TX callbacks
*/