2 * Copyright (C) 2003 Herbert Valerio Riedel <hvr@gnu.org>
3 * Copyright (C) 2004 Luis R. Rodriguez <mcgrof@ruslug.rutgers.edu>
4 * Copyright (C) 2004 Aurelien Alleaume <slts@free.fr>
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License
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.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, see <http://www.gnu.org/licenses/>.
20 #if !defined(_ISL_OID_H)
24 * MIB related constant and structure definitions for communicating
25 * with the device firmware
34 u8 type
; /* dot11_priv_t */
57 u32 addr
; /* 32bit bus address */
83 struct obj_bss bsslist
[0];
86 struct obj_frequencies
{
91 struct obj_attachment
{
100 * in case everything's ok, the inlined function below will be
101 * optimized away by the compiler...
104 __bug_on_wrong_struct_sizes(void)
106 BUILD_BUG_ON(sizeof (struct obj_ssid
) != 34);
107 BUILD_BUG_ON(sizeof (struct obj_key
) != 34);
108 BUILD_BUG_ON(sizeof (struct obj_mlme
) != 12);
109 BUILD_BUG_ON(sizeof (struct obj_mlmeex
) != 14);
110 BUILD_BUG_ON(sizeof (struct obj_buffer
) != 8);
111 BUILD_BUG_ON(sizeof (struct obj_bss
) != 60);
112 BUILD_BUG_ON(sizeof (struct obj_bsslist
) != 4);
113 BUILD_BUG_ON(sizeof (struct obj_frequencies
) != 2);
117 DOT11_STATE_NONE
= 0,
118 DOT11_STATE_AUTHING
= 1,
119 DOT11_STATE_AUTH
= 2,
120 DOT11_STATE_ASSOCING
= 3,
122 DOT11_STATE_ASSOC
= 5,
123 DOT11_STATE_IBSS
= 6,
127 enum dot11_bsstype_t
{
128 DOT11_BSSTYPE_NONE
= 0,
129 DOT11_BSSTYPE_INFRA
= 1,
130 DOT11_BSSTYPE_IBSS
= 2,
131 DOT11_BSSTYPE_ANY
= 3
143 DOT11_MLME_INTERMEDIATE
= 1,
144 DOT11_MLME_EXTENDED
= 2
152 /* Prism "Nitro" / Frameburst / "Packet Frame Grouping"
153 * Value is in microseconds. Represents the # microseconds
154 * the firmware will take to group frames before sending out then out
155 * together with a CSMA contention. Without this all frames are
156 * sent with a CSMA contention.
158 * http://www.hpl.hp.com/personal/Jean_Tourrilhes/Papers/Packet.Frame.Grouping.html
160 enum dot11_maxframeburst_t
{
161 /* Values for DOT11_OID_MAXFRAMEBURST */
162 DOT11_MAXFRAMEBURST_OFF
= 0, /* Card firmware default */
163 DOT11_MAXFRAMEBURST_MIXED_SAFE
= 650, /* 802.11 a,b,g safe */
164 DOT11_MAXFRAMEBURST_IDEAL
= 1300, /* Theoretical ideal level */
165 DOT11_MAXFRAMEBURST_MAX
= 5000, /* Use this as max,
166 * Note: firmware allows for greater values. This is a
167 * recommended max. I'll update this as I find
168 * out what the real MAX is. Also note that you don't necessarily
169 * get better results with a greater value here.
173 /* Support for 802.11 long and short frame preambles.
174 * Long preamble uses 128-bit sync field, 8-bit CRC
175 * Short preamble uses 56-bit sync field, 16-bit CRC
177 * 802.11a -- not sure, both optionally ?
178 * 802.11b supports long and optionally short
179 * 802.11g supports both */
180 enum dot11_preamblesettings_t
{
181 DOT11_PREAMBLESETTING_LONG
= 0,
182 /* Allows *only* long 802.11 preambles */
183 DOT11_PREAMBLESETTING_SHORT
= 1,
184 /* Allows *only* short 802.11 preambles */
185 DOT11_PREAMBLESETTING_DYNAMIC
= 2
186 /* AutomatiGically set */
189 /* Support for 802.11 slot timing (time between packets).
191 * Long uses 802.11a slot timing (9 usec ?)
192 * Short uses 802.11b slot timing (20 use ?) */
193 enum dot11_slotsettings_t
{
194 DOT11_SLOTSETTINGS_LONG
= 0,
195 /* Allows *only* long 802.11b slot timing */
196 DOT11_SLOTSETTINGS_SHORT
= 1,
197 /* Allows *only* long 802.11a slot timing */
198 DOT11_SLOTSETTINGS_DYNAMIC
= 2
199 /* AutomatiGically set */
202 /* All you need to know, ERP is "Extended Rate PHY".
203 * An Extended Rate PHY (ERP) STA or AP shall support three different
204 * preamble and header formats:
205 * Long preamble (refer to above)
206 * Short preamble (refer to above)
207 * OFDM preamble ( ? )
209 * I'm assuming here Protection tells the AP
210 * to be careful, a STA which cannot handle the long pre-amble
213 enum do11_nonerpstatus_t
{
214 DOT11_ERPSTAT_NONEPRESENT
= 0,
215 DOT11_ERPSTAT_USEPROTECTION
= 1
218 /* (ERP is "Extended Rate PHY") Way to read NONERP is NON-ERP-*
219 * The key here is DOT11 NON ERP NEVER protects against
220 * NON ERP STA's. You *don't* want this unless
221 * you know what you are doing. It means you will only
222 * get Extended Rate capabilities */
223 enum dot11_nonerpprotection_t
{
224 DOT11_NONERP_NEVER
= 0,
225 DOT11_NONERP_ALWAYS
= 1,
226 DOT11_NONERP_DYNAMIC
= 2
229 /* Preset OID configuration for 802.11 modes
230 * Note: DOT11_OID_CW[MIN|MAX] hold the values of the
231 * DCS MIN|MAX backoff used */
232 enum dot11_profile_t
{ /* And set/allowed values */
233 /* Allowed values for DOT11_OID_PROFILES */
234 DOT11_PROFILE_B_ONLY
= 0,
235 /* DOT11_OID_RATES: 1, 2, 5.5, 11Mbps
236 * DOT11_OID_PREAMBLESETTINGS: DOT11_PREAMBLESETTING_DYNAMIC
237 * DOT11_OID_CWMIN: 31
238 * DOT11_OID_NONEPROTECTION: DOT11_NOERP_DYNAMIC
239 * DOT11_OID_SLOTSETTINGS: DOT11_SLOTSETTINGS_LONG
241 DOT11_PROFILE_MIXED_G_WIFI
= 1,
242 /* DOT11_OID_RATES: 1, 2, 5.5, 11, 6, 9, 12, 18, 24, 36, 48, 54Mbs
243 * DOT11_OID_PREAMBLESETTINGS: DOT11_PREAMBLESETTING_DYNAMIC
244 * DOT11_OID_CWMIN: 15
245 * DOT11_OID_NONEPROTECTION: DOT11_NOERP_DYNAMIC
246 * DOT11_OID_SLOTSETTINGS: DOT11_SLOTSETTINGS_DYNAMIC
248 DOT11_PROFILE_MIXED_LONG
= 2, /* "Long range" */
249 /* Same as Profile MIXED_G_WIFI */
250 DOT11_PROFILE_G_ONLY
= 3,
251 /* Same as Profile MIXED_G_WIFI */
252 DOT11_PROFILE_TEST
= 4,
253 /* Same as Profile MIXED_G_WIFI except:
254 * DOT11_OID_PREAMBLESETTINGS: DOT11_PREAMBLESETTING_SHORT
255 * DOT11_OID_NONEPROTECTION: DOT11_NOERP_NEVER
256 * DOT11_OID_SLOTSETTINGS: DOT11_SLOTSETTINGS_SHORT
258 DOT11_PROFILE_B_WIFI
= 5,
259 /* Same as Profile B_ONLY */
260 DOT11_PROFILE_A_ONLY
= 6,
261 /* Same as Profile MIXED_G_WIFI except:
262 * DOT11_OID_RATES: 6, 9, 12, 18, 24, 36, 48, 54Mbs
264 DOT11_PROFILE_MIXED_SHORT
= 7
265 /* Same as MIXED_G_WIFI */
269 /* The dot11d conformance level configures the 802.11d conformance levels.
270 * The following conformance levels exist:*/
271 enum oid_inl_conformance_t
{
272 OID_INL_CONFORMANCE_NONE
= 0, /* Perform active scanning */
273 OID_INL_CONFORMANCE_STRICT
= 1, /* Strictly adhere to 802.11d */
274 OID_INL_CONFORMANCE_FLEXIBLE
= 2, /* Use passed 802.11d info to
275 * determine channel AND/OR just make assumption that active
276 * channels are valid channels */
279 enum oid_inl_mode_t
{
281 INL_MODE_PROMISCUOUS
= 0,
287 enum oid_inl_config_t
{
288 INL_CONFIG_NOTHING
= 0x00,
289 INL_CONFIG_MANUALRUN
= 0x01,
290 INL_CONFIG_FRAMETRAP
= 0x02,
291 INL_CONFIG_RXANNEX
= 0x04,
292 INL_CONFIG_TXANNEX
= 0x08,
293 INL_CONFIG_WDS
= 0x10
296 enum oid_inl_phycap_t
{
297 INL_PHYCAP_2400MHZ
= 1,
298 INL_PHYCAP_5000MHZ
= 2,
299 INL_PHYCAP_FAA
= 0x80000000, /* Means card supports the FAA switch */
304 GEN_OID_MACADDRESS
= 0,
317 DOT11_OID_COUNTRYSTRING
,
318 DOT11_OID_SSIDOVERRIDE
,
320 DOT11_OID_MEDIUMLIMIT
,
321 DOT11_OID_BEACONPERIOD
,
322 DOT11_OID_DTIMPERIOD
,
323 DOT11_OID_ATIMWINDOW
,
324 DOT11_OID_LISTENINTERVAL
,
326 DOT11_OID_CFPDURATION
,
328 DOT11_OID_AUTHENABLE
,
329 DOT11_OID_PRIVACYINVOKED
,
330 DOT11_OID_EXUNENCRYPTED
,
332 DOT11_OID_DEFKEYX
, /* DOT11_OID_DEFKEY1,...DOT11_OID_DEFKEY4 */
334 DOT11_OID_REKEYTHRESHOLD
,
337 DOT11_OID_PRIVTXREJECTED
,
338 DOT11_OID_PRIVRXPLAIN
,
339 DOT11_OID_PRIVRXFAILED
,
340 DOT11_OID_PRIVRXNOKEY
,
343 DOT11_OID_FRAGTHRESH
,
344 DOT11_OID_SHORTRETRIES
,
345 DOT11_OID_LONGRETRIES
,
346 DOT11_OID_MAXTXLIFETIME
,
347 DOT11_OID_MAXRXLIFETIME
,
348 DOT11_OID_AUTHRESPTIMEOUT
,
349 DOT11_OID_ASSOCRESPTIMEOUT
,
351 DOT11_OID_ALOFT_TABLE
,
352 DOT11_OID_ALOFT_CTRL_TABLE
,
353 DOT11_OID_ALOFT_RETREAT
,
354 DOT11_OID_ALOFT_PROGRESS
,
355 DOT11_OID_ALOFT_FIXEDRATE
,
356 DOT11_OID_ALOFT_RSSIGRAPH
,
357 DOT11_OID_ALOFT_CONFIG
,
360 DOT11_OID_MAXFRAMEBURST
,
363 DOT11_OID_CAMTIMEOUT
,
364 DOT11_OID_RECEIVEDTIMS
,
365 DOT11_OID_ROAMPREFERENCE
,
367 DOT11_OID_BRIDGELOCAL
,
369 DOT11_OID_CLIENTSASSOCIATED
,
370 DOT11_OID_CLIENTX
, /* DOT11_OID_CLIENTX,...DOT11_OID_CLIENT2007 */
372 DOT11_OID_CLIENTFIND
,
373 DOT11_OID_WDSLINKADD
,
374 DOT11_OID_WDSLINKREMOVE
,
375 DOT11_OID_EAPAUTHSTA
,
376 DOT11_OID_EAPUNAUTHSTA
,
377 DOT11_OID_DOT1XENABLE
,
378 DOT11_OID_MICFAILURE
,
379 DOT11_OID_REKEYINDICATE
,
381 DOT11_OID_MPDUTXSUCCESSFUL
,
382 DOT11_OID_MPDUTXONERETRY
,
383 DOT11_OID_MPDUTXMULTIPLERETRIES
,
384 DOT11_OID_MPDUTXFAILED
,
385 DOT11_OID_MPDURXSUCCESSFUL
,
386 DOT11_OID_MPDURXDUPS
,
387 DOT11_OID_RTSSUCCESSFUL
,
390 DOT11_OID_FRAMERECEIVES
,
391 DOT11_OID_FRAMEERRORS
,
392 DOT11_OID_FRAMEABORTS
,
393 DOT11_OID_FRAMEABORTSPHY
,
396 DOT11_OID_CWMIN
, /* MIN DCS backoff */
397 DOT11_OID_CWMAX
, /* MAX DCS backoff */
401 DOT11_OID_ANTENNADIVERSITY
,
403 DOT11_OID_EDTHRESHOLD
,
404 DOT11_OID_PREAMBLESETTINGS
,
406 DOT11_OID_CCAMODESUPPORTED
,
408 DOT11_OID_RSSIVECTOR
,
409 DOT11_OID_OUTPUTPOWERTABLE
,
410 DOT11_OID_OUTPUTPOWER
,
411 DOT11_OID_SUPPORTEDRATES
,
413 DOT11_OID_SUPPORTEDFREQUENCIES
,
414 DOT11_OID_NOISEFLOOR
,
415 DOT11_OID_FREQUENCYACTIVITY
,
416 DOT11_OID_IQCALIBRATIONTABLE
,
417 DOT11_OID_NONERPPROTECTION
,
418 DOT11_OID_SLOTSETTINGS
,
419 DOT11_OID_NONERPTIMEOUT
,
421 DOT11_OID_EXTENDEDRATES
,
423 DOT11_OID_DEAUTHENTICATE
,
424 DOT11_OID_AUTHENTICATE
,
425 DOT11_OID_DISASSOCIATE
,
430 DOT11_OID_DEAUTHENTICATEEX
,
431 DOT11_OID_AUTHENTICATEEX
,
432 DOT11_OID_DISASSOCIATEEX
,
433 DOT11_OID_ASSOCIATEEX
,
434 DOT11_OID_REASSOCIATE
,
435 DOT11_OID_REASSOCIATEEX
,
437 DOT11_OID_NONERPSTATUS
,
439 DOT11_OID_STATIMEOUT
,
440 DOT11_OID_MLMEAUTOLEVEL
,
441 DOT11_OID_BSSTIMEOUT
,
442 DOT11_OID_ATTACHMENT
,
446 DOT11_OID_BSSX
, /*DOT11_OID_BSS1,...,DOT11_OID_BSS64 */
454 OID_INL_COMPONENT_NR
,
456 OID_INL_INTERFACE_ID
,
457 OID_INL_COMPONENT_ID
,
459 OID_INL_DOT11D_CONFORMANCE
,
460 OID_INL_PHYCAPABILITIES
,
466 #define OID_FLAG_CACHED 0x80
467 #define OID_FLAG_TYPE 0x7f
469 #define OID_TYPE_U32 0x01
470 #define OID_TYPE_SSID 0x02
471 #define OID_TYPE_KEY 0x03
472 #define OID_TYPE_BUFFER 0x04
473 #define OID_TYPE_BSS 0x05
474 #define OID_TYPE_BSSLIST 0x06
475 #define OID_TYPE_FREQUENCIES 0x07
476 #define OID_TYPE_MLME 0x08
477 #define OID_TYPE_MLMEEX 0x09
478 #define OID_TYPE_ADDR 0x0A
479 #define OID_TYPE_RAW 0x0B
480 #define OID_TYPE_ATTACH 0x0C
482 /* OID_TYPE_MLMEEX is special because of a variable size field when sending.
483 * Not yet implemented (not used in driver anyway).
488 short range
; /* to define a range of oid */
489 short size
; /* max size of the associated data */
498 #define IWMAX_BITRATES 20
500 #define IWMAX_FREQ 30
501 #define PRIV_STR_SIZE 1024
503 #endif /* !defined(_ISL_OID_H) */