This source file includes following definitions.
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
- GEN_CMD_CODE
1
2
3
4
5
6
7
8
9
10
11
12
13
14 #ifndef __RTL8712_CMD_H_
15 #define __RTL8712_CMD_H_
16
17 #define CMD_HDR_SZ 8
18
19 u8 r8712_fw_cmd(struct _adapter *pAdapter, u32 cmd);
20 void r8712_fw_cmd_data(struct _adapter *pAdapter, u32 *value, u8 flag);
21
22 struct cmd_hdr {
23 u32 cmd_dw0;
24 u32 cmd_dw1;
25 };
26
27 enum rtl8712_h2c_cmd {
28 GEN_CMD_CODE(_Read_MACREG),
29 GEN_CMD_CODE(_Write_MACREG),
30 GEN_CMD_CODE(_Read_BBREG),
31 GEN_CMD_CODE(_Write_BBREG),
32 GEN_CMD_CODE(_Read_RFREG),
33 GEN_CMD_CODE(_Write_RFREG),
34 GEN_CMD_CODE(_Read_EEPROM),
35 GEN_CMD_CODE(_Write_EEPROM),
36 GEN_CMD_CODE(_Read_EFUSE),
37 GEN_CMD_CODE(_Write_EFUSE),
38
39 GEN_CMD_CODE(_Read_CAM),
40 GEN_CMD_CODE(_Write_CAM),
41 GEN_CMD_CODE(_setBCNITV),
42 GEN_CMD_CODE(_setMBIDCFG),
43 GEN_CMD_CODE(_JoinBss),
44 GEN_CMD_CODE(_DisConnect),
45 GEN_CMD_CODE(_CreateBss),
46 GEN_CMD_CODE(_SetOpMode),
47 GEN_CMD_CODE(_SiteSurvey),
48 GEN_CMD_CODE(_SetAuth),
49
50 GEN_CMD_CODE(_SetKey),
51 GEN_CMD_CODE(_SetStaKey),
52 GEN_CMD_CODE(_SetAssocSta),
53 GEN_CMD_CODE(_DelAssocSta),
54 GEN_CMD_CODE(_SetStaPwrState),
55 GEN_CMD_CODE(_SetBasicRate),
56 GEN_CMD_CODE(_GetBasicRate),
57 GEN_CMD_CODE(_SetDataRate),
58 GEN_CMD_CODE(_GetDataRate),
59 GEN_CMD_CODE(_SetPhyInfo),
60
61 GEN_CMD_CODE(_GetPhyInfo),
62 GEN_CMD_CODE(_SetPhy),
63 GEN_CMD_CODE(_GetPhy),
64 GEN_CMD_CODE(_readRssi),
65 GEN_CMD_CODE(_readGain),
66 GEN_CMD_CODE(_SetAtim),
67 GEN_CMD_CODE(_SetPwrMode),
68 GEN_CMD_CODE(_JoinbssRpt),
69 GEN_CMD_CODE(_SetRaTable),
70 GEN_CMD_CODE(_GetRaTable),
71
72 GEN_CMD_CODE(_GetCCXReport),
73 GEN_CMD_CODE(_GetDTMReport),
74 GEN_CMD_CODE(_GetTXRateStatistics),
75 GEN_CMD_CODE(_SetUsbSuspend),
76 GEN_CMD_CODE(_SetH2cLbk),
77 GEN_CMD_CODE(_AddBAReq),
78
79 GEN_CMD_CODE(_SetChannel),
80
81 GEN_CMD_CODE(_SetTxPower),
82 GEN_CMD_CODE(_SwitchAntenna),
83 GEN_CMD_CODE(_SetCrystalCap),
84 GEN_CMD_CODE(_SetSingleCarrierTx),
85 GEN_CMD_CODE(_SetSingleToneTx),
86 GEN_CMD_CODE(_SetCarrierSuppressionTx),
87 GEN_CMD_CODE(_SetContinuousTx),
88 GEN_CMD_CODE(_SwitchBandwidth),
89
90 GEN_CMD_CODE(_TX_Beacon),
91 GEN_CMD_CODE(_SetPowerTracking),
92 GEN_CMD_CODE(_AMSDU_TO_AMPDU),
93 GEN_CMD_CODE(_SetMacAddress),
94
95 GEN_CMD_CODE(_DisconnectCtrl),
96 GEN_CMD_CODE(_SetChannelPlan),
97 GEN_CMD_CODE(_DisconnectCtrlEx),
98
99
100 GEN_CMD_CODE(_GetH2cLbk),
101
102
103 GEN_CMD_CODE(_SetProbeReqExtraIE),
104 GEN_CMD_CODE(_SetAssocReqExtraIE),
105 GEN_CMD_CODE(_SetProbeRspExtraIE),
106 GEN_CMD_CODE(_SetAssocRspExtraIE),
107
108
109 GEN_CMD_CODE(_GetCurDataRate),
110
111 GEN_CMD_CODE(_GetTxRetrycnt),
112
113
114 GEN_CMD_CODE(_GetRxRetrycnt),
115
116
117
118
119 GEN_CMD_CODE(_GetBCNOKcnt),
120 GEN_CMD_CODE(_GetBCNERRcnt),
121 GEN_CMD_CODE(_GetCurTxPwrLevel),
122
123 GEN_CMD_CODE(_SetDIG),
124 GEN_CMD_CODE(_SetRA),
125 GEN_CMD_CODE(_SetPT),
126 GEN_CMD_CODE(_ReadTSSI),
127
128 MAX_H2CCMD
129 };
130
131 #define _GetBBReg_CMD_ _Read_BBREG_CMD_
132 #define _SetBBReg_CMD_ _Write_BBREG_CMD_
133 #define _GetRFReg_CMD_ _Read_RFREG_CMD_
134 #define _SetRFReg_CMD_ _Write_RFREG_CMD_
135 #define _DRV_INT_CMD_ (MAX_H2CCMD + 1)
136 #define _SetRFIntFs_CMD_ (MAX_H2CCMD + 2)
137
138 #ifdef _RTL8712_CMD_C_
139 static struct _cmd_callback cmd_callback[] = {
140 {GEN_CMD_CODE(_Read_MACREG), NULL},
141 {GEN_CMD_CODE(_Write_MACREG), NULL},
142 {GEN_CMD_CODE(_Read_BBREG), NULL},
143 {GEN_CMD_CODE(_Write_BBREG), NULL},
144 {GEN_CMD_CODE(_Read_RFREG), &r8712_getbbrfreg_cmdrsp_callback},
145 {GEN_CMD_CODE(_Write_RFREG), NULL},
146 {GEN_CMD_CODE(_Read_EEPROM), NULL},
147 {GEN_CMD_CODE(_Write_EEPROM), NULL},
148 {GEN_CMD_CODE(_Read_EFUSE), NULL},
149 {GEN_CMD_CODE(_Write_EFUSE), NULL},
150
151 {GEN_CMD_CODE(_Read_CAM), NULL},
152 {GEN_CMD_CODE(_Write_CAM), NULL},
153 {GEN_CMD_CODE(_setBCNITV), NULL},
154 {GEN_CMD_CODE(_setMBIDCFG), NULL},
155 {GEN_CMD_CODE(_JoinBss), &r8712_joinbss_cmd_callback},
156 {GEN_CMD_CODE(_DisConnect), &r8712_disassoc_cmd_callback},
157 {GEN_CMD_CODE(_CreateBss), &r8712_createbss_cmd_callback},
158 {GEN_CMD_CODE(_SetOpMode), NULL},
159 {GEN_CMD_CODE(_SiteSurvey), &r8712_survey_cmd_callback},
160 {GEN_CMD_CODE(_SetAuth), NULL},
161
162 {GEN_CMD_CODE(_SetKey), NULL},
163 {GEN_CMD_CODE(_SetStaKey), &r8712_setstaKey_cmdrsp_callback},
164 {GEN_CMD_CODE(_SetAssocSta), &r8712_setassocsta_cmdrsp_callback},
165 {GEN_CMD_CODE(_DelAssocSta), NULL},
166 {GEN_CMD_CODE(_SetStaPwrState), NULL},
167 {GEN_CMD_CODE(_SetBasicRate), NULL},
168 {GEN_CMD_CODE(_GetBasicRate), NULL},
169 {GEN_CMD_CODE(_SetDataRate), NULL},
170 {GEN_CMD_CODE(_GetDataRate), NULL},
171 {GEN_CMD_CODE(_SetPhyInfo), NULL},
172
173 {GEN_CMD_CODE(_GetPhyInfo), NULL},
174 {GEN_CMD_CODE(_SetPhy), NULL},
175 {GEN_CMD_CODE(_GetPhy), NULL},
176 {GEN_CMD_CODE(_readRssi), NULL},
177 {GEN_CMD_CODE(_readGain), NULL},
178 {GEN_CMD_CODE(_SetAtim), NULL},
179 {GEN_CMD_CODE(_SetPwrMode), NULL},
180 {GEN_CMD_CODE(_JoinbssRpt), NULL},
181 {GEN_CMD_CODE(_SetRaTable), NULL},
182 {GEN_CMD_CODE(_GetRaTable), NULL},
183
184 {GEN_CMD_CODE(_GetCCXReport), NULL},
185 {GEN_CMD_CODE(_GetDTMReport), NULL},
186 {GEN_CMD_CODE(_GetTXRateStatistics), NULL},
187 {GEN_CMD_CODE(_SetUsbSuspend), NULL},
188 {GEN_CMD_CODE(_SetH2cLbk), NULL},
189 {GEN_CMD_CODE(_AddBAReq), NULL},
190
191 {GEN_CMD_CODE(_SetChannel), NULL},
192
193 {GEN_CMD_CODE(_SetTxPower), NULL},
194 {GEN_CMD_CODE(_SwitchAntenna), NULL},
195 {GEN_CMD_CODE(_SetCrystalCap), NULL},
196 {GEN_CMD_CODE(_SetSingleCarrierTx), NULL},
197 {GEN_CMD_CODE(_SetSingleToneTx), NULL},
198 {GEN_CMD_CODE(_SetCarrierSuppressionTx), NULL},
199 {GEN_CMD_CODE(_SetContinuousTx), NULL},
200 {GEN_CMD_CODE(_SwitchBandwidth), NULL},
201
202 {GEN_CMD_CODE(_TX_Beacon), NULL},
203 {GEN_CMD_CODE(_SetPowerTracking), NULL},
204 {GEN_CMD_CODE(_AMSDU_TO_AMPDU), NULL},
205 {GEN_CMD_CODE(_SetMacAddress), NULL},
206
207 {GEN_CMD_CODE(_DisconnectCtrl), NULL},
208 {GEN_CMD_CODE(_SetChannelPlan), NULL},
209 {GEN_CMD_CODE(_DisconnectCtrlEx), NULL},
210
211
212 {GEN_CMD_CODE(_GetH2cLbk), NULL},
213
214 {_SetProbeReqExtraIE_CMD_, NULL},
215 {_SetAssocReqExtraIE_CMD_, NULL},
216 {_SetProbeRspExtraIE_CMD_, NULL},
217 {_SetAssocRspExtraIE_CMD_, NULL},
218 {_GetCurDataRate_CMD_, NULL},
219 {_GetTxRetrycnt_CMD_, NULL},
220 {_GetRxRetrycnt_CMD_, NULL},
221 {_GetBCNOKcnt_CMD_, NULL},
222 {_GetBCNERRcnt_CMD_, NULL},
223 {_GetCurTxPwrLevel_CMD_, NULL},
224 {_SetDIG_CMD_, NULL},
225 {_SetRA_CMD_, NULL},
226 {_SetPT_CMD_, NULL},
227 {GEN_CMD_CODE(_ReadTSSI), &r8712_readtssi_cmdrsp_callback}
228 };
229 #endif
230
231 #endif