Arend van Spriel | 5b435de | 2011-10-05 13:19:03 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2010 Broadcom Corporation |
| 3 | * |
| 4 | * Permission to use, copy, modify, and/or distribute this software for any |
| 5 | * purpose with or without fee is hereby granted, provided that the above |
| 6 | * copyright notice and this permission notice appear in all copies. |
| 7 | * |
| 8 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES |
| 9 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF |
| 10 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY |
| 11 | * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
| 12 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION |
| 13 | * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN |
| 14 | * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
| 15 | */ |
| 16 | |
| 17 | #ifndef _BRCM_AMPDU_H_ |
| 18 | #define _BRCM_AMPDU_H_ |
| 19 | |
Seth Forshee | ef2c051 | 2012-11-15 08:07:51 -0600 | [diff] [blame] | 20 | /* |
| 21 | * Data structure representing an in-progress session for accumulating |
| 22 | * frames for AMPDU. |
| 23 | * |
| 24 | * wlc: pointer to common driver data |
| 25 | * skb_list: queue of skb's for AMPDU |
| 26 | * max_ampdu_len: maximum length for this AMPDU |
| 27 | * max_ampdu_frames: maximum number of frames for this AMPDU |
| 28 | * ampdu_len: total number of bytes accumulated for this AMPDU |
| 29 | * dma_len: DMA length of this AMPDU |
| 30 | */ |
| 31 | struct brcms_ampdu_session { |
| 32 | struct brcms_c_info *wlc; |
| 33 | struct sk_buff_head skb_list; |
| 34 | unsigned max_ampdu_len; |
| 35 | u16 max_ampdu_frames; |
| 36 | u16 ampdu_len; |
| 37 | u16 dma_len; |
| 38 | }; |
| 39 | |
Joe Perches | 9bd91f3 | 2013-09-23 11:37:59 -0700 | [diff] [blame] | 40 | void brcms_c_ampdu_reset_session(struct brcms_ampdu_session *session, |
| 41 | struct brcms_c_info *wlc); |
| 42 | int brcms_c_ampdu_add_frame(struct brcms_ampdu_session *session, |
| 43 | struct sk_buff *p); |
| 44 | void brcms_c_ampdu_finalize(struct brcms_ampdu_session *session); |
Seth Forshee | ef2c051 | 2012-11-15 08:07:51 -0600 | [diff] [blame] | 45 | |
Joe Perches | 9bd91f3 | 2013-09-23 11:37:59 -0700 | [diff] [blame] | 46 | struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc); |
| 47 | void brcms_c_ampdu_detach(struct ampdu_info *ampdu); |
| 48 | void brcms_c_ampdu_dotxstatus(struct ampdu_info *ampdu, struct scb *scb, |
| 49 | struct sk_buff *p, struct tx_status *txs); |
| 50 | void brcms_c_ampdu_macaddr_upd(struct brcms_c_info *wlc); |
| 51 | void brcms_c_ampdu_shm_upd(struct ampdu_info *ampdu); |
Arend van Spriel | 5b435de | 2011-10-05 13:19:03 +0200 | [diff] [blame] | 52 | |
| 53 | #endif /* _BRCM_AMPDU_H_ */ |