]> git.karo-electronics.de Git - karo-tx-linux.git/blob - drivers/staging/rtl8192e/rtl819x_BA.h
Merge remote-tracking branch 'usb-chipidea-next/ci-for-usb-next'
[karo-tx-linux.git] / drivers / staging / rtl8192e / rtl819x_BA.h
1 /******************************************************************************
2  * Copyright(c) 2008 - 2010 Realtek Corporation. All rights reserved.
3  *
4  * This program is distributed in the hope that it will be useful, but WITHOUT
5  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
6  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
7  * more details.
8  *
9  * You should have received a copy of the GNU General Public License along with
10  * this program; if not, write to the Free Software Foundation, Inc.,
11  * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
12  *
13  * The full GNU General Public License is included in this distribution in the
14  * file called LICENSE.
15  *
16  * Contact Information:
17  * wlanfae <wlanfae@realtek.com>
18 ******************************************************************************/
19 #ifndef _BATYPE_H_
20 #define _BATYPE_H_
21
22 #define BA_SETUP_TIMEOUT        200
23
24 #define BA_POLICY_DELAYED               0
25 #define BA_POLICY_IMMEDIATE     1
26
27 #define ADDBA_STATUS_SUCCESS                    0
28 #define ADDBA_STATUS_REFUSED            37
29 #define ADDBA_STATUS_INVALID_PARAM      38
30
31 #define DELBA_REASON_END_BA                     37
32 #define DELBA_REASON_UNKNOWN_BA 38
33 #define DELBA_REASON_TIMEOUT                    39
34 union sequence_control {
35         u16 ShortData;
36         struct {
37                 u16     FragNum:4;
38                 u16     SeqNum:12;
39         } field;
40 };
41
42 union ba_param_set {
43         u8 charData[2];
44         u16 shortData;
45         struct {
46                 u16 AMSDU_Support:1;
47                 u16 BAPolicy:1;
48                 u16 TID:4;
49                 u16 BufferSize:10;
50         } field;
51 };
52
53 union delba_param_set {
54         u8 charData[2];
55         u16 shortData;
56         struct {
57                 u16 Reserved:11;
58                 u16 Initiator:1;
59                 u16 TID:4;
60         } field;
61 };
62
63 struct ba_record {
64         struct timer_list               Timer;
65         u8                              bValid;
66         u8                              DialogToken;
67         union ba_param_set BaParamSet;
68         u16                             BaTimeoutValue;
69         union sequence_control BaStartSeqCtrl;
70 };
71
72 #endif