aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas/hostcmd.h
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@infradead.org>2007-05-25 23:36:54 -0400
committerJohn W. Linville <linville@tuxdriver.com>2007-06-11 14:28:45 -0400
commit981f187b7c4b237011d4175cae0120d5d203c0fd (patch)
treeb4508fc33a9aed0177c18c3a4db5c4e500fdb646 /drivers/net/wireless/libertas/hostcmd.h
parent123e0e044091ca35a4766b38ae15032f2d41bcd6 (diff)
[PATCH] libertas: first pass at fixing up endianness issues
Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/hostcmd.h')
-rw-r--r--drivers/net/wireless/libertas/hostcmd.h372
1 files changed, 186 insertions, 186 deletions
diff --git a/drivers/net/wireless/libertas/hostcmd.h b/drivers/net/wireless/libertas/hostcmd.h
index 581b9a37d7b7..204d9d53aba8 100644
--- a/drivers/net/wireless/libertas/hostcmd.h
+++ b/drivers/net/wireless/libertas/hostcmd.h
@@ -14,12 +14,12 @@
14/* TxPD descriptor */ 14/* TxPD descriptor */
15struct txpd { 15struct txpd {
16 /* Current Tx packet status */ 16 /* Current Tx packet status */
17 u32 tx_status; 17 __le32 tx_status;
18 /* Tx control */ 18 /* Tx control */
19 u32 tx_control; 19 __le32 tx_control;
20 u32 tx_packet_location; 20 __le32 tx_packet_location;
21 /* Tx packet length */ 21 /* Tx packet length */
22 u16 tx_packet_length; 22 __le16 tx_packet_length;
23 /* First 2 byte of destination MAC address */ 23 /* First 2 byte of destination MAC address */
24 u8 tx_dest_addr_high[2]; 24 u8 tx_dest_addr_high[2];
25 /* Last 4 byte of destination MAC address */ 25 /* Last 4 byte of destination MAC address */
@@ -37,7 +37,7 @@ struct txpd {
37/* RxPD Descriptor */ 37/* RxPD Descriptor */
38struct rxpd { 38struct rxpd {
39 /* Current Rx packet status */ 39 /* Current Rx packet status */
40 u16 status; 40 __le16 status;
41 41
42 /* SNR */ 42 /* SNR */
43 u8 snr; 43 u8 snr;
@@ -46,7 +46,7 @@ struct rxpd {
46 u8 rx_control; 46 u8 rx_control;
47 47
48 /* Pkt length */ 48 /* Pkt length */
49 u16 pkt_len; 49 __le16 pkt_len;
50 50
51 /* Noise Floor */ 51 /* Noise Floor */
52 u8 nf; 52 u8 nf;
@@ -55,10 +55,10 @@ struct rxpd {
55 u8 rx_rate; 55 u8 rx_rate;
56 56
57 /* Pkt addr */ 57 /* Pkt addr */
58 u32 pkt_ptr; 58 __le32 pkt_ptr;
59 59
60 /* Next Rx RxPD addr */ 60 /* Next Rx RxPD addr */
61 u32 next_rxpd_ptr; 61 __le32 next_rxpd_ptr;
62 62
63 /* Pkt Priority */ 63 /* Pkt Priority */
64 u8 priority; 64 u8 priority;
@@ -89,22 +89,22 @@ struct cmd_ctrl_node {
89 * is determined from the keylength field. 89 * is determined from the keylength field.
90 */ 90 */
91struct WLAN_802_11_KEY { 91struct WLAN_802_11_KEY {
92 u32 len; 92 __le32 len;
93 u32 flags; /* KEY_INFO_* from wlan_defs.h */ 93 __le32 flags; /* KEY_INFO_* from wlan_defs.h */
94 u8 key[MRVL_MAX_KEY_WPA_KEY_LENGTH]; 94 u8 key[MRVL_MAX_KEY_WPA_KEY_LENGTH];
95 u16 type; /* KEY_TYPE_* from wlan_defs.h */ 95 __le16 type; /* KEY_TYPE_* from wlan_defs.h */
96}; 96};
97 97
98struct IE_WPA { 98struct IE_WPA {
99 u8 elementid; 99 u8 elementid;
100 u8 len; 100 u8 len;
101 u8 oui[4]; 101 u8 oui[4];
102 u16 version; 102 __le16 version;
103}; 103};
104 104
105struct WLAN_802_11_SSID { 105struct WLAN_802_11_SSID {
106 /* SSID length */ 106 /* SSID length */
107 u32 ssidlength; 107 __le32 ssidlength;
108 108
109 /* SSID information field */ 109 /* SSID information field */
110 u8 ssid[IW_ESSID_MAX_SIZE]; 110 u8 ssid[IW_ESSID_MAX_SIZE];
@@ -122,9 +122,9 @@ struct wlan_offset_value {
122}; 122};
123 123
124struct WLAN_802_11_FIXED_IEs { 124struct WLAN_802_11_FIXED_IEs {
125 u8 timestamp[8]; 125 __le64 timestamp;
126 u16 beaconinterval; 126 __le16 beaconinterval;
127 u16 capabilities; 127 u16 capabilities; /* Actually struct ieeetypes_capinfo */
128}; 128};
129 129
130struct WLAN_802_11_VARIABLE_IEs { 130struct WLAN_802_11_VARIABLE_IEs {
@@ -136,10 +136,10 @@ struct WLAN_802_11_VARIABLE_IEs {
136/* Define general data structure */ 136/* Define general data structure */
137/* cmd_DS_GEN */ 137/* cmd_DS_GEN */
138struct cmd_ds_gen { 138struct cmd_ds_gen {
139 u16 command; 139 __le16 command;
140 u16 size; 140 __le16 size;
141 u16 seqnum; 141 __le16 seqnum;
142 u16 result; 142 __le16 result;
143}; 143};
144 144
145#define S_DS_GEN sizeof(struct cmd_ds_gen) 145#define S_DS_GEN sizeof(struct cmd_ds_gen)
@@ -149,44 +149,44 @@ struct cmd_ds_gen {
149 */ 149 */
150struct cmd_ds_get_hw_spec { 150struct cmd_ds_get_hw_spec {
151 /* HW Interface version number */ 151 /* HW Interface version number */
152 u16 hwifversion; 152 __le16 hwifversion;
153 /* HW version number */ 153 /* HW version number */
154 u16 version; 154 __le16 version;
155 /* Max number of TxPD FW can handle */ 155 /* Max number of TxPD FW can handle */
156 u16 nr_txpd; 156 __le16 nr_txpd;
157 /* Max no of Multicast address */ 157 /* Max no of Multicast address */
158 u16 nr_mcast_adr; 158 __le16 nr_mcast_adr;
159 /* MAC address */ 159 /* MAC address */
160 u8 permanentaddr[6]; 160 u8 permanentaddr[6];
161 161
162 /* region Code */ 162 /* region Code */
163 u16 regioncode; 163 __le16 regioncode;
164 164
165 /* Number of antenna used */ 165 /* Number of antenna used */
166 u16 nr_antenna; 166 __le16 nr_antenna;
167 167
168 /* FW release number, example 0x1234=1.2.3.4 */ 168 /* FW release number, example 0x1234=1.2.3.4 */
169 u32 fwreleasenumber; 169 __le32 fwreleasenumber;
170 170
171 /* Base Address of TxPD queue */ 171 /* Base Address of TxPD queue */
172 u32 wcb_base; 172 __le32 wcb_base;
173 /* Read Pointer of RxPd queue */ 173 /* Read Pointer of RxPd queue */
174 u32 rxpd_rdptr; 174 __le32 rxpd_rdptr;
175 175
176 /* Write Pointer of RxPd queue */ 176 /* Write Pointer of RxPd queue */
177 u32 rxpd_wrptr; 177 __le32 rxpd_wrptr;
178 178
179 /*FW/HW capability */ 179 /*FW/HW capability */
180 u32 fwcapinfo; 180 __le32 fwcapinfo;
181} __attribute__ ((packed)); 181} __attribute__ ((packed));
182 182
183struct cmd_ds_802_11_reset { 183struct cmd_ds_802_11_reset {
184 u16 action; 184 __le16 action;
185}; 185};
186 186
187struct cmd_ds_802_11_subscribe_event { 187struct cmd_ds_802_11_subscribe_event {
188 u16 action; 188 __le16 action;
189 u16 events; 189 __le16 events;
190}; 190};
191 191
192/* 192/*
@@ -205,35 +205,35 @@ struct cmd_ds_802_11_scan {
205}; 205};
206 206
207struct cmd_ds_802_11_scan_rsp { 207struct cmd_ds_802_11_scan_rsp {
208 u16 bssdescriptsize; 208 __le16 bssdescriptsize;
209 u8 nr_sets; 209 u8 nr_sets;
210 u8 bssdesc_and_tlvbuffer[1]; 210 u8 bssdesc_and_tlvbuffer[1];
211}; 211};
212 212
213struct cmd_ds_802_11_get_log { 213struct cmd_ds_802_11_get_log {
214 u32 mcasttxframe; 214 __le32 mcasttxframe;
215 u32 failed; 215 __le32 failed;
216 u32 retry; 216 __le32 retry;
217 u32 multiretry; 217 __le32 multiretry;
218 u32 framedup; 218 __le32 framedup;
219 u32 rtssuccess; 219 __le32 rtssuccess;
220 u32 rtsfailure; 220 __le32 rtsfailure;
221 u32 ackfailure; 221 __le32 ackfailure;
222 u32 rxfrag; 222 __le32 rxfrag;
223 u32 mcastrxframe; 223 __le32 mcastrxframe;
224 u32 fcserror; 224 __le32 fcserror;
225 u32 txframe; 225 __le32 txframe;
226 u32 wepundecryptable; 226 __le32 wepundecryptable;
227}; 227};
228 228
229struct cmd_ds_mac_control { 229struct cmd_ds_mac_control {
230 u16 action; 230 __le16 action;
231 u16 reserved; 231 __le16 reserved;
232}; 232};
233 233
234struct cmd_ds_mac_multicast_adr { 234struct cmd_ds_mac_multicast_adr {
235 u16 action; 235 __le16 action;
236 u16 nr_of_adrs; 236 __le16 nr_of_adrs;
237 u8 maclist[ETH_ALEN * MRVDRV_MAX_MULTICAST_LIST_SIZE]; 237 u8 maclist[ETH_ALEN * MRVDRV_MAX_MULTICAST_LIST_SIZE];
238}; 238};
239 239
@@ -245,14 +245,14 @@ struct cmd_ds_802_11_authenticate {
245 245
246struct cmd_ds_802_11_deauthenticate { 246struct cmd_ds_802_11_deauthenticate {
247 u8 macaddr[6]; 247 u8 macaddr[6];
248 u16 reasoncode; 248 __le16 reasoncode;
249}; 249};
250 250
251struct cmd_ds_802_11_associate { 251struct cmd_ds_802_11_associate {
252 u8 peerstaaddr[6]; 252 u8 peerstaaddr[6];
253 struct ieeetypes_capinfo capinfo; 253 struct ieeetypes_capinfo capinfo;
254 u16 listeninterval; 254 __le16 listeninterval;
255 u16 bcnperiod; 255 __le16 bcnperiod;
256 u8 dtimperiod; 256 u8 dtimperiod;
257 257
258#if 0 258#if 0
@@ -265,7 +265,7 @@ struct cmd_ds_802_11_associate {
265 265
266struct cmd_ds_802_11_disassociate { 266struct cmd_ds_802_11_disassociate {
267 u8 destmacaddr[6]; 267 u8 destmacaddr[6];
268 u16 reasoncode; 268 __le16 reasoncode;
269}; 269};
270 270
271struct cmd_ds_802_11_associate_rsp { 271struct cmd_ds_802_11_associate_rsp {
@@ -279,10 +279,10 @@ struct cmd_ds_802_11_ad_hoc_result {
279 279
280struct cmd_ds_802_11_set_wep { 280struct cmd_ds_802_11_set_wep {
281 /* ACT_ADD, ACT_REMOVE or ACT_ENABLE */ 281 /* ACT_ADD, ACT_REMOVE or ACT_ENABLE */
282 u16 action; 282 __le16 action;
283 283
284 /* key Index selected for Tx */ 284 /* key Index selected for Tx */
285 u16 keyindex; 285 __le16 keyindex;
286 286
287 /* 40, 128bit or TXWEP */ 287 /* 40, 128bit or TXWEP */
288 u8 keytype[4]; 288 u8 keytype[4];
@@ -290,96 +290,96 @@ struct cmd_ds_802_11_set_wep {
290}; 290};
291 291
292struct cmd_ds_802_3_get_stat { 292struct cmd_ds_802_3_get_stat {
293 u32 xmitok; 293 __le32 xmitok;
294 u32 rcvok; 294 __le32 rcvok;
295 u32 xmiterror; 295 __le32 xmiterror;
296 u32 rcverror; 296 __le32 rcverror;
297 u32 rcvnobuffer; 297 __le32 rcvnobuffer;
298 u32 rcvcrcerror; 298 __le32 rcvcrcerror;
299}; 299};
300 300
301struct cmd_ds_802_11_get_stat { 301struct cmd_ds_802_11_get_stat {
302 u32 txfragmentcnt; 302 __le32 txfragmentcnt;
303 u32 mcasttxframecnt; 303 __le32 mcasttxframecnt;
304 u32 failedcnt; 304 __le32 failedcnt;
305 u32 retrycnt; 305 __le32 retrycnt;
306 u32 Multipleretrycnt; 306 __le32 Multipleretrycnt;
307 u32 rtssuccesscnt; 307 __le32 rtssuccesscnt;
308 u32 rtsfailurecnt; 308 __le32 rtsfailurecnt;
309 u32 ackfailurecnt; 309 __le32 ackfailurecnt;
310 u32 frameduplicatecnt; 310 __le32 frameduplicatecnt;
311 u32 rxfragmentcnt; 311 __le32 rxfragmentcnt;
312 u32 mcastrxframecnt; 312 __le32 mcastrxframecnt;
313 u32 fcserrorcnt; 313 __le32 fcserrorcnt;
314 u32 bcasttxframecnt; 314 __le32 bcasttxframecnt;
315 u32 bcastrxframecnt; 315 __le32 bcastrxframecnt;
316 u32 txbeacon; 316 __le32 txbeacon;
317 u32 rxbeacon; 317 __le32 rxbeacon;
318 u32 wepundecryptable; 318 __le32 wepundecryptable;
319}; 319};
320 320
321struct cmd_ds_802_11_snmp_mib { 321struct cmd_ds_802_11_snmp_mib {
322 u16 querytype; 322 __le16 querytype;
323 u16 oid; 323 __le16 oid;
324 u16 bufsize; 324 __le16 bufsize;
325 u8 value[128]; 325 u8 value[128];
326}; 326};
327 327
328struct cmd_ds_mac_reg_map { 328struct cmd_ds_mac_reg_map {
329 u16 buffersize; 329 __le16 buffersize;
330 u8 regmap[128]; 330 u8 regmap[128];
331 u16 reserved; 331 __le16 reserved;
332}; 332};
333 333
334struct cmd_ds_bbp_reg_map { 334struct cmd_ds_bbp_reg_map {
335 u16 buffersize; 335 __le16 buffersize;
336 u8 regmap[128]; 336 u8 regmap[128];
337 u16 reserved; 337 __le16 reserved;
338}; 338};
339 339
340struct cmd_ds_rf_reg_map { 340struct cmd_ds_rf_reg_map {
341 u16 buffersize; 341 __le16 buffersize;
342 u8 regmap[64]; 342 u8 regmap[64];
343 u16 reserved; 343 __le16 reserved;
344}; 344};
345 345
346struct cmd_ds_mac_reg_access { 346struct cmd_ds_mac_reg_access {
347 u16 action; 347 __le16 action;
348 u16 offset; 348 __le16 offset;
349 u32 value; 349 __le32 value;
350}; 350};
351 351
352struct cmd_ds_bbp_reg_access { 352struct cmd_ds_bbp_reg_access {
353 u16 action; 353 __le16 action;
354 u16 offset; 354 __le16 offset;
355 u8 value; 355 u8 value;
356 u8 reserved[3]; 356 u8 reserved[3];
357}; 357};
358 358
359struct cmd_ds_rf_reg_access { 359struct cmd_ds_rf_reg_access {
360 u16 action; 360 __le16 action;
361 u16 offset; 361 __le16 offset;
362 u8 value; 362 u8 value;
363 u8 reserved[3]; 363 u8 reserved[3];
364}; 364};
365 365
366struct cmd_ds_802_11_radio_control { 366struct cmd_ds_802_11_radio_control {
367 u16 action; 367 __le16 action;
368 u16 control; 368 __le16 control;
369}; 369};
370 370
371struct cmd_ds_802_11_sleep_params { 371struct cmd_ds_802_11_sleep_params {
372 /* ACT_GET/ACT_SET */ 372 /* ACT_GET/ACT_SET */
373 u16 action; 373 __le16 action;
374 374
375 /* Sleep clock error in ppm */ 375 /* Sleep clock error in ppm */
376 u16 error; 376 __le16 error;
377 377
378 /* Wakeup offset in usec */ 378 /* Wakeup offset in usec */
379 u16 offset; 379 __le16 offset;
380 380
381 /* Clock stabilization time in usec */ 381 /* Clock stabilization time in usec */
382 u16 stabletime; 382 __le16 stabletime;
383 383
384 /* control periodic calibration */ 384 /* control periodic calibration */
385 u8 calcontrol; 385 u8 calcontrol;
@@ -388,100 +388,100 @@ struct cmd_ds_802_11_sleep_params {
388 u8 externalsleepclk; 388 u8 externalsleepclk;
389 389
390 /* reserved field, should be set to zero */ 390 /* reserved field, should be set to zero */
391 u16 reserved; 391 __le16 reserved;
392}; 392};
393 393
394struct cmd_ds_802_11_inactivity_timeout { 394struct cmd_ds_802_11_inactivity_timeout {
395 /* ACT_GET/ACT_SET */ 395 /* ACT_GET/ACT_SET */
396 u16 action; 396 __le16 action;
397 397
398 /* Inactivity timeout in msec */ 398 /* Inactivity timeout in msec */
399 u16 timeout; 399 __le16 timeout;
400}; 400};
401 401
402struct cmd_ds_802_11_rf_channel { 402struct cmd_ds_802_11_rf_channel {
403 u16 action; 403 __le16 action;
404 u16 currentchannel; 404 __le16 currentchannel;
405 u16 rftype; 405 __le16 rftype;
406 u16 reserved; 406 __le16 reserved;
407 u8 channellist[32]; 407 u8 channellist[32];
408}; 408};
409 409
410struct cmd_ds_802_11_rssi { 410struct cmd_ds_802_11_rssi {
411 /* weighting factor */ 411 /* weighting factor */
412 u16 N; 412 __le16 N;
413 413
414 u16 reserved_0; 414 __le16 reserved_0;
415 u16 reserved_1; 415 __le16 reserved_1;
416 u16 reserved_2; 416 __le16 reserved_2;
417}; 417};
418 418
419struct cmd_ds_802_11_rssi_rsp { 419struct cmd_ds_802_11_rssi_rsp {
420 u16 SNR; 420 __le16 SNR;
421 u16 noisefloor; 421 __le16 noisefloor;
422 u16 avgSNR; 422 __le16 avgSNR;
423 u16 avgnoisefloor; 423 __le16 avgnoisefloor;
424}; 424};
425 425
426struct cmd_ds_802_11_mac_address { 426struct cmd_ds_802_11_mac_address {
427 u16 action; 427 __le16 action;
428 u8 macadd[ETH_ALEN]; 428 u8 macadd[ETH_ALEN];
429}; 429};
430 430
431struct cmd_ds_802_11_rf_tx_power { 431struct cmd_ds_802_11_rf_tx_power {
432 u16 action; 432 __le16 action;
433 u16 currentlevel; 433 __le16 currentlevel;
434}; 434};
435 435
436struct cmd_ds_802_11_rf_antenna { 436struct cmd_ds_802_11_rf_antenna {
437 u16 action; 437 __le16 action;
438 438
439 /* Number of antennas or 0xffff(diversity) */ 439 /* Number of antennas or 0xffff(diversity) */
440 u16 antennamode; 440 __le16 antennamode;
441 441
442}; 442};
443 443
444struct cmd_ds_802_11_ps_mode { 444struct cmd_ds_802_11_ps_mode {
445 u16 action; 445 __le16 action;
446 u16 nullpktinterval; 446 __le16 nullpktinterval;
447 u16 multipledtim; 447 __le16 multipledtim;
448 u16 reserved; 448 __le16 reserved;
449 u16 locallisteninterval; 449 __le16 locallisteninterval;
450}; 450};
451 451
452struct PS_CMD_ConfirmSleep { 452struct PS_CMD_ConfirmSleep {
453 u16 command; 453 __le16 command;
454 u16 size; 454 __le16 size;
455 u16 seqnum; 455 __le16 seqnum;
456 u16 result; 456 __le16 result;
457 457
458 u16 action; 458 __le16 action;
459 u16 reserved1; 459 __le16 reserved1;
460 u16 multipledtim; 460 __le16 multipledtim;
461 u16 reserved; 461 __le16 reserved;
462 u16 locallisteninterval; 462 __le16 locallisteninterval;
463}; 463};
464 464
465struct cmd_ds_802_11_data_rate { 465struct cmd_ds_802_11_data_rate {
466 u16 action; 466 __le16 action;
467 u16 reserverd; 467 __le16 reserverd;
468 u8 datarate[G_SUPPORTED_RATES]; 468 u8 datarate[G_SUPPORTED_RATES];
469}; 469};
470 470
471struct cmd_ds_802_11_rate_adapt_rateset { 471struct cmd_ds_802_11_rate_adapt_rateset {
472 u16 action; 472 __le16 action;
473 u16 enablehwauto; 473 __le16 enablehwauto;
474 u16 bitmap; 474 __le16 bitmap;
475}; 475};
476 476
477struct cmd_ds_802_11_ad_hoc_start { 477struct cmd_ds_802_11_ad_hoc_start {
478 u8 SSID[IW_ESSID_MAX_SIZE]; 478 u8 SSID[IW_ESSID_MAX_SIZE];
479 u8 bsstype; 479 u8 bsstype;
480 u16 beaconperiod; 480 __le16 beaconperiod;
481 u8 dtimperiod; 481 u8 dtimperiod;
482 union IEEEtypes_ssparamset ssparamset; 482 union IEEEtypes_ssparamset ssparamset;
483 union ieeetypes_phyparamset phyparamset; 483 union ieeetypes_phyparamset phyparamset;
484 u16 probedelay; 484 __le16 probedelay;
485 struct ieeetypes_capinfo cap; 485 struct ieeetypes_capinfo cap;
486 u8 datarate[G_SUPPORTED_RATES]; 486 u8 datarate[G_SUPPORTED_RATES];
487 u8 tlv_memory_size_pad[100]; 487 u8 tlv_memory_size_pad[100];
@@ -491,10 +491,10 @@ struct adhoc_bssdesc {
491 u8 BSSID[6]; 491 u8 BSSID[6];
492 u8 SSID[32]; 492 u8 SSID[32];
493 u8 bsstype; 493 u8 bsstype;
494 u16 beaconperiod; 494 __le16 beaconperiod;
495 u8 dtimperiod; 495 u8 dtimperiod;
496 u8 timestamp[8]; 496 __le64 timestamp;
497 u8 localtime[8]; 497 __le64 localtime;
498 union ieeetypes_phyparamset phyparamset; 498 union ieeetypes_phyparamset phyparamset;
499 union IEEEtypes_ssparamset ssparamset; 499 union IEEEtypes_ssparamset ssparamset;
500 struct ieeetypes_capinfo cap; 500 struct ieeetypes_capinfo cap;
@@ -508,52 +508,52 @@ struct adhoc_bssdesc {
508 508
509struct cmd_ds_802_11_ad_hoc_join { 509struct cmd_ds_802_11_ad_hoc_join {
510 struct adhoc_bssdesc bssdescriptor; 510 struct adhoc_bssdesc bssdescriptor;
511 u16 failtimeout; 511 __le16 failtimeout;
512 u16 probedelay; 512 __le16 probedelay;
513 513
514} __attribute__ ((packed)); 514} __attribute__ ((packed));
515 515
516struct cmd_ds_802_11_enable_rsn { 516struct cmd_ds_802_11_enable_rsn {
517 u16 action; 517 __le16 action;
518 u16 enable; 518 __le16 enable;
519}; 519};
520 520
521struct MrvlIEtype_keyParamSet { 521struct MrvlIEtype_keyParamSet {
522 /* type ID */ 522 /* type ID */
523 u16 type; 523 __le16 type;
524 524
525 /* length of Payload */ 525 /* length of Payload */
526 u16 length; 526 __le16 length;
527 527
528 /* type of key: WEP=0, TKIP=1, AES=2 */ 528 /* type of key: WEP=0, TKIP=1, AES=2 */
529 u16 keytypeid; 529 __le16 keytypeid;
530 530
531 /* key control Info specific to a keytypeid */ 531 /* key control Info specific to a keytypeid */
532 u16 keyinfo; 532 __le16 keyinfo;
533 533
534 /* length of key */ 534 /* length of key */
535 u16 keylen; 535 __le16 keylen;
536 536
537 /* key material of size keylen */ 537 /* key material of size keylen */
538 u8 key[32]; 538 u8 key[32];
539}; 539};
540 540
541struct cmd_ds_802_11_key_material { 541struct cmd_ds_802_11_key_material {
542 u16 action; 542 __le16 action;
543 struct MrvlIEtype_keyParamSet keyParamSet[2]; 543 struct MrvlIEtype_keyParamSet keyParamSet[2];
544} __attribute__ ((packed)); 544} __attribute__ ((packed));
545 545
546struct cmd_ds_802_11_eeprom_access { 546struct cmd_ds_802_11_eeprom_access {
547 u16 action; 547 __le16 action;
548 548
549 /* multiple 4 */ 549 /* multiple 4 */
550 u16 offset; 550 __le16 offset;
551 u16 bytecount; 551 __le16 bytecount;
552 u8 value; 552 u8 value;
553} __attribute__ ((packed)); 553} __attribute__ ((packed));
554 554
555struct cmd_ds_802_11_tpc_cfg { 555struct cmd_ds_802_11_tpc_cfg {
556 u16 action; 556 __le16 action;
557 u8 enable; 557 u8 enable;
558 s8 P0; 558 s8 P0;
559 s8 P1; 559 s8 P1;
@@ -562,13 +562,13 @@ struct cmd_ds_802_11_tpc_cfg {
562} __attribute__ ((packed)); 562} __attribute__ ((packed));
563 563
564struct cmd_ds_802_11_led_ctrl { 564struct cmd_ds_802_11_led_ctrl {
565 u16 action; 565 __le16 action;
566 u16 numled; 566 __le16 numled;
567 u8 data[256]; 567 u8 data[256];
568} __attribute__ ((packed)); 568} __attribute__ ((packed));
569 569
570struct cmd_ds_802_11_pwr_cfg { 570struct cmd_ds_802_11_pwr_cfg {
571 u16 action; 571 __le16 action;
572 u8 enable; 572 u8 enable;
573 s8 PA_P0; 573 s8 PA_P0;
574 s8 PA_P1; 574 s8 PA_P1;
@@ -576,21 +576,21 @@ struct cmd_ds_802_11_pwr_cfg {
576} __attribute__ ((packed)); 576} __attribute__ ((packed));
577 577
578struct cmd_ds_802_11_afc { 578struct cmd_ds_802_11_afc {
579 u16 afc_auto; 579 __le16 afc_auto;
580 union { 580 union {
581 struct { 581 struct {
582 u16 threshold; 582 __le16 threshold;
583 u16 period; 583 __le16 period;
584 }; 584 };
585 struct { 585 struct {
586 s16 timing_offset; 586 __le16 timing_offset; /* signed */
587 s16 carrier_offset; 587 __le16 carrier_offset; /* signed */
588 }; 588 };
589 }; 589 };
590} __attribute__ ((packed)); 590} __attribute__ ((packed));
591 591
592struct cmd_tx_rate_query { 592struct cmd_tx_rate_query {
593 u16 txrate; 593 __le16 txrate;
594} __attribute__ ((packed)); 594} __attribute__ ((packed));
595 595
596struct cmd_ds_get_tsf { 596struct cmd_ds_get_tsf {
@@ -598,35 +598,35 @@ struct cmd_ds_get_tsf {
598} __attribute__ ((packed)); 598} __attribute__ ((packed));
599 599
600struct cmd_ds_bt_access { 600struct cmd_ds_bt_access {
601 u16 action; 601 __le16 action;
602 u32 id; 602 __le32 id;
603 u8 addr1[ETH_ALEN]; 603 u8 addr1[ETH_ALEN];
604 u8 addr2[ETH_ALEN]; 604 u8 addr2[ETH_ALEN];
605} __attribute__ ((packed)); 605} __attribute__ ((packed));
606 606
607struct cmd_ds_fwt_access { 607struct cmd_ds_fwt_access {
608 u16 action; 608 __le16 action;
609 u32 id; 609 __le32 id;
610 u8 valid; 610 u8 valid;
611 u8 da[ETH_ALEN]; 611 u8 da[ETH_ALEN];
612 u8 dir; 612 u8 dir;
613 u8 ra[ETH_ALEN]; 613 u8 ra[ETH_ALEN];
614 u32 ssn; 614 __le32 ssn;
615 u32 dsn; 615 __le32 dsn;
616 u32 metric; 616 __le32 metric;
617 u8 rate; 617 u8 rate;
618 u8 hopcount; 618 u8 hopcount;
619 u8 ttl; 619 u8 ttl;
620 u32 expiration; 620 __le32 expiration;
621 u8 sleepmode; 621 u8 sleepmode;
622 u32 snr; 622 __le32 snr;
623 u32 references; 623 __le32 references;
624 u8 prec[ETH_ALEN]; 624 u8 prec[ETH_ALEN];
625} __attribute__ ((packed)); 625} __attribute__ ((packed));
626 626
627struct cmd_ds_mesh_access { 627struct cmd_ds_mesh_access {
628 u16 action; 628 __le16 action;
629 u32 data[32]; /* last position reserved */ 629 __le32 data[32]; /* last position reserved */
630} __attribute__ ((packed)); 630} __attribute__ ((packed));
631 631
632/* Number of stats counters returned by the firmware */ 632/* Number of stats counters returned by the firmware */
@@ -634,10 +634,10 @@ struct cmd_ds_mesh_access {
634 634
635struct cmd_ds_command { 635struct cmd_ds_command {
636 /* command header */ 636 /* command header */
637 u16 command; 637 __le16 command;
638 u16 size; 638 __le16 size;
639 u16 seqnum; 639 __le16 seqnum;
640 u16 result; 640 __le16 result;
641 641
642 /* command Body */ 642 /* command Body */
643 union { 643 union {