提交 ef2c0512 编写于 作者: S Seth Forshee 提交者: John W. Linville

brcmsmac: Introduce AMPDU sessions for assembling AMPDUs

AMPDU session allows MPDUs to be temporarily queued until either a full
AMPDU has been collected or circumstances dictate that transmission
should start with a partial AMPDU. Packets are added to the session by
calling brcms_c_ampdu_add_frame(). brcms_c_ampdu_finalize() should be
called to fix up the tx headers in the first and last packet before
adding the packets to the DMA ring. brmcs_c_sendampdu() is converted to
using AMPDU sessions.

This patch has no real value on it's own, but is needed in preparation
for elimination of the tx packet queue from brcmsmac.
Signed-off-by: NSeth Forshee <seth.forshee@canonical.com>
Reviewed-by: NPieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: NArend van Spriel <arend@broadcom.com>
Tested-by: NDaniel Wagner <wagi@monom.org>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 cb675f5f
......@@ -17,6 +17,32 @@
#ifndef _BRCM_AMPDU_H_
#define _BRCM_AMPDU_H_
/*
* Data structure representing an in-progress session for accumulating
* frames for AMPDU.
*
* wlc: pointer to common driver data
* skb_list: queue of skb's for AMPDU
* max_ampdu_len: maximum length for this AMPDU
* max_ampdu_frames: maximum number of frames for this AMPDU
* ampdu_len: total number of bytes accumulated for this AMPDU
* dma_len: DMA length of this AMPDU
*/
struct brcms_ampdu_session {
struct brcms_c_info *wlc;
struct sk_buff_head skb_list;
unsigned max_ampdu_len;
u16 max_ampdu_frames;
u16 ampdu_len;
u16 dma_len;
};
extern void brcms_c_ampdu_reset_session(struct brcms_ampdu_session *session,
struct brcms_c_info *wlc);
extern int brcms_c_ampdu_add_frame(struct brcms_ampdu_session *session,
struct sk_buff *p);
extern void brcms_c_ampdu_finalize(struct brcms_ampdu_session *session);
extern struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc);
extern void brcms_c_ampdu_detach(struct ampdu_info *ampdu);
extern int brcms_c_sendampdu(struct ampdu_info *ampdu,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册