2007-02-10 14:25:27 +00:00
|
|
|
/*
|
|
|
|
* This file contains the function prototypes, data structure
|
|
|
|
* and defines for all the host/station commands
|
|
|
|
*/
|
2007-11-15 23:05:47 +00:00
|
|
|
#ifndef _LBS_HOSTCMD_H
|
|
|
|
#define _LBS_HOSTCMD_H
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
#include <linux/wireless.h>
|
|
|
|
#include "11d.h"
|
|
|
|
#include "types.h"
|
|
|
|
|
|
|
|
/* 802.11-related definitions */
|
|
|
|
|
|
|
|
/* TxPD descriptor */
|
|
|
|
struct txpd {
|
|
|
|
/* Current Tx packet status */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 tx_status;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* Tx control */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 tx_control;
|
|
|
|
__le32 tx_packet_location;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* Tx packet length */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 tx_packet_length;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* First 2 byte of destination MAC address */
|
|
|
|
u8 tx_dest_addr_high[2];
|
|
|
|
/* Last 4 byte of destination MAC address */
|
|
|
|
u8 tx_dest_addr_low[4];
|
|
|
|
/* Pkt Priority */
|
|
|
|
u8 priority;
|
|
|
|
/* Pkt Trasnit Power control */
|
|
|
|
u8 powermgmt;
|
|
|
|
/* Amount of time the packet has been queued in the driver (units = 2ms) */
|
|
|
|
u8 pktdelay_2ms;
|
|
|
|
/* reserved */
|
|
|
|
u8 reserved1;
|
|
|
|
};
|
|
|
|
|
|
|
|
/* RxPD Descriptor */
|
|
|
|
struct rxpd {
|
|
|
|
/* Current Rx packet status */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 status;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* SNR */
|
|
|
|
u8 snr;
|
|
|
|
|
|
|
|
/* Tx control */
|
|
|
|
u8 rx_control;
|
|
|
|
|
|
|
|
/* Pkt length */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 pkt_len;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Noise Floor */
|
|
|
|
u8 nf;
|
|
|
|
|
|
|
|
/* Rx Packet Rate */
|
|
|
|
u8 rx_rate;
|
|
|
|
|
|
|
|
/* Pkt addr */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 pkt_ptr;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Next Rx RxPD addr */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 next_rxpd_ptr;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Pkt Priority */
|
|
|
|
u8 priority;
|
|
|
|
u8 reserved[3];
|
|
|
|
};
|
|
|
|
|
2007-12-11 17:33:30 +00:00
|
|
|
struct cmd_header {
|
|
|
|
__le16 command;
|
|
|
|
__le16 size;
|
|
|
|
__le16 seqnum;
|
|
|
|
__le16 result;
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ctrl_node {
|
|
|
|
struct list_head list;
|
2007-12-15 09:22:52 +00:00
|
|
|
int result;
|
2007-12-05 16:58:11 +00:00
|
|
|
/* command response */
|
2007-12-11 17:33:30 +00:00
|
|
|
int (*callback)(struct lbs_private *, unsigned long, struct cmd_header *);
|
2007-12-10 18:36:10 +00:00
|
|
|
unsigned long callback_arg;
|
2007-12-05 16:58:11 +00:00
|
|
|
/* command data */
|
2007-12-11 18:49:39 +00:00
|
|
|
struct cmd_header *cmdbuf;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* wait queue */
|
|
|
|
u16 cmdwaitqwoken;
|
|
|
|
wait_queue_head_t cmdwait_q;
|
|
|
|
};
|
|
|
|
|
2007-08-02 14:45:55 +00:00
|
|
|
/* Generic structure to hold all key types. */
|
|
|
|
struct enc_key {
|
|
|
|
u16 len;
|
2007-11-15 23:05:47 +00:00
|
|
|
u16 flags; /* KEY_INFO_* from defs.h */
|
|
|
|
u16 type; /* KEY_TYPE_* from defs.h */
|
2007-08-02 14:45:55 +00:00
|
|
|
u8 key[32];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
2007-11-15 23:05:47 +00:00
|
|
|
/* lbs_offset_value */
|
|
|
|
struct lbs_offset_value {
|
2007-02-10 14:25:27 +00:00
|
|
|
u32 offset;
|
|
|
|
u32 value;
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Define general data structure */
|
|
|
|
/* cmd_DS_GEN */
|
|
|
|
struct cmd_ds_gen {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 command;
|
|
|
|
__le16 size;
|
|
|
|
__le16 seqnum;
|
|
|
|
__le16 result;
|
2007-12-05 16:58:11 +00:00
|
|
|
void *cmdresp[0];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#define S_DS_GEN sizeof(struct cmd_ds_gen)
|
2007-12-05 16:58:11 +00:00
|
|
|
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
/*
|
2007-08-02 15:31:18 +00:00
|
|
|
* Define data structure for CMD_GET_HW_SPEC
|
2007-02-10 14:25:27 +00:00
|
|
|
* This structure defines the response for the GET_HW_SPEC command
|
|
|
|
*/
|
|
|
|
struct cmd_ds_get_hw_spec {
|
2007-12-11 17:42:16 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
/* HW Interface version number */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 hwifversion;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* HW version number */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 version;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* Max number of TxPD FW can handle */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 nr_txpd;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* Max no of Multicast address */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 nr_mcast_adr;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* MAC address */
|
|
|
|
u8 permanentaddr[6];
|
|
|
|
|
|
|
|
/* region Code */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 regioncode;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Number of antenna used */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 nr_antenna;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
2008-01-16 14:55:22 +00:00
|
|
|
/* FW release number, example 0x01030304 = 2.3.4p1 */
|
|
|
|
__le32 fwrelease;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Base Address of TxPD queue */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 wcb_base;
|
2007-02-10 14:25:27 +00:00
|
|
|
/* Read Pointer of RxPd queue */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 rxpd_rdptr;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Write Pointer of RxPd queue */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 rxpd_wrptr;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/*FW/HW capability */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 fwcapinfo;
|
2007-02-10 14:25:27 +00:00
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_reset {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_subscribe_event {
|
2007-12-18 07:01:37 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 events;
|
2007-11-26 09:07:14 +00:00
|
|
|
|
|
|
|
/* A TLV to the CMD_802_11_SUBSCRIBE_EVENT command can contain a
|
|
|
|
* number of TLVs. From the v5.1 manual, those TLVs would add up to
|
|
|
|
* 40 bytes. However, future firmware might add additional TLVs, so I
|
|
|
|
* bump this up a bit.
|
|
|
|
*/
|
2007-12-18 07:01:37 +00:00
|
|
|
uint8_t tlv[128];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
/*
|
|
|
|
* This scan handle Country Information IE(802.11d compliant)
|
2007-08-02 15:31:18 +00:00
|
|
|
* Define data structure for CMD_802_11_SCAN
|
2007-02-10 14:25:27 +00:00
|
|
|
*/
|
|
|
|
struct cmd_ds_802_11_scan {
|
2008-03-03 11:18:03 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
|
|
|
uint8_t bsstype;
|
|
|
|
uint8_t bssid[ETH_ALEN];
|
|
|
|
uint8_t tlvbuffer[0];
|
2007-02-10 14:25:27 +00:00
|
|
|
#if 0
|
|
|
|
mrvlietypes_ssidparamset_t ssidParamSet;
|
|
|
|
mrvlietypes_chanlistparamset_t ChanListParamSet;
|
|
|
|
mrvlietypes_ratesparamset_t OpRateSet;
|
|
|
|
#endif
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_scan_rsp {
|
2008-03-03 11:18:03 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 bssdescriptsize;
|
2008-03-03 11:18:03 +00:00
|
|
|
uint8_t nr_sets;
|
|
|
|
uint8_t bssdesc_and_tlvbuffer[0];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_get_log {
|
2008-03-17 11:45:58 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 mcasttxframe;
|
|
|
|
__le32 failed;
|
|
|
|
__le32 retry;
|
|
|
|
__le32 multiretry;
|
|
|
|
__le32 framedup;
|
|
|
|
__le32 rtssuccess;
|
|
|
|
__le32 rtsfailure;
|
|
|
|
__le32 ackfailure;
|
|
|
|
__le32 rxfrag;
|
|
|
|
__le32 mcastrxframe;
|
|
|
|
__le32 fcserror;
|
|
|
|
__le32 txframe;
|
|
|
|
__le32 wepundecryptable;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_mac_control {
|
2008-03-12 15:05:40 +00:00
|
|
|
struct cmd_header hdr;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2008-03-12 15:05:40 +00:00
|
|
|
u16 reserved;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_mac_multicast_adr {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 nr_of_adrs;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 maclist[ETH_ALEN * MRVDRV_MAX_MULTICAST_LIST_SIZE];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_authenticate {
|
|
|
|
u8 macaddr[ETH_ALEN];
|
|
|
|
u8 authtype;
|
|
|
|
u8 reserved[10];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_deauthenticate {
|
|
|
|
u8 macaddr[6];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reasoncode;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_associate {
|
|
|
|
u8 peerstaaddr[6];
|
2007-08-02 14:43:44 +00:00
|
|
|
__le16 capability;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 listeninterval;
|
|
|
|
__le16 bcnperiod;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 dtimperiod;
|
|
|
|
|
|
|
|
#if 0
|
|
|
|
mrvlietypes_ssidparamset_t ssidParamSet;
|
|
|
|
mrvlietypes_phyparamset_t phyparamset;
|
|
|
|
mrvlietypes_ssparamset_t ssparamset;
|
|
|
|
mrvlietypes_ratesparamset_t ratesParamSet;
|
|
|
|
#endif
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_disassociate {
|
|
|
|
u8 destmacaddr[6];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reasoncode;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_associate_rsp {
|
|
|
|
struct ieeetypes_assocrsp assocRsp;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_ad_hoc_result {
|
2007-08-02 15:18:23 +00:00
|
|
|
u8 pad[3];
|
|
|
|
u8 bssid[ETH_ALEN];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_set_wep {
|
2007-12-18 05:18:05 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
/* ACT_ADD, ACT_REMOVE or ACT_ENABLE */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* key Index selected for Tx */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 keyindex;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* 40, 128bit or TXWEP */
|
2007-12-18 05:18:05 +00:00
|
|
|
uint8_t keytype[4];
|
|
|
|
uint8_t keymaterial[4][16];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_3_get_stat {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 xmitok;
|
|
|
|
__le32 rcvok;
|
|
|
|
__le32 xmiterror;
|
|
|
|
__le32 rcverror;
|
|
|
|
__le32 rcvnobuffer;
|
|
|
|
__le32 rcvcrcerror;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_get_stat {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 txfragmentcnt;
|
|
|
|
__le32 mcasttxframecnt;
|
|
|
|
__le32 failedcnt;
|
|
|
|
__le32 retrycnt;
|
|
|
|
__le32 Multipleretrycnt;
|
|
|
|
__le32 rtssuccesscnt;
|
|
|
|
__le32 rtsfailurecnt;
|
|
|
|
__le32 ackfailurecnt;
|
|
|
|
__le32 frameduplicatecnt;
|
|
|
|
__le32 rxfragmentcnt;
|
|
|
|
__le32 mcastrxframecnt;
|
|
|
|
__le32 fcserrorcnt;
|
|
|
|
__le32 bcasttxframecnt;
|
|
|
|
__le32 bcastrxframecnt;
|
|
|
|
__le32 txbeacon;
|
|
|
|
__le32 rxbeacon;
|
|
|
|
__le32 wepundecryptable;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_snmp_mib {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 querytype;
|
|
|
|
__le16 oid;
|
|
|
|
__le16 bufsize;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 value[128];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_mac_reg_map {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 buffersize;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 regmap[128];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reserved;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_bbp_reg_map {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 buffersize;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 regmap[128];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reserved;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_rf_reg_map {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 buffersize;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 regmap[64];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reserved;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_mac_reg_access {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 offset;
|
|
|
|
__le32 value;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_bbp_reg_access {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 offset;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 value;
|
|
|
|
u8 reserved[3];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_rf_reg_access {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 offset;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 value;
|
|
|
|
u8 reserved[3];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_radio_control {
|
2007-12-18 03:43:48 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 control;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
2007-11-20 22:44:28 +00:00
|
|
|
struct cmd_ds_802_11_beacon_control {
|
|
|
|
__le16 action;
|
|
|
|
__le16 beacon_enable;
|
|
|
|
__le16 beacon_period;
|
|
|
|
};
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_802_11_sleep_params {
|
2007-12-18 04:48:31 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
/* ACT_GET/ACT_SET */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Sleep clock error in ppm */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 error;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Wakeup offset in usec */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 offset;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Clock stabilization time in usec */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 stabletime;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* control periodic calibration */
|
2007-12-18 04:48:31 +00:00
|
|
|
uint8_t calcontrol;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* control the use of external sleep clock */
|
2007-12-18 04:48:31 +00:00
|
|
|
uint8_t externalsleepclk;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* reserved field, should be set to zero */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reserved;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_inactivity_timeout {
|
2007-12-18 04:04:37 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
/* ACT_GET/ACT_SET */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Inactivity timeout in msec */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 timeout;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rf_channel {
|
2007-12-11 21:54:15 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-12-11 21:54:15 +00:00
|
|
|
__le16 channel;
|
|
|
|
__le16 rftype; /* unused */
|
|
|
|
__le16 reserved; /* unused */
|
|
|
|
u8 channellist[32]; /* unused */
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rssi {
|
|
|
|
/* weighting factor */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 N;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 reserved_0;
|
|
|
|
__le16 reserved_1;
|
|
|
|
__le16 reserved_2;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rssi_rsp {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 SNR;
|
|
|
|
__le16 noisefloor;
|
|
|
|
__le16 avgSNR;
|
|
|
|
__le16 avgnoisefloor;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_mac_address {
|
2008-03-26 08:58:32 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 macadd[ETH_ALEN];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rf_tx_power {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 currentlevel;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rf_antenna {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* Number of antennas or 0xffff(diversity) */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 antennamode;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
};
|
|
|
|
|
2007-08-02 17:16:55 +00:00
|
|
|
struct cmd_ds_802_11_monitor_mode {
|
2007-12-07 15:30:44 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 mode;
|
2007-08-02 17:16:55 +00:00
|
|
|
};
|
|
|
|
|
2007-08-02 17:19:24 +00:00
|
|
|
struct cmd_ds_set_boot2_ver {
|
2007-12-11 17:33:30 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-12-07 15:30:44 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 version;
|
2007-08-02 17:19:24 +00:00
|
|
|
};
|
|
|
|
|
2007-12-17 02:43:40 +00:00
|
|
|
struct cmd_ds_802_11_fw_wake_method {
|
|
|
|
struct cmd_header hdr;
|
|
|
|
|
|
|
|
__le16 action;
|
|
|
|
__le16 method;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_sleep_period {
|
|
|
|
struct cmd_header hdr;
|
|
|
|
|
|
|
|
__le16 action;
|
|
|
|
__le16 period;
|
|
|
|
};
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_802_11_ps_mode {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 nullpktinterval;
|
|
|
|
__le16 multipledtim;
|
|
|
|
__le16 reserved;
|
|
|
|
__le16 locallisteninterval;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
2008-03-26 12:22:11 +00:00
|
|
|
struct cmd_confirm_sleep {
|
|
|
|
struct cmd_header hdr;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2008-03-26 12:22:11 +00:00
|
|
|
__le16 nullpktinterval;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 multipledtim;
|
|
|
|
__le16 reserved;
|
|
|
|
__le16 locallisteninterval;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_data_rate {
|
2007-12-11 20:50:59 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-08-02 15:40:45 +00:00
|
|
|
__le16 reserved;
|
|
|
|
u8 rates[MAX_RATES];
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_rate_adapt_rateset {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 enablehwauto;
|
|
|
|
__le16 bitmap;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_ad_hoc_start {
|
2007-08-02 15:18:40 +00:00
|
|
|
u8 ssid[IW_ESSID_MAX_SIZE];
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 bsstype;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 beaconperiod;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 dtimperiod;
|
|
|
|
union IEEEtypes_ssparamset ssparamset;
|
|
|
|
union ieeetypes_phyparamset phyparamset;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 probedelay;
|
2007-08-02 14:43:44 +00:00
|
|
|
__le16 capability;
|
2007-08-02 15:40:45 +00:00
|
|
|
u8 rates[MAX_RATES];
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 tlv_memory_size_pad[100];
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct adhoc_bssdesc {
|
2007-08-02 14:43:44 +00:00
|
|
|
u8 bssid[6];
|
|
|
|
u8 ssid[32];
|
|
|
|
u8 type;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 beaconperiod;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 dtimperiod;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le64 timestamp;
|
|
|
|
__le64 localtime;
|
2007-02-10 14:25:27 +00:00
|
|
|
union ieeetypes_phyparamset phyparamset;
|
|
|
|
union IEEEtypes_ssparamset ssparamset;
|
2007-08-02 14:43:44 +00:00
|
|
|
__le16 capability;
|
2007-08-02 15:40:45 +00:00
|
|
|
u8 rates[MAX_RATES];
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* DO NOT ADD ANY FIELDS TO THIS STRUCTURE. It is used below in the
|
|
|
|
* Adhoc join command and will cause a binary layout mismatch with
|
|
|
|
* the firmware
|
|
|
|
*/
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_ad_hoc_join {
|
2007-08-02 14:43:44 +00:00
|
|
|
struct adhoc_bssdesc bss;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 failtimeout;
|
|
|
|
__le16 probedelay;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_enable_rsn {
|
2007-12-18 05:47:17 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 enable;
|
2007-06-18 16:01:12 +00:00
|
|
|
} __attribute__ ((packed));
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
struct MrvlIEtype_keyParamSet {
|
|
|
|
/* type ID */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 type;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* length of Payload */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 length;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* type of key: WEP=0, TKIP=1, AES=2 */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 keytypeid;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* key control Info specific to a keytypeid */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 keyinfo;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* length of key */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 keylen;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* key material of size keylen */
|
|
|
|
u8 key[32];
|
|
|
|
};
|
|
|
|
|
2007-12-12 20:19:29 +00:00
|
|
|
struct cmd_ds_host_sleep {
|
|
|
|
struct cmd_header hdr;
|
|
|
|
__le32 criteria;
|
|
|
|
uint8_t gpio;
|
|
|
|
uint8_t gap;
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_802_11_key_material {
|
2008-03-03 11:15:39 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
struct MrvlIEtype_keyParamSet keyParamSet[2];
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_eeprom_access {
|
2008-03-26 09:03:48 +00:00
|
|
|
struct cmd_header hdr;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 offset;
|
2008-03-26 09:03:48 +00:00
|
|
|
__le16 len;
|
|
|
|
/* firmware says it returns a maximum of 20 bytes */
|
|
|
|
#define LBS_EEPROM_READ_LEN 20
|
|
|
|
u8 value[LBS_EEPROM_READ_LEN];
|
2007-02-10 14:25:27 +00:00
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_tpc_cfg {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 enable;
|
|
|
|
s8 P0;
|
|
|
|
s8 P1;
|
|
|
|
s8 P2;
|
|
|
|
u8 usesnr;
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_led_ctrl {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le16 numled;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 data[256];
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_afc {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 afc_auto;
|
2007-02-10 14:25:27 +00:00
|
|
|
union {
|
|
|
|
struct {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 threshold;
|
|
|
|
__le16 period;
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
struct {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 timing_offset; /* signed */
|
|
|
|
__le16 carrier_offset; /* signed */
|
2007-02-10 14:25:27 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_tx_rate_query {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 txrate;
|
2007-02-10 14:25:27 +00:00
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_get_tsf {
|
|
|
|
__le64 tsfvalue;
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_bt_access {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le32 id;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 addr1[ETH_ALEN];
|
|
|
|
u8 addr2[ETH_ALEN];
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
struct cmd_ds_fwt_access {
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le32 id;
|
2007-05-25 17:53:26 +00:00
|
|
|
u8 valid;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 da[ETH_ALEN];
|
|
|
|
u8 dir;
|
|
|
|
u8 ra[ETH_ALEN];
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 ssn;
|
|
|
|
__le32 dsn;
|
|
|
|
__le32 metric;
|
2007-05-25 17:53:26 +00:00
|
|
|
u8 rate;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 hopcount;
|
|
|
|
u8 ttl;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 expiration;
|
2007-02-10 14:25:27 +00:00
|
|
|
u8 sleepmode;
|
2007-05-26 03:36:54 +00:00
|
|
|
__le32 snr;
|
|
|
|
__le32 references;
|
2007-05-25 17:53:26 +00:00
|
|
|
u8 prec[ETH_ALEN];
|
2007-02-10 14:25:27 +00:00
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
2007-12-11 23:56:42 +00:00
|
|
|
|
|
|
|
struct cmd_ds_mesh_config {
|
|
|
|
struct cmd_header hdr;
|
|
|
|
|
|
|
|
__le16 action;
|
|
|
|
__le16 channel;
|
|
|
|
__le16 type;
|
|
|
|
__le16 length;
|
|
|
|
u8 data[128]; /* last position reserved */
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_mesh_access {
|
2007-12-11 20:23:59 +00:00
|
|
|
struct cmd_header hdr;
|
|
|
|
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 action;
|
|
|
|
__le32 data[32]; /* last position reserved */
|
2007-02-10 14:25:27 +00:00
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
2007-05-25 16:12:06 +00:00
|
|
|
/* Number of stats counters returned by the firmware */
|
|
|
|
#define MESH_STATS_NUM 8
|
|
|
|
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_command {
|
|
|
|
/* command header */
|
2007-05-26 03:36:54 +00:00
|
|
|
__le16 command;
|
|
|
|
__le16 size;
|
|
|
|
__le16 seqnum;
|
|
|
|
__le16 result;
|
2007-02-10 14:25:27 +00:00
|
|
|
|
|
|
|
/* command Body */
|
|
|
|
union {
|
|
|
|
struct cmd_ds_802_11_ps_mode psmode;
|
|
|
|
struct cmd_ds_802_11_associate associate;
|
|
|
|
struct cmd_ds_802_11_deauthenticate deauth;
|
|
|
|
struct cmd_ds_802_11_ad_hoc_start ads;
|
|
|
|
struct cmd_ds_802_11_reset reset;
|
|
|
|
struct cmd_ds_802_11_ad_hoc_result result;
|
|
|
|
struct cmd_ds_802_11_authenticate auth;
|
|
|
|
struct cmd_ds_802_11_get_stat gstat;
|
|
|
|
struct cmd_ds_802_3_get_stat gstat_8023;
|
|
|
|
struct cmd_ds_802_11_snmp_mib smib;
|
|
|
|
struct cmd_ds_802_11_rf_tx_power txp;
|
|
|
|
struct cmd_ds_802_11_rf_antenna rant;
|
2007-08-02 17:16:55 +00:00
|
|
|
struct cmd_ds_802_11_monitor_mode monitor;
|
2007-02-10 14:25:27 +00:00
|
|
|
struct cmd_ds_802_11_rate_adapt_rateset rateset;
|
|
|
|
struct cmd_ds_mac_multicast_adr madr;
|
|
|
|
struct cmd_ds_802_11_ad_hoc_join adj;
|
|
|
|
struct cmd_ds_802_11_rssi rssi;
|
|
|
|
struct cmd_ds_802_11_rssi_rsp rssirsp;
|
|
|
|
struct cmd_ds_802_11_disassociate dassociate;
|
|
|
|
struct cmd_ds_mac_reg_access macreg;
|
|
|
|
struct cmd_ds_bbp_reg_access bbpreg;
|
|
|
|
struct cmd_ds_rf_reg_access rfreg;
|
|
|
|
|
|
|
|
struct cmd_ds_802_11d_domain_info domaininfo;
|
|
|
|
struct cmd_ds_802_11d_domain_info domaininforesp;
|
|
|
|
|
|
|
|
struct cmd_ds_802_11_tpc_cfg tpccfg;
|
|
|
|
struct cmd_ds_802_11_afc afc;
|
|
|
|
struct cmd_ds_802_11_led_ctrl ledgpio;
|
|
|
|
|
|
|
|
struct cmd_tx_rate_query txrate;
|
|
|
|
struct cmd_ds_bt_access bt;
|
|
|
|
struct cmd_ds_fwt_access fwt;
|
|
|
|
struct cmd_ds_get_tsf gettsf;
|
2007-11-20 22:44:28 +00:00
|
|
|
struct cmd_ds_802_11_beacon_control bcn_ctrl;
|
2007-02-10 14:25:27 +00:00
|
|
|
} params;
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
|
|
|
|
#endif
|