blob: 3c8262321795a054f01d6585213fe79f0558aa65 [file] [log] [blame]
Forest Bond92b96792009-06-13 07:38:31 -04001/*
2 * Copyright (c) 1996, 2003 VIA Networking Technologies, Inc.
3 * All rights reserved.
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * File: rxtx.h
20 *
21 * Purpose:
22 *
23 * Author: Jerry Chen
24 *
25 * Date: Jun. 27, 2002
26 *
27 */
28
Forest Bond92b96792009-06-13 07:38:31 -040029#ifndef __RXTX_H__
30#define __RXTX_H__
31
Forest Bond92b96792009-06-13 07:38:31 -040032#include "device.h"
Forest Bond92b96792009-06-13 07:38:31 -040033#include "wcmd.h"
Forest Bond92b96792009-06-13 07:38:31 -040034
Malcolm Priestley6398a592013-08-16 21:26:55 +010035/* RsvTime buffer header */
36struct vnt_rrv_time_rts {
37 u16 wRTSTxRrvTime_ba;
38 u16 wRTSTxRrvTime_aa;
39 u16 wRTSTxRrvTime_bb;
40 u16 wReserved;
41 u16 wTxRrvTime_b;
42 u16 wTxRrvTime_a;
43} __packed;
44
Malcolm Priestley4f990052013-08-16 23:38:57 +010045struct vnt_rrv_time_cts {
46 u16 wCTSTxRrvTime_ba;
47 u16 wReserved;
48 u16 wTxRrvTime_b;
49 u16 wTxRrvTime_a;
50} __packed;
51
Malcolm Priestley976467d2013-08-16 23:44:04 +010052struct vnt_rrv_time_ab {
53 u16 wRTSTxRrvTime;
54 u16 wTxRrvTime;
55} __packed;
56
Malcolm Priestley7e60a3de2013-08-16 23:48:03 +010057/* TX data header */
58struct vnt_tx_datahead_g {
59 u8 bySignalField_b;
60 u8 byServiceField_b;
61 u16 wTransmitLength_b;
62 u8 bySignalField_a;
63 u8 byServiceField_a;
64 u16 wTransmitLength_a;
65 u16 wDuration_b;
66 u16 wDuration_a;
67 u16 wTimeStampOff_b;
68 u16 wTimeStampOff_a;
69} __packed;
70
Malcolm Priestleyc521cb52013-08-15 21:23:25 +010071/* RTS buffer header */
72struct vnt_rts_g {
73 u8 bySignalField_b;
74 u8 byServiceField_b;
75 u16 wTransmitLength_b;
76 u8 bySignalField_a;
77 u8 byServiceField_a;
78 u16 wTransmitLength_a;
79 u16 wDuration_ba;
80 u16 wDuration_aa;
81 u16 wDuration_bb;
82 u16 wReserved;
83 struct ieee80211_rts data;
84} __packed;
85
86struct vnt_rts_g_fb {
87 u8 bySignalField_b;
88 u8 byServiceField_b;
89 u16 wTransmitLength_b;
90 u8 bySignalField_a;
91 u8 byServiceField_a;
92 u16 wTransmitLength_a;
93 u16 wDuration_ba;
94 u16 wDuration_aa;
95 u16 wDuration_bb;
96 u16 wReserved;
97 u16 wRTSDuration_ba_f0;
98 u16 wRTSDuration_aa_f0;
99 u16 wRTSDuration_ba_f1;
100 u16 wRTSDuration_aa_f1;
101 struct ieee80211_rts data;
102} __packed;
103
104struct vnt_rts_ab {
105 u8 bySignalField;
106 u8 byServiceField;
107 u16 wTransmitLength;
108 u16 wDuration;
109 u16 wReserved;
110 struct ieee80211_rts data;
111} __packed;
112
113struct vnt_rts_a_fb {
114 u8 bySignalField;
115 u8 byServiceField;
116 u16 wTransmitLength;
117 u16 wDuration;
118 u16 wReserved;
119 u16 wRTSDuration_f0;
120 u16 wRTSDuration_f1;
121 struct ieee80211_rts data;
122} __packed;
123
Malcolm Priestleyf0c5ba22013-08-15 21:27:22 +0100124/* CTS buffer header */
125struct vnt_cts {
126 u8 bySignalField_b;
127 u8 byServiceField_b;
128 u16 wTransmitLength_b;
129 u16 wDuration_ba;
130 u16 wReserved;
131 struct ieee80211_cts data;
132 u16 reserved2;
133} __packed;
134
135struct vnt_cts_fb {
136 u8 bySignalField_b;
137 u8 byServiceField_b;
138 u16 wTransmitLength_b;
139 u16 wDuration_ba;
140 u16 wReserved;
141 u16 wCTSDuration_ba_f0;
142 u16 wCTSDuration_ba_f1;
143 struct ieee80211_cts data;
144 u16 reserved2;
145} __packed;
146
Malcolm Priestleyf39c0d82013-08-15 19:34:37 +0100147struct vnt_tx_buffer {
148 u8 byType;
149 u8 byPKTNO;
150 u16 wTxByteCount;
Malcolm Priestleyed743952012-11-11 15:34:51 +0000151 u32 adwTxKey[4];
Malcolm Priestleyf39c0d82013-08-15 19:34:37 +0100152 u16 wFIFOCtl;
153 u16 wTimeStamp;
154 u16 wFragCtl;
155 u16 wReserved;
156} __packed;
Forest Bond92b96792009-06-13 07:38:31 -0400157
Malcolm Priestley01f865b2013-08-15 19:40:08 +0100158struct vnt_beacon_buffer {
159 u8 byType;
160 u8 byPKTNO;
161 u16 wTxByteCount;
162 u16 wFIFOCtl;
163 u16 wTimeStamp;
164} __packed;
Forest Bond92b96792009-06-13 07:38:31 -0400165
Malcolm Priestleyd56131d2013-01-17 23:15:22 +0000166void vDMA0_tx_80211(struct vnt_private *, struct sk_buff *skb);
167int nsDMA_tx_packet(struct vnt_private *, u32 uDMAIdx, struct sk_buff *skb);
168CMD_STATUS csMgmt_xmit(struct vnt_private *, struct vnt_tx_mgmt *);
169CMD_STATUS csBeacon_xmit(struct vnt_private *, struct vnt_tx_mgmt *);
170int bRelayPacketSend(struct vnt_private *, u8 *pbySkbData, u32 uDataLen,
171 u32 uNodeIndex);
Forest Bond92b96792009-06-13 07:38:31 -0400172
Andres Moree7b07d12010-05-01 19:12:26 -0300173#endif /* __RXTX_H__ */