diff options
author | Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com> | 2011-10-06 19:05:02 +0200 |
---|---|---|
committer | Philippe LANGLAIS <philippe.langlais@stericsson.com> | 2011-10-13 10:23:49 +0200 |
commit | 847817a7ac38983d030d87d4c1b38e379a26fe8e (patch) | |
tree | af0b449b8359ed45a234a377c0a81bde69a36653 /drivers/staging/cw1200/queue.h | |
parent | 5a3348f06558026c5c842112b83674e00903064c (diff) |
cw1200: Accurate reporting of TX status.
* Accurate reporting of TX status is implemented (needed for UAPSD and PSPOLL).
* Leaking of TX rate policies is fixed.
* skb destructor is implemented.
* Time to live for queued frames is implemented.
* cw1200_tx is split by separate TX handlers (like in mac80211).
* cw1200_skb_to_wsm is not existing anymore.
* BT coex: null frames are prioritized as management frames.
* Debug: added printing of rate policies in use.
ST-Ericsson ID: 354950
ST-Ericsson ID: 360749
Change-Id: I920d398418df99c21b37a16ef16591e58a82151d
Signed-off-by: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/33542
Reviewed-by: Bartosz MARKOWSKI <bartosz.markowski@tieto.com>
Reviewed-by: Philippe LANGLAIS <philippe.langlais@stericsson.com>
Diffstat (limited to 'drivers/staging/cw1200/queue.h')
-rw-r--r-- | drivers/staging/cw1200/queue.h | 40 |
1 files changed, 25 insertions, 15 deletions
diff --git a/drivers/staging/cw1200/queue.h b/drivers/staging/cw1200/queue.h index 502496b142b..bff33625c8a 100644 --- a/drivers/staging/cw1200/queue.h +++ b/drivers/staging/cw1200/queue.h @@ -22,6 +22,10 @@ /* forward */ struct cw1200_queue_stats; +typedef void (*cw1200_queue_skb_dtor_t)(struct cw1200_common *priv, + struct sk_buff *skb, + const struct cw1200_txpriv *txpriv); + struct cw1200_queue { struct cw1200_queue_stats *stats; size_t capacity; @@ -38,6 +42,8 @@ struct cw1200_queue { spinlock_t lock; u8 queue_id; u8 generation; + struct timer_list gc; + unsigned long ttl; }; struct cw1200_queue_stats { @@ -46,29 +52,36 @@ struct cw1200_queue_stats { int num_queued; size_t map_capacity; wait_queue_head_t wait_link_id_empty; + cw1200_queue_skb_dtor_t skb_dtor; + struct cw1200_common *priv; }; struct cw1200_txpriv { u8 link_id; u8 raw_link_id; u8 tid; + u8 rate_id; + u8 offset; }; int cw1200_queue_stats_init(struct cw1200_queue_stats *stats, - size_t map_capacity); + size_t map_capacity, + cw1200_queue_skb_dtor_t skb_dtor, + struct cw1200_common *priv); int cw1200_queue_init(struct cw1200_queue *queue, struct cw1200_queue_stats *stats, u8 queue_id, - size_t capacity); -int cw1200_queue_clear(struct cw1200_queue *queue, struct cw1200_common *priv); + size_t capacity, + unsigned long ttl); +int cw1200_queue_clear(struct cw1200_queue *queue); void cw1200_queue_stats_deinit(struct cw1200_queue_stats *stats); -void cw1200_queue_deinit(struct cw1200_queue *queue, - struct cw1200_common *priv); +void cw1200_queue_deinit(struct cw1200_queue *queue); size_t cw1200_queue_get_num_queued(struct cw1200_queue *queue, u32 link_id_map); -int cw1200_queue_put(struct cw1200_queue *queue, struct cw1200_common *cw1200, - struct sk_buff *skb, struct cw1200_txpriv *txpriv); +int cw1200_queue_put(struct cw1200_queue *queue, + struct sk_buff *skb, + struct cw1200_txpriv *txpriv); int cw1200_queue_get(struct cw1200_queue *queue, u32 link_id_map, struct wsm_tx **tx, @@ -76,15 +89,12 @@ int cw1200_queue_get(struct cw1200_queue *queue, const struct cw1200_txpriv **txpriv); int cw1200_queue_requeue(struct cw1200_queue *queue, u32 packetID); int cw1200_queue_requeue_all(struct cw1200_queue *queue); -int cw1200_queue_remove(struct cw1200_queue *queue, struct cw1200_common *priv, - u32 packetID); +int cw1200_queue_remove(struct cw1200_queue *queue, + u32 packetID); int cw1200_queue_get_skb(struct cw1200_queue *queue, u32 packetID, - struct sk_buff **skb, - const struct cw1200_txpriv **txpriv); -void cw1200_queue_lock(struct cw1200_queue *queue, - struct cw1200_common *cw1200); -void cw1200_queue_unlock(struct cw1200_queue *queue, - struct cw1200_common *cw1200); + struct sk_buff **skb); +void cw1200_queue_lock(struct cw1200_queue *queue); +void cw1200_queue_unlock(struct cw1200_queue *queue); bool cw1200_queue_stats_is_empty(struct cw1200_queue_stats *stats, u32 link_id_map); |