Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 1 | /* |
| 2 | * This file contains the function prototypes, data structure |
| 3 | * and defines for all the host/station commands |
| 4 | */ |
Holger Schurig | 1007832 | 2007-11-15 18:05:47 -0500 | [diff] [blame] | 5 | #ifndef _LBS_HOSTCMD_H |
| 6 | #define _LBS_HOSTCMD_H |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 7 | |
| 8 | #include <linux/wireless.h> |
| 9 | #include "11d.h" |
| 10 | #include "types.h" |
| 11 | |
| 12 | /* 802.11-related definitions */ |
| 13 | |
| 14 | /* TxPD descriptor */ |
| 15 | struct txpd { |
| 16 | /* Current Tx packet status */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 17 | __le32 tx_status; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 18 | /* Tx control */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 19 | __le32 tx_control; |
| 20 | __le32 tx_packet_location; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 21 | /* Tx packet length */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 22 | __le16 tx_packet_length; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 23 | /* First 2 byte of destination MAC address */ |
| 24 | u8 tx_dest_addr_high[2]; |
| 25 | /* Last 4 byte of destination MAC address */ |
| 26 | u8 tx_dest_addr_low[4]; |
| 27 | /* Pkt Priority */ |
| 28 | u8 priority; |
| 29 | /* Pkt Trasnit Power control */ |
| 30 | u8 powermgmt; |
| 31 | /* Amount of time the packet has been queued in the driver (units = 2ms) */ |
| 32 | u8 pktdelay_2ms; |
| 33 | /* reserved */ |
| 34 | u8 reserved1; |
| 35 | }; |
| 36 | |
| 37 | /* RxPD Descriptor */ |
| 38 | struct rxpd { |
| 39 | /* Current Rx packet status */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 40 | __le16 status; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 41 | |
| 42 | /* SNR */ |
| 43 | u8 snr; |
| 44 | |
| 45 | /* Tx control */ |
| 46 | u8 rx_control; |
| 47 | |
| 48 | /* Pkt length */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 49 | __le16 pkt_len; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 50 | |
| 51 | /* Noise Floor */ |
| 52 | u8 nf; |
| 53 | |
| 54 | /* Rx Packet Rate */ |
| 55 | u8 rx_rate; |
| 56 | |
| 57 | /* Pkt addr */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 58 | __le32 pkt_ptr; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 59 | |
| 60 | /* Next Rx RxPD addr */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 61 | __le32 next_rxpd_ptr; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 62 | |
| 63 | /* Pkt Priority */ |
| 64 | u8 priority; |
| 65 | u8 reserved[3]; |
| 66 | }; |
| 67 | |
Dan Williams | 7ad994d | 2007-12-11 12:33:30 -0500 | [diff] [blame] | 68 | struct cmd_header { |
| 69 | __le16 command; |
| 70 | __le16 size; |
| 71 | __le16 seqnum; |
| 72 | __le16 result; |
| 73 | } __attribute__ ((packed)); |
| 74 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 75 | struct cmd_ctrl_node { |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 76 | struct list_head list; |
David Woodhouse | ae125bf | 2007-12-15 04:22:52 -0500 | [diff] [blame] | 77 | int result; |
Holger Schurig | 675787e | 2007-12-05 17:58:11 +0100 | [diff] [blame] | 78 | /* command response */ |
Dan Williams | 7ad994d | 2007-12-11 12:33:30 -0500 | [diff] [blame] | 79 | int (*callback)(struct lbs_private *, unsigned long, struct cmd_header *); |
David Woodhouse | 1309b55 | 2007-12-10 13:36:10 -0500 | [diff] [blame] | 80 | unsigned long callback_arg; |
Holger Schurig | 675787e | 2007-12-05 17:58:11 +0100 | [diff] [blame] | 81 | /* command data */ |
Dan Williams | ddac452 | 2007-12-11 13:49:39 -0500 | [diff] [blame] | 82 | struct cmd_header *cmdbuf; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 83 | /* wait queue */ |
| 84 | u16 cmdwaitqwoken; |
| 85 | wait_queue_head_t cmdwait_q; |
| 86 | }; |
| 87 | |
Dan Williams | 1443b65 | 2007-08-02 10:45:55 -0400 | [diff] [blame] | 88 | /* Generic structure to hold all key types. */ |
| 89 | struct enc_key { |
| 90 | u16 len; |
Holger Schurig | 1007832 | 2007-11-15 18:05:47 -0500 | [diff] [blame] | 91 | u16 flags; /* KEY_INFO_* from defs.h */ |
| 92 | u16 type; /* KEY_TYPE_* from defs.h */ |
Dan Williams | 1443b65 | 2007-08-02 10:45:55 -0400 | [diff] [blame] | 93 | u8 key[32]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 94 | }; |
| 95 | |
Holger Schurig | 1007832 | 2007-11-15 18:05:47 -0500 | [diff] [blame] | 96 | /* lbs_offset_value */ |
| 97 | struct lbs_offset_value { |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 98 | u32 offset; |
| 99 | u32 value; |
| 100 | }; |
| 101 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 102 | /* Define general data structure */ |
| 103 | /* cmd_DS_GEN */ |
| 104 | struct cmd_ds_gen { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 105 | __le16 command; |
| 106 | __le16 size; |
| 107 | __le16 seqnum; |
| 108 | __le16 result; |
Holger Schurig | 675787e | 2007-12-05 17:58:11 +0100 | [diff] [blame] | 109 | void *cmdresp[0]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 110 | }; |
| 111 | |
| 112 | #define S_DS_GEN sizeof(struct cmd_ds_gen) |
Holger Schurig | 675787e | 2007-12-05 17:58:11 +0100 | [diff] [blame] | 113 | |
| 114 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 115 | /* |
Dan Williams | 0aef64d | 2007-08-02 11:31:18 -0400 | [diff] [blame] | 116 | * Define data structure for CMD_GET_HW_SPEC |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 117 | * This structure defines the response for the GET_HW_SPEC command |
| 118 | */ |
| 119 | struct cmd_ds_get_hw_spec { |
Dan Williams | 6e66f03 | 2007-12-11 12:42:16 -0500 | [diff] [blame] | 120 | struct cmd_header hdr; |
| 121 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 122 | /* HW Interface version number */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 123 | __le16 hwifversion; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 124 | /* HW version number */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 125 | __le16 version; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 126 | /* Max number of TxPD FW can handle */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 127 | __le16 nr_txpd; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 128 | /* Max no of Multicast address */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 129 | __le16 nr_mcast_adr; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 130 | /* MAC address */ |
| 131 | u8 permanentaddr[6]; |
| 132 | |
| 133 | /* region Code */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 134 | __le16 regioncode; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 135 | |
| 136 | /* Number of antenna used */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 137 | __le16 nr_antenna; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 138 | |
David Woodhouse | e5b3d47 | 2007-05-25 23:40:21 -0400 | [diff] [blame] | 139 | /* FW release number, example 1,2,3,4 = 3.2.1p4 */ |
| 140 | u8 fwreleasenumber[4]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 141 | |
| 142 | /* Base Address of TxPD queue */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 143 | __le32 wcb_base; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 144 | /* Read Pointer of RxPd queue */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 145 | __le32 rxpd_rdptr; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 146 | |
| 147 | /* Write Pointer of RxPd queue */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 148 | __le32 rxpd_wrptr; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 149 | |
| 150 | /*FW/HW capability */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 151 | __le32 fwcapinfo; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 152 | } __attribute__ ((packed)); |
| 153 | |
| 154 | struct cmd_ds_802_11_reset { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 155 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 156 | }; |
| 157 | |
| 158 | struct cmd_ds_802_11_subscribe_event { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 159 | __le16 action; |
| 160 | __le16 events; |
Holger Schurig | 3a18864 | 2007-11-26 10:07:14 +0100 | [diff] [blame] | 161 | |
| 162 | /* A TLV to the CMD_802_11_SUBSCRIBE_EVENT command can contain a |
| 163 | * number of TLVs. From the v5.1 manual, those TLVs would add up to |
| 164 | * 40 bytes. However, future firmware might add additional TLVs, so I |
| 165 | * bump this up a bit. |
| 166 | */ |
| 167 | u8 tlv[128]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 168 | }; |
| 169 | |
| 170 | /* |
| 171 | * This scan handle Country Information IE(802.11d compliant) |
Dan Williams | 0aef64d | 2007-08-02 11:31:18 -0400 | [diff] [blame] | 172 | * Define data structure for CMD_802_11_SCAN |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 173 | */ |
| 174 | struct cmd_ds_802_11_scan { |
| 175 | u8 bsstype; |
Dan Williams | 492b6da | 2007-08-02 11:16:07 -0400 | [diff] [blame] | 176 | u8 bssid[ETH_ALEN]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 177 | u8 tlvbuffer[1]; |
| 178 | #if 0 |
| 179 | mrvlietypes_ssidparamset_t ssidParamSet; |
| 180 | mrvlietypes_chanlistparamset_t ChanListParamSet; |
| 181 | mrvlietypes_ratesparamset_t OpRateSet; |
| 182 | #endif |
| 183 | }; |
| 184 | |
| 185 | struct cmd_ds_802_11_scan_rsp { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 186 | __le16 bssdescriptsize; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 187 | u8 nr_sets; |
| 188 | u8 bssdesc_and_tlvbuffer[1]; |
| 189 | }; |
| 190 | |
| 191 | struct cmd_ds_802_11_get_log { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 192 | __le32 mcasttxframe; |
| 193 | __le32 failed; |
| 194 | __le32 retry; |
| 195 | __le32 multiretry; |
| 196 | __le32 framedup; |
| 197 | __le32 rtssuccess; |
| 198 | __le32 rtsfailure; |
| 199 | __le32 ackfailure; |
| 200 | __le32 rxfrag; |
| 201 | __le32 mcastrxframe; |
| 202 | __le32 fcserror; |
| 203 | __le32 txframe; |
| 204 | __le32 wepundecryptable; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 205 | }; |
| 206 | |
| 207 | struct cmd_ds_mac_control { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 208 | __le16 action; |
| 209 | __le16 reserved; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 210 | }; |
| 211 | |
| 212 | struct cmd_ds_mac_multicast_adr { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 213 | __le16 action; |
| 214 | __le16 nr_of_adrs; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 215 | u8 maclist[ETH_ALEN * MRVDRV_MAX_MULTICAST_LIST_SIZE]; |
| 216 | }; |
| 217 | |
| 218 | struct cmd_ds_802_11_authenticate { |
| 219 | u8 macaddr[ETH_ALEN]; |
| 220 | u8 authtype; |
| 221 | u8 reserved[10]; |
| 222 | }; |
| 223 | |
| 224 | struct cmd_ds_802_11_deauthenticate { |
| 225 | u8 macaddr[6]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 226 | __le16 reasoncode; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 227 | }; |
| 228 | |
| 229 | struct cmd_ds_802_11_associate { |
| 230 | u8 peerstaaddr[6]; |
Dan Williams | 0c9ca690 | 2007-08-02 10:43:44 -0400 | [diff] [blame] | 231 | __le16 capability; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 232 | __le16 listeninterval; |
| 233 | __le16 bcnperiod; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 234 | u8 dtimperiod; |
| 235 | |
| 236 | #if 0 |
| 237 | mrvlietypes_ssidparamset_t ssidParamSet; |
| 238 | mrvlietypes_phyparamset_t phyparamset; |
| 239 | mrvlietypes_ssparamset_t ssparamset; |
| 240 | mrvlietypes_ratesparamset_t ratesParamSet; |
| 241 | #endif |
| 242 | } __attribute__ ((packed)); |
| 243 | |
| 244 | struct cmd_ds_802_11_disassociate { |
| 245 | u8 destmacaddr[6]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 246 | __le16 reasoncode; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 247 | }; |
| 248 | |
| 249 | struct cmd_ds_802_11_associate_rsp { |
| 250 | struct ieeetypes_assocrsp assocRsp; |
| 251 | }; |
| 252 | |
| 253 | struct cmd_ds_802_11_ad_hoc_result { |
Dan Williams | ea8da92 | 2007-08-02 11:18:23 -0400 | [diff] [blame] | 254 | u8 pad[3]; |
| 255 | u8 bssid[ETH_ALEN]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 256 | }; |
| 257 | |
| 258 | struct cmd_ds_802_11_set_wep { |
| 259 | /* ACT_ADD, ACT_REMOVE or ACT_ENABLE */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 260 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 261 | |
| 262 | /* key Index selected for Tx */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 263 | __le16 keyindex; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 264 | |
| 265 | /* 40, 128bit or TXWEP */ |
| 266 | u8 keytype[4]; |
| 267 | u8 keymaterial[4][16]; |
| 268 | }; |
| 269 | |
| 270 | struct cmd_ds_802_3_get_stat { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 271 | __le32 xmitok; |
| 272 | __le32 rcvok; |
| 273 | __le32 xmiterror; |
| 274 | __le32 rcverror; |
| 275 | __le32 rcvnobuffer; |
| 276 | __le32 rcvcrcerror; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 277 | }; |
| 278 | |
| 279 | struct cmd_ds_802_11_get_stat { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 280 | __le32 txfragmentcnt; |
| 281 | __le32 mcasttxframecnt; |
| 282 | __le32 failedcnt; |
| 283 | __le32 retrycnt; |
| 284 | __le32 Multipleretrycnt; |
| 285 | __le32 rtssuccesscnt; |
| 286 | __le32 rtsfailurecnt; |
| 287 | __le32 ackfailurecnt; |
| 288 | __le32 frameduplicatecnt; |
| 289 | __le32 rxfragmentcnt; |
| 290 | __le32 mcastrxframecnt; |
| 291 | __le32 fcserrorcnt; |
| 292 | __le32 bcasttxframecnt; |
| 293 | __le32 bcastrxframecnt; |
| 294 | __le32 txbeacon; |
| 295 | __le32 rxbeacon; |
| 296 | __le32 wepundecryptable; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 297 | }; |
| 298 | |
| 299 | struct cmd_ds_802_11_snmp_mib { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 300 | __le16 querytype; |
| 301 | __le16 oid; |
| 302 | __le16 bufsize; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 303 | u8 value[128]; |
| 304 | }; |
| 305 | |
| 306 | struct cmd_ds_mac_reg_map { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 307 | __le16 buffersize; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 308 | u8 regmap[128]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 309 | __le16 reserved; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 310 | }; |
| 311 | |
| 312 | struct cmd_ds_bbp_reg_map { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 313 | __le16 buffersize; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 314 | u8 regmap[128]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 315 | __le16 reserved; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 316 | }; |
| 317 | |
| 318 | struct cmd_ds_rf_reg_map { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 319 | __le16 buffersize; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 320 | u8 regmap[64]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 321 | __le16 reserved; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 322 | }; |
| 323 | |
| 324 | struct cmd_ds_mac_reg_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 325 | __le16 action; |
| 326 | __le16 offset; |
| 327 | __le32 value; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 328 | }; |
| 329 | |
| 330 | struct cmd_ds_bbp_reg_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 331 | __le16 action; |
| 332 | __le16 offset; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 333 | u8 value; |
| 334 | u8 reserved[3]; |
| 335 | }; |
| 336 | |
| 337 | struct cmd_ds_rf_reg_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 338 | __le16 action; |
| 339 | __le16 offset; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 340 | u8 value; |
| 341 | u8 reserved[3]; |
| 342 | }; |
| 343 | |
| 344 | struct cmd_ds_802_11_radio_control { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 345 | __le16 action; |
| 346 | __le16 control; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 347 | }; |
| 348 | |
Brajesh Dave | 96287ac | 2007-11-20 17:44:28 -0500 | [diff] [blame] | 349 | struct cmd_ds_802_11_beacon_control { |
| 350 | __le16 action; |
| 351 | __le16 beacon_enable; |
| 352 | __le16 beacon_period; |
| 353 | }; |
| 354 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 355 | struct cmd_ds_802_11_sleep_params { |
| 356 | /* ACT_GET/ACT_SET */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 357 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 358 | |
| 359 | /* Sleep clock error in ppm */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 360 | __le16 error; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 361 | |
| 362 | /* Wakeup offset in usec */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 363 | __le16 offset; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 364 | |
| 365 | /* Clock stabilization time in usec */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 366 | __le16 stabletime; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 367 | |
| 368 | /* control periodic calibration */ |
| 369 | u8 calcontrol; |
| 370 | |
| 371 | /* control the use of external sleep clock */ |
| 372 | u8 externalsleepclk; |
| 373 | |
| 374 | /* reserved field, should be set to zero */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 375 | __le16 reserved; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 376 | }; |
| 377 | |
| 378 | struct cmd_ds_802_11_inactivity_timeout { |
| 379 | /* ACT_GET/ACT_SET */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 380 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 381 | |
| 382 | /* Inactivity timeout in msec */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 383 | __le16 timeout; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 384 | }; |
| 385 | |
| 386 | struct cmd_ds_802_11_rf_channel { |
Dan Williams | 2dd4b26 | 2007-12-11 16:54:15 -0500 | [diff] [blame] | 387 | struct cmd_header hdr; |
| 388 | |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 389 | __le16 action; |
Dan Williams | 2dd4b26 | 2007-12-11 16:54:15 -0500 | [diff] [blame] | 390 | __le16 channel; |
| 391 | __le16 rftype; /* unused */ |
| 392 | __le16 reserved; /* unused */ |
| 393 | u8 channellist[32]; /* unused */ |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 394 | }; |
| 395 | |
| 396 | struct cmd_ds_802_11_rssi { |
| 397 | /* weighting factor */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 398 | __le16 N; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 399 | |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 400 | __le16 reserved_0; |
| 401 | __le16 reserved_1; |
| 402 | __le16 reserved_2; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 403 | }; |
| 404 | |
| 405 | struct cmd_ds_802_11_rssi_rsp { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 406 | __le16 SNR; |
| 407 | __le16 noisefloor; |
| 408 | __le16 avgSNR; |
| 409 | __le16 avgnoisefloor; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 410 | }; |
| 411 | |
| 412 | struct cmd_ds_802_11_mac_address { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 413 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 414 | u8 macadd[ETH_ALEN]; |
| 415 | }; |
| 416 | |
| 417 | struct cmd_ds_802_11_rf_tx_power { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 418 | __le16 action; |
| 419 | __le16 currentlevel; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 420 | }; |
| 421 | |
| 422 | struct cmd_ds_802_11_rf_antenna { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 423 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 424 | |
| 425 | /* Number of antennas or 0xffff(diversity) */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 426 | __le16 antennamode; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 427 | |
| 428 | }; |
| 429 | |
Luis Carlos Cobo | 965f8bbc | 2007-08-02 13:16:55 -0400 | [diff] [blame] | 430 | struct cmd_ds_802_11_monitor_mode { |
Holger Schurig | c2df2ef | 2007-12-07 15:30:44 +0000 | [diff] [blame] | 431 | __le16 action; |
| 432 | __le16 mode; |
Luis Carlos Cobo | 965f8bbc | 2007-08-02 13:16:55 -0400 | [diff] [blame] | 433 | }; |
| 434 | |
Luis Carlos Cobo | 63f0023 | 2007-08-02 13:19:24 -0400 | [diff] [blame] | 435 | struct cmd_ds_set_boot2_ver { |
Dan Williams | 7ad994d | 2007-12-11 12:33:30 -0500 | [diff] [blame] | 436 | struct cmd_header hdr; |
| 437 | |
Holger Schurig | c2df2ef | 2007-12-07 15:30:44 +0000 | [diff] [blame] | 438 | __le16 action; |
| 439 | __le16 version; |
Luis Carlos Cobo | 63f0023 | 2007-08-02 13:19:24 -0400 | [diff] [blame] | 440 | }; |
| 441 | |
David Woodhouse | c6ad373 | 2007-12-16 21:43:40 -0500 | [diff] [blame^] | 442 | struct cmd_ds_802_11_fw_wake_method { |
| 443 | struct cmd_header hdr; |
| 444 | |
| 445 | __le16 action; |
| 446 | __le16 method; |
| 447 | }; |
| 448 | |
| 449 | struct cmd_ds_802_11_sleep_period { |
| 450 | struct cmd_header hdr; |
| 451 | |
| 452 | __le16 action; |
| 453 | __le16 period; |
| 454 | }; |
| 455 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 456 | struct cmd_ds_802_11_ps_mode { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 457 | __le16 action; |
| 458 | __le16 nullpktinterval; |
| 459 | __le16 multipledtim; |
| 460 | __le16 reserved; |
| 461 | __le16 locallisteninterval; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 462 | }; |
| 463 | |
| 464 | struct PS_CMD_ConfirmSleep { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 465 | __le16 command; |
| 466 | __le16 size; |
| 467 | __le16 seqnum; |
| 468 | __le16 result; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 469 | |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 470 | __le16 action; |
| 471 | __le16 reserved1; |
| 472 | __le16 multipledtim; |
| 473 | __le16 reserved; |
| 474 | __le16 locallisteninterval; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 475 | }; |
| 476 | |
| 477 | struct cmd_ds_802_11_data_rate { |
Dan Williams | 8e3c91b | 2007-12-11 15:50:59 -0500 | [diff] [blame] | 478 | struct cmd_header hdr; |
| 479 | |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 480 | __le16 action; |
Dan Williams | 8c51276 | 2007-08-02 11:40:45 -0400 | [diff] [blame] | 481 | __le16 reserved; |
| 482 | u8 rates[MAX_RATES]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 483 | }; |
| 484 | |
| 485 | struct cmd_ds_802_11_rate_adapt_rateset { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 486 | __le16 action; |
| 487 | __le16 enablehwauto; |
| 488 | __le16 bitmap; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 489 | }; |
| 490 | |
| 491 | struct cmd_ds_802_11_ad_hoc_start { |
Dan Williams | b44898e | 2007-08-02 11:18:40 -0400 | [diff] [blame] | 492 | u8 ssid[IW_ESSID_MAX_SIZE]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 493 | u8 bsstype; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 494 | __le16 beaconperiod; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 495 | u8 dtimperiod; |
| 496 | union IEEEtypes_ssparamset ssparamset; |
| 497 | union ieeetypes_phyparamset phyparamset; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 498 | __le16 probedelay; |
Dan Williams | 0c9ca690 | 2007-08-02 10:43:44 -0400 | [diff] [blame] | 499 | __le16 capability; |
Dan Williams | 8c51276 | 2007-08-02 11:40:45 -0400 | [diff] [blame] | 500 | u8 rates[MAX_RATES]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 501 | u8 tlv_memory_size_pad[100]; |
| 502 | } __attribute__ ((packed)); |
| 503 | |
| 504 | struct adhoc_bssdesc { |
Dan Williams | 0c9ca690 | 2007-08-02 10:43:44 -0400 | [diff] [blame] | 505 | u8 bssid[6]; |
| 506 | u8 ssid[32]; |
| 507 | u8 type; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 508 | __le16 beaconperiod; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 509 | u8 dtimperiod; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 510 | __le64 timestamp; |
| 511 | __le64 localtime; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 512 | union ieeetypes_phyparamset phyparamset; |
| 513 | union IEEEtypes_ssparamset ssparamset; |
Dan Williams | 0c9ca690 | 2007-08-02 10:43:44 -0400 | [diff] [blame] | 514 | __le16 capability; |
Dan Williams | 8c51276 | 2007-08-02 11:40:45 -0400 | [diff] [blame] | 515 | u8 rates[MAX_RATES]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 516 | |
| 517 | /* DO NOT ADD ANY FIELDS TO THIS STRUCTURE. It is used below in the |
| 518 | * Adhoc join command and will cause a binary layout mismatch with |
| 519 | * the firmware |
| 520 | */ |
| 521 | } __attribute__ ((packed)); |
| 522 | |
| 523 | struct cmd_ds_802_11_ad_hoc_join { |
Dan Williams | 0c9ca690 | 2007-08-02 10:43:44 -0400 | [diff] [blame] | 524 | struct adhoc_bssdesc bss; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 525 | __le16 failtimeout; |
| 526 | __le16 probedelay; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 527 | |
| 528 | } __attribute__ ((packed)); |
| 529 | |
| 530 | struct cmd_ds_802_11_enable_rsn { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 531 | __le16 action; |
| 532 | __le16 enable; |
Dan Williams | 18c96c34 | 2007-06-18 12:01:12 -0400 | [diff] [blame] | 533 | } __attribute__ ((packed)); |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 534 | |
| 535 | struct MrvlIEtype_keyParamSet { |
| 536 | /* type ID */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 537 | __le16 type; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 538 | |
| 539 | /* length of Payload */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 540 | __le16 length; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 541 | |
| 542 | /* type of key: WEP=0, TKIP=1, AES=2 */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 543 | __le16 keytypeid; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 544 | |
| 545 | /* key control Info specific to a keytypeid */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 546 | __le16 keyinfo; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 547 | |
| 548 | /* length of key */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 549 | __le16 keylen; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 550 | |
| 551 | /* key material of size keylen */ |
| 552 | u8 key[32]; |
| 553 | }; |
| 554 | |
David Woodhouse | 6ce4fd2 | 2007-12-12 15:19:29 -0500 | [diff] [blame] | 555 | struct cmd_ds_host_sleep { |
| 556 | struct cmd_header hdr; |
| 557 | __le32 criteria; |
| 558 | uint8_t gpio; |
| 559 | uint8_t gap; |
| 560 | } __attribute__ ((packed)); |
| 561 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 562 | struct cmd_ds_802_11_key_material { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 563 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 564 | struct MrvlIEtype_keyParamSet keyParamSet[2]; |
| 565 | } __attribute__ ((packed)); |
| 566 | |
| 567 | struct cmd_ds_802_11_eeprom_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 568 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 569 | |
| 570 | /* multiple 4 */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 571 | __le16 offset; |
| 572 | __le16 bytecount; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 573 | u8 value; |
| 574 | } __attribute__ ((packed)); |
| 575 | |
| 576 | struct cmd_ds_802_11_tpc_cfg { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 577 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 578 | u8 enable; |
| 579 | s8 P0; |
| 580 | s8 P1; |
| 581 | s8 P2; |
| 582 | u8 usesnr; |
| 583 | } __attribute__ ((packed)); |
| 584 | |
| 585 | struct cmd_ds_802_11_led_ctrl { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 586 | __le16 action; |
| 587 | __le16 numled; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 588 | u8 data[256]; |
| 589 | } __attribute__ ((packed)); |
| 590 | |
| 591 | struct cmd_ds_802_11_pwr_cfg { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 592 | __le16 action; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 593 | u8 enable; |
| 594 | s8 PA_P0; |
| 595 | s8 PA_P1; |
| 596 | s8 PA_P2; |
| 597 | } __attribute__ ((packed)); |
| 598 | |
| 599 | struct cmd_ds_802_11_afc { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 600 | __le16 afc_auto; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 601 | union { |
| 602 | struct { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 603 | __le16 threshold; |
| 604 | __le16 period; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 605 | }; |
| 606 | struct { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 607 | __le16 timing_offset; /* signed */ |
| 608 | __le16 carrier_offset; /* signed */ |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 609 | }; |
| 610 | }; |
| 611 | } __attribute__ ((packed)); |
| 612 | |
| 613 | struct cmd_tx_rate_query { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 614 | __le16 txrate; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 615 | } __attribute__ ((packed)); |
| 616 | |
| 617 | struct cmd_ds_get_tsf { |
| 618 | __le64 tsfvalue; |
| 619 | } __attribute__ ((packed)); |
| 620 | |
| 621 | struct cmd_ds_bt_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 622 | __le16 action; |
| 623 | __le32 id; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 624 | u8 addr1[ETH_ALEN]; |
| 625 | u8 addr2[ETH_ALEN]; |
| 626 | } __attribute__ ((packed)); |
| 627 | |
| 628 | struct cmd_ds_fwt_access { |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 629 | __le16 action; |
| 630 | __le32 id; |
Luis Carlos Cobo | 90e8eaf | 2007-05-25 13:53:26 -0400 | [diff] [blame] | 631 | u8 valid; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 632 | u8 da[ETH_ALEN]; |
| 633 | u8 dir; |
| 634 | u8 ra[ETH_ALEN]; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 635 | __le32 ssn; |
| 636 | __le32 dsn; |
| 637 | __le32 metric; |
Luis Carlos Cobo | 90e8eaf | 2007-05-25 13:53:26 -0400 | [diff] [blame] | 638 | u8 rate; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 639 | u8 hopcount; |
| 640 | u8 ttl; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 641 | __le32 expiration; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 642 | u8 sleepmode; |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 643 | __le32 snr; |
| 644 | __le32 references; |
Luis Carlos Cobo | 90e8eaf | 2007-05-25 13:53:26 -0400 | [diff] [blame] | 645 | u8 prec[ETH_ALEN]; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 646 | } __attribute__ ((packed)); |
| 647 | |
David Woodhouse | 23a397a | 2007-12-11 18:56:42 -0500 | [diff] [blame] | 648 | |
| 649 | struct cmd_ds_mesh_config { |
| 650 | struct cmd_header hdr; |
| 651 | |
| 652 | __le16 action; |
| 653 | __le16 channel; |
| 654 | __le16 type; |
| 655 | __le16 length; |
| 656 | u8 data[128]; /* last position reserved */ |
| 657 | } __attribute__ ((packed)); |
| 658 | |
| 659 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 660 | struct cmd_ds_mesh_access { |
David Woodhouse | 301eacb | 2007-12-11 15:23:59 -0500 | [diff] [blame] | 661 | struct cmd_header hdr; |
| 662 | |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 663 | __le16 action; |
| 664 | __le32 data[32]; /* last position reserved */ |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 665 | } __attribute__ ((packed)); |
| 666 | |
Javier Cardona | 0601e7e | 2007-05-25 12:12:06 -0400 | [diff] [blame] | 667 | /* Number of stats counters returned by the firmware */ |
| 668 | #define MESH_STATS_NUM 8 |
| 669 | |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 670 | struct cmd_ds_command { |
| 671 | /* command header */ |
David Woodhouse | 981f187 | 2007-05-25 23:36:54 -0400 | [diff] [blame] | 672 | __le16 command; |
| 673 | __le16 size; |
| 674 | __le16 seqnum; |
| 675 | __le16 result; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 676 | |
| 677 | /* command Body */ |
| 678 | union { |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 679 | struct cmd_ds_802_11_ps_mode psmode; |
| 680 | struct cmd_ds_802_11_scan scan; |
| 681 | struct cmd_ds_802_11_scan_rsp scanresp; |
| 682 | struct cmd_ds_mac_control macctrl; |
| 683 | struct cmd_ds_802_11_associate associate; |
| 684 | struct cmd_ds_802_11_deauthenticate deauth; |
| 685 | struct cmd_ds_802_11_set_wep wep; |
| 686 | struct cmd_ds_802_11_ad_hoc_start ads; |
| 687 | struct cmd_ds_802_11_reset reset; |
| 688 | struct cmd_ds_802_11_ad_hoc_result result; |
| 689 | struct cmd_ds_802_11_get_log glog; |
| 690 | struct cmd_ds_802_11_authenticate auth; |
| 691 | struct cmd_ds_802_11_get_stat gstat; |
| 692 | struct cmd_ds_802_3_get_stat gstat_8023; |
| 693 | struct cmd_ds_802_11_snmp_mib smib; |
| 694 | struct cmd_ds_802_11_rf_tx_power txp; |
| 695 | struct cmd_ds_802_11_rf_antenna rant; |
Luis Carlos Cobo | 965f8bbc | 2007-08-02 13:16:55 -0400 | [diff] [blame] | 696 | struct cmd_ds_802_11_monitor_mode monitor; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 697 | struct cmd_ds_802_11_rate_adapt_rateset rateset; |
| 698 | struct cmd_ds_mac_multicast_adr madr; |
| 699 | struct cmd_ds_802_11_ad_hoc_join adj; |
| 700 | struct cmd_ds_802_11_radio_control radio; |
| 701 | struct cmd_ds_802_11_rf_channel rfchannel; |
| 702 | struct cmd_ds_802_11_rssi rssi; |
| 703 | struct cmd_ds_802_11_rssi_rsp rssirsp; |
| 704 | struct cmd_ds_802_11_disassociate dassociate; |
| 705 | struct cmd_ds_802_11_mac_address macadd; |
| 706 | struct cmd_ds_802_11_enable_rsn enbrsn; |
| 707 | struct cmd_ds_802_11_key_material keymaterial; |
| 708 | struct cmd_ds_mac_reg_access macreg; |
| 709 | struct cmd_ds_bbp_reg_access bbpreg; |
| 710 | struct cmd_ds_rf_reg_access rfreg; |
| 711 | struct cmd_ds_802_11_eeprom_access rdeeprom; |
| 712 | |
| 713 | struct cmd_ds_802_11d_domain_info domaininfo; |
| 714 | struct cmd_ds_802_11d_domain_info domaininforesp; |
| 715 | |
| 716 | struct cmd_ds_802_11_sleep_params sleep_params; |
| 717 | struct cmd_ds_802_11_inactivity_timeout inactivity_timeout; |
| 718 | struct cmd_ds_802_11_tpc_cfg tpccfg; |
| 719 | struct cmd_ds_802_11_pwr_cfg pwrcfg; |
| 720 | struct cmd_ds_802_11_afc afc; |
| 721 | struct cmd_ds_802_11_led_ctrl ledgpio; |
| 722 | |
| 723 | struct cmd_tx_rate_query txrate; |
| 724 | struct cmd_ds_bt_access bt; |
| 725 | struct cmd_ds_fwt_access fwt; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 726 | struct cmd_ds_get_tsf gettsf; |
| 727 | struct cmd_ds_802_11_subscribe_event subscribe_event; |
Brajesh Dave | 96287ac | 2007-11-20 17:44:28 -0500 | [diff] [blame] | 728 | struct cmd_ds_802_11_beacon_control bcn_ctrl; |
Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 729 | } params; |
| 730 | } __attribute__ ((packed)); |
| 731 | |
| 732 | #endif |