staging: csr: remove CsrBool typedef
[linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git] / drivers / staging / csr / csr_wifi_nme_ap_prim.h
blob1ca0ec95917ce967a13cf510f5afede2bee76cd6
1 /*****************************************************************************
3 (c) Cambridge Silicon Radio Limited 2012
4 All rights reserved and confidential information of CSR
6 Refer to LICENSE.txt included with this source for details
7 on the license terms.
9 *****************************************************************************/
11 /* Note: this is an auto-generated file. */
13 #ifndef CSR_WIFI_NME_AP_PRIM_H__
14 #define CSR_WIFI_NME_AP_PRIM_H__
16 #include "csr_types.h"
17 #include "csr_prim_defs.h"
18 #include "csr_sched.h"
19 #include "csr_wifi_common.h"
20 #include "csr_result.h"
21 #include "csr_wifi_fsm_event.h"
22 #include "csr_wifi_sme_ap_prim.h"
23 #include "csr_wifi_nme_prim.h"
25 #ifdef __cplusplus
26 extern "C" {
27 #endif
29 #ifndef CSR_WIFI_NME_ENABLE
30 #error CSR_WIFI_NME_ENABLE MUST be defined inorder to use csr_wifi_nme_ap_prim.h
31 #endif
32 #ifndef CSR_WIFI_AP_ENABLE
33 #error CSR_WIFI_AP_ENABLE MUST be defined inorder to use csr_wifi_nme_ap_prim.h
34 #endif
36 #define CSR_WIFI_NME_AP_PRIM (0x0426)
38 typedef CsrPrim CsrWifiNmeApPrim;
41 /*******************************************************************************
43 NAME
44 CsrWifiNmeApPersCredentialType
46 DESCRIPTION
47 NME Credential Types
49 VALUES
50 CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PSK
51 - Use PSK as credential.
52 CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PASSPHRASE
53 - Use the specified passphrase as credential
55 *******************************************************************************/
56 typedef u8 CsrWifiNmeApPersCredentialType;
57 #define CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PSK ((CsrWifiNmeApPersCredentialType) 0x00)
58 #define CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PASSPHRASE ((CsrWifiNmeApPersCredentialType) 0x01)
61 /*******************************************************************************
63 NAME
64 CsrWifiNmeApConfig
66 DESCRIPTION
67 Structure holding AP config data.
69 MEMBERS
70 apGroupkeyTimeout - Access point group key timeout.
71 apStrictGtkRekey - Access point strict GTK rekey flag. If set TRUE, the AP
72 shall rekey GTK every time a connected STA leaves BSS.
73 apGmkTimeout - Access point GMK timeout
74 apResponseTimeout - Response timeout
75 apRetransLimit - Max allowed retransmissions
77 *******************************************************************************/
78 typedef struct
80 u16 apGroupkeyTimeout;
81 u8 apStrictGtkRekey;
82 u16 apGmkTimeout;
83 u16 apResponseTimeout;
84 u8 apRetransLimit;
85 } CsrWifiNmeApConfig;
87 /*******************************************************************************
89 NAME
90 CsrWifiNmeApAuthPers
92 DESCRIPTION
94 MEMBERS
95 authSupport - Credential type value (as defined in the
96 enumeration type).
97 rsnCapabilities - RSN capabilities mask
98 wapiCapabilities - WAPI capabilities mask
99 pskOrPassphrase - Credential type value (as defined in the
100 enumeration type).
101 authPers_credentials - Union containing credentials which depends
102 on credentialType parameter.
103 authPers_credentialspsk -
104 authPers_credentialspassphrase -
106 *******************************************************************************/
107 typedef struct
109 CsrWifiSmeApAuthSupportMask authSupport;
110 CsrWifiSmeApRsnCapabilitiesMask rsnCapabilities;
111 CsrWifiSmeApWapiCapabilitiesMask wapiCapabilities;
112 CsrWifiNmeApPersCredentialType pskOrPassphrase;
113 union {
114 CsrWifiNmePsk psk;
115 CsrWifiNmePassphrase passphrase;
116 } authPers_credentials;
117 } CsrWifiNmeApAuthPers;
119 /*******************************************************************************
121 NAME
122 CsrWifiNmeApCredentials
124 DESCRIPTION
125 Structure containing the Credentials data.
127 MEMBERS
128 authType - Authentication type
129 nmeAuthType - Authentication parameters
130 nmeAuthTypeopenSystemEmpty -
131 nmeAuthTypeauthwep -
132 nmeAuthTypeauthTypePersonal -
134 *******************************************************************************/
135 typedef struct
137 CsrWifiSmeApAuthType authType;
138 union {
139 CsrWifiSmeEmpty openSystemEmpty;
140 CsrWifiSmeWepAuth authwep;
141 CsrWifiNmeApAuthPers authTypePersonal;
142 } nmeAuthType;
143 } CsrWifiNmeApCredentials;
146 /* Downstream */
147 #define CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST (0x0000)
149 #define CSR_WIFI_NME_AP_CONFIG_SET_REQ ((CsrWifiNmeApPrim) (0x0000 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
150 #define CSR_WIFI_NME_AP_WPS_REGISTER_REQ ((CsrWifiNmeApPrim) (0x0001 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
151 #define CSR_WIFI_NME_AP_START_REQ ((CsrWifiNmeApPrim) (0x0002 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
152 #define CSR_WIFI_NME_AP_STOP_REQ ((CsrWifiNmeApPrim) (0x0003 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
153 #define CSR_WIFI_NME_AP_WMM_PARAM_UPDATE_REQ ((CsrWifiNmeApPrim) (0x0004 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
154 #define CSR_WIFI_NME_AP_STA_REMOVE_REQ ((CsrWifiNmeApPrim) (0x0005 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST))
157 #define CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_HIGHEST (0x0005 + CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST)
159 /* Upstream */
160 #define CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST (0x0000 + CSR_PRIM_UPSTREAM)
162 #define CSR_WIFI_NME_AP_CONFIG_SET_CFM ((CsrWifiNmeApPrim)(0x0000 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
163 #define CSR_WIFI_NME_AP_WPS_REGISTER_CFM ((CsrWifiNmeApPrim)(0x0001 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
164 #define CSR_WIFI_NME_AP_START_CFM ((CsrWifiNmeApPrim)(0x0002 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
165 #define CSR_WIFI_NME_AP_STOP_CFM ((CsrWifiNmeApPrim)(0x0003 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
166 #define CSR_WIFI_NME_AP_STOP_IND ((CsrWifiNmeApPrim)(0x0004 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
167 #define CSR_WIFI_NME_AP_WMM_PARAM_UPDATE_CFM ((CsrWifiNmeApPrim)(0x0005 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
168 #define CSR_WIFI_NME_AP_STATION_IND ((CsrWifiNmeApPrim)(0x0006 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST))
170 #define CSR_WIFI_NME_AP_PRIM_UPSTREAM_HIGHEST (0x0006 + CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST)
172 #define CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_COUNT (CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_HIGHEST + 1 - CSR_WIFI_NME_AP_PRIM_DOWNSTREAM_LOWEST)
173 #define CSR_WIFI_NME_AP_PRIM_UPSTREAM_COUNT (CSR_WIFI_NME_AP_PRIM_UPSTREAM_HIGHEST + 1 - CSR_WIFI_NME_AP_PRIM_UPSTREAM_LOWEST)
175 /*******************************************************************************
177 NAME
178 CsrWifiNmeApConfigSetReq
180 DESCRIPTION
181 This primitive passes AP configuration info for NME. This can be sent at
182 any time but will be acted upon when the AP is started again. This
183 information is common to both P2P GO and AP
185 MEMBERS
186 common - Common header for use with the CsrWifiFsm Module
187 apConfig - AP configuration for the NME.
188 apMacConfig - MAC configuration to be acted on when
189 CSR_WIFI_NME_AP_START.request is sent.
191 *******************************************************************************/
192 typedef struct
194 CsrWifiFsmEvent common;
195 CsrWifiNmeApConfig apConfig;
196 CsrWifiSmeApMacConfig apMacConfig;
197 } CsrWifiNmeApConfigSetReq;
199 /*******************************************************************************
201 NAME
202 CsrWifiNmeApWpsRegisterReq
204 DESCRIPTION
205 This primitive allows the NME to accept the WPS registration from an
206 enrollee. Such registration procedure can be cancelled by sending
207 CSR_WIFI_NME_WPS_CANCEL.request.
209 MEMBERS
210 common - Common header for use with the CsrWifiFsm Module
211 interfaceTag - Interface Identifier; unique identifier of an
212 interface
213 selectedDevicePasswordId - Selected password type
214 selectedConfigMethod - Selected WPS configuration method type
215 pin - PIN value.
216 Relevant if selected device password ID is PIN.4
217 digit pin is passed by sending the pin digits in
218 pin[0]..pin[3] and rest of the contents filled
219 with '-'.
221 *******************************************************************************/
222 typedef struct
224 CsrWifiFsmEvent common;
225 u16 interfaceTag;
226 CsrWifiSmeWpsDpid selectedDevicePasswordId;
227 CsrWifiSmeWpsConfigType selectedConfigMethod;
228 u8 pin[8];
229 } CsrWifiNmeApWpsRegisterReq;
231 /*******************************************************************************
233 NAME
234 CsrWifiNmeApStartReq
236 DESCRIPTION
237 This primitive requests NME to started the AP operation.
239 MEMBERS
240 common - Common header for use with the CsrWifiFsm Module
241 interfaceTag - Interface identifier; unique identifier of an interface
242 apType - AP Type specifies the Legacy AP or P2P GO operation
243 cloakSsid - Indicates whether the SSID should be cloaked (hidden and
244 not broadcast in beacon) or not
245 ssid - Service Set Identifier
246 ifIndex - Radio interface
247 channel - Channel number of the channel to use
248 apCredentials - Security credential configuration.
249 maxConnections - Maximum number of stations/P2P clients allowed
250 p2pGoParam - P2P specific GO parameters.
251 wpsEnabled - Indicates whether WPS should be enabled or not
253 *******************************************************************************/
254 typedef struct
256 CsrWifiFsmEvent common;
257 u16 interfaceTag;
258 CsrWifiSmeApType apType;
259 u8 cloakSsid;
260 CsrWifiSsid ssid;
261 CsrWifiSmeRadioIF ifIndex;
262 u8 channel;
263 CsrWifiNmeApCredentials apCredentials;
264 u8 maxConnections;
265 CsrWifiSmeApP2pGoConfig p2pGoParam;
266 u8 wpsEnabled;
267 } CsrWifiNmeApStartReq;
269 /*******************************************************************************
271 NAME
272 CsrWifiNmeApStopReq
274 DESCRIPTION
275 This primitive requests NME to stop the AP operation.
277 MEMBERS
278 common - Common header for use with the CsrWifiFsm Module
279 interfaceTag - Interface identifier; unique identifier of an interface
281 *******************************************************************************/
282 typedef struct
284 CsrWifiFsmEvent common;
285 u16 interfaceTag;
286 } CsrWifiNmeApStopReq;
288 /*******************************************************************************
290 NAME
291 CsrWifiNmeApWmmParamUpdateReq
293 DESCRIPTION
294 Application uses this primitive to update the WMM parameters
296 MEMBERS
297 common - Common header for use with the CsrWifiFsm Module
298 wmmApParams - WMM Access point parameters per access category. The array
299 index corresponds to the ACI
300 wmmApBcParams - WMM station parameters per access category to be advertised
301 in the beacons and probe response The array index
302 corresponds to the ACI
304 *******************************************************************************/
305 typedef struct
307 CsrWifiFsmEvent common;
308 CsrWifiSmeWmmAcParams wmmApParams[4];
309 CsrWifiSmeWmmAcParams wmmApBcParams[4];
310 } CsrWifiNmeApWmmParamUpdateReq;
312 /*******************************************************************************
314 NAME
315 CsrWifiNmeApStaRemoveReq
317 DESCRIPTION
318 This primitive disconnects a connected station. If keepBlocking is set to
319 TRUE, the station with the specified MAC address is not allowed to
320 connect. If the requested station is not already connected,it may be
321 blocked based on keepBlocking parameter.
323 MEMBERS
324 common - Common header for use with the CsrWifiFsm Module
325 interfaceTag - Interface Identifier; unique identifier of an interface
326 staMacAddress - Mac Address of the station to be disconnected or blocked
327 keepBlocking - If TRUE, the station is blocked. If FALSE and the station is
328 connected, disconnect the station. If FALSE and the station
329 is not connected, no action is taken.
331 *******************************************************************************/
332 typedef struct
334 CsrWifiFsmEvent common;
335 u16 interfaceTag;
336 CsrWifiMacAddress staMacAddress;
337 u8 keepBlocking;
338 } CsrWifiNmeApStaRemoveReq;
340 /*******************************************************************************
342 NAME
343 CsrWifiNmeApConfigSetCfm
345 DESCRIPTION
346 This primitive reports the result of the request.
348 MEMBERS
349 common - Common header for use with the CsrWifiFsm Module
350 status - Status of the request.
352 *******************************************************************************/
353 typedef struct
355 CsrWifiFsmEvent common;
356 CsrResult status;
357 } CsrWifiNmeApConfigSetCfm;
359 /*******************************************************************************
361 NAME
362 CsrWifiNmeApWpsRegisterCfm
364 DESCRIPTION
365 This primitive reports the result of WPS procedure.
367 MEMBERS
368 common - Common header for use with the CsrWifiFsm Module
369 interfaceTag - Interface identifier; unique identifier of an interface
370 status - Status of the request.
372 *******************************************************************************/
373 typedef struct
375 CsrWifiFsmEvent common;
376 u16 interfaceTag;
377 CsrResult status;
378 } CsrWifiNmeApWpsRegisterCfm;
380 /*******************************************************************************
382 NAME
383 CsrWifiNmeApStartCfm
385 DESCRIPTION
386 This primitive reports the result of CSR_WIFI_NME_AP_START.request.
388 MEMBERS
389 common - Common header for use with the CsrWifiFsm Module
390 interfaceTag - Interface identifier; unique identifier of an interface
391 status - Status of the request.
392 ssid - Service Set Identifier
394 *******************************************************************************/
395 typedef struct
397 CsrWifiFsmEvent common;
398 u16 interfaceTag;
399 CsrResult status;
400 CsrWifiSsid ssid;
401 } CsrWifiNmeApStartCfm;
403 /*******************************************************************************
405 NAME
406 CsrWifiNmeApStopCfm
408 DESCRIPTION
409 This primitive confirms that the AP operation is stopped. NME shall send
410 this primitive in response to the request even if AP operation has
411 already been stopped
413 MEMBERS
414 common - Common header for use with the CsrWifiFsm Module
415 interfaceTag - Interface identifier; unique identifier of an interface
416 status - Status of the request.
418 *******************************************************************************/
419 typedef struct
421 CsrWifiFsmEvent common;
422 u16 interfaceTag;
423 CsrResult status;
424 } CsrWifiNmeApStopCfm;
426 /*******************************************************************************
428 NAME
429 CsrWifiNmeApStopInd
431 DESCRIPTION
432 Indicates that AP operation had stopped because of some unrecoverable
433 error after AP operation was started successfully. NME sends this signal
434 after failing to restart the AP operation internally following an error
436 MEMBERS
437 common - Common header for use with the CsrWifiFsm Module
438 interfaceTag - Interface Identifier; unique identifier of an interface
439 apType - Reports AP Type (P2PGO or AP)
440 status - Error Status
442 *******************************************************************************/
443 typedef struct
445 CsrWifiFsmEvent common;
446 u16 interfaceTag;
447 CsrWifiSmeApType apType;
448 CsrResult status;
449 } CsrWifiNmeApStopInd;
451 /*******************************************************************************
453 NAME
454 CsrWifiNmeApWmmParamUpdateCfm
456 DESCRIPTION
457 A confirm for for the WMM parameters update
459 MEMBERS
460 common - Common header for use with the CsrWifiFsm Module
461 status - Status of the request.
463 *******************************************************************************/
464 typedef struct
466 CsrWifiFsmEvent common;
467 CsrResult status;
468 } CsrWifiNmeApWmmParamUpdateCfm;
470 /*******************************************************************************
472 NAME
473 CsrWifiNmeApStationInd
475 DESCRIPTION
476 This primitive indicates that a station has joined or a previously joined
477 station has left the BSS/group
479 MEMBERS
480 common - Common header for use with the CsrWifiFsm Module
481 interfaceTag - Interface Identifier; unique identifier of an interface
482 mediaStatus - Indicates whether the station is connected or
483 disconnected
484 peerMacAddress - MAC address of the station
485 peerDeviceAddress - P2P Device Address
487 *******************************************************************************/
488 typedef struct
490 CsrWifiFsmEvent common;
491 u16 interfaceTag;
492 CsrWifiSmeMediaStatus mediaStatus;
493 CsrWifiMacAddress peerMacAddress;
494 CsrWifiMacAddress peerDeviceAddress;
495 } CsrWifiNmeApStationInd;
498 #ifdef __cplusplus
500 #endif
502 #endif /* CSR_WIFI_NME_AP_PRIM_H__ */