summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNitesh Shah <niteshs@qti.qualcomm.com>2016-07-21 17:02:43 +0530
committerAnjaneedevi Kapparapu <akappa@codeaurora.org>2016-07-28 14:36:57 +0530
commitae876ff6c6f67d5264464f90d5abc83b96d81967 (patch)
tree3b7d6d81af6bd3ea6370eb3913b15b6a9b0cfed7
parent1c91c3ddf1f88c7f9aa4b4994b4dd5e9a0a6a127 (diff)
qcacld-2.0: CL 1597848 - update fw common interface files
Adding WMI defs for pdev and peer GET_ANTDIV_STATUS_CMD, ANTDIV_INFO_EVENT msgs. Change-Id: Iad3c57f0b4e10e68c86cef175b8cadcfd9e7fe1e CRs-fixed: 865207
-rw-r--r--CORE/SERVICES/COMMON/wmi_tlv_defs.h30
-rw-r--r--CORE/SERVICES/COMMON/wmi_unified.h118
-rw-r--r--CORE/SERVICES/COMMON/wmi_version.h2
-rw-r--r--CORE/SERVICES/WMI/wmi_unified.c2
4 files changed, 151 insertions, 1 deletions
diff --git a/CORE/SERVICES/COMMON/wmi_tlv_defs.h b/CORE/SERVICES/COMMON/wmi_tlv_defs.h
index ca0c3fdcc0e5..dcb580ccbdf2 100644
--- a/CORE/SERVICES/COMMON/wmi_tlv_defs.h
+++ b/CORE/SERVICES/COMMON/wmi_tlv_defs.h
@@ -725,6 +725,11 @@ typedef enum {
WMITLV_TAG_STRUC_WMI_PDEV_SET_WAKEUP_CONFIG_CMDID_fixed_param,
WMITLV_TAG_STRUC_wmi_tlv_buf_len_param,
WMITLV_TAG_STRUC_wmi_service_available_event_fixed_param,
+ WMITLV_TAG_STRUC_wmi_peer_antdiv_info_req_cmd_fixed_param,
+ WMITLV_TAG_STRUC_wmi_peer_antdiv_info_event_fixed_param,
+ WMITLV_TAG_STRUC_wmi_peer_antdiv_info,
+ WMITLV_TAG_STRUC_wmi_pdev_get_antdiv_status_cmd_fixed_param,
+ WMITLV_TAG_STRUC_wmi_pdev_antdiv_status_event_fixed_param,
} WMITLV_TAG_ID;
/*
@@ -1021,6 +1026,8 @@ typedef enum {
OP(WMI_PDEV_SET_REORDER_TIMEOUT_VAL_CMDID) \
OP(WMI_PEER_SET_RX_BLOCKSIZE_CMDID) \
OP(WMI_PDEV_SET_WAKEUP_CONFIG_CMDID) \
+ OP(WMI_PEER_ANTDIV_INFO_REQ_CMDID) \
+ OP(WMI_PDEV_GET_ANTDIV_STATUS_CMDID) \
/* add new CMD_LIST elements above this line */
/*
@@ -1175,6 +1182,8 @@ typedef enum {
OP(WMI_MGMT_TX_BUNDLE_COMPLETION_EVENTID) \
OP(WMI_READ_DATA_FROM_FLASH_EVENTID) \
OP(WMI_SERVICE_AVAILABLE_EVENTID) \
+ OP(WMI_PEER_ANTDIV_INFO_EVENTID) \
+ OP(WMI_PDEV_ANTDIV_STATUS_EVENTID) \
/* add new EVT_LIST elements above this line */
@@ -2330,6 +2339,12 @@ WMITLV_CREATE_PARAM_STRUC(WMI_BATCH_SCAN_ENABLE_CMDID);
WMITLV_CREATE_PARAM_STRUC(WMI_PEER_INFO_REQ_CMDID);
+#define WMITLV_TABLE_WMI_PEER_ANTDIV_INFO_REQ_CMDID(id, op, buf, len) \
+ WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_STRUC_wmi_peer_antdiv_info_req_cmd_fixed_param, \
+ wmi_peer_antdiv_info_req_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX)
+
+WMITLV_CREATE_PARAM_STRUC(WMI_PEER_ANTDIV_INFO_REQ_CMDID);
+
#define WMITLV_TABLE_WMI_RMC_SET_MODE_CMDID(id,op,buf,len) \
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_rmc_set_mode_cmd_fixed_param, \
wmi_rmc_set_mode_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX)
@@ -2536,6 +2551,11 @@ WMITLV_CREATE_PARAM_STRUC(WMI_D0_WOW_ENABLE_DISABLE_CMDID);
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_pdev_get_temperature_cmd_fixed_param, wmi_pdev_get_temperature_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX)
WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_GET_TEMPERATURE_CMDID);
+/* Pdev get ANT DIV feature status Cmd */
+#define WMITLV_TABLE_WMI_PDEV_GET_ANTDIV_STATUS_CMDID(id, op, buf, len) \
+ WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_STRUC_wmi_pdev_get_antdiv_status_cmd_fixed_param, wmi_pdev_get_antdiv_status_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX)
+WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_GET_ANTDIV_STATUS_CMDID);
+
/* Set antenna diversity Cmd */
#define WMITLV_TABLE_WMI_SET_ANTENNA_DIVERSITY_CMDID(id,op,buf,len) \
WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_STRUC_wmi_pdev_set_antenna_diversity_cmd_fixed_param, wmi_pdev_set_antenna_diversity_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX)
@@ -3444,6 +3464,11 @@ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_peer_info_event_fixed_param, wmi
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_peer_info, peer_info, WMITLV_SIZE_VAR)
WMITLV_CREATE_PARAM_STRUC(WMI_PEER_INFO_EVENTID);
+#define WMITLV_TABLE_WMI_PEER_ANTDIV_INFO_EVENTID(id, op, buf, len) \
+ WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_STRUC_wmi_peer_antdiv_info_event_fixed_param, wmi_peer_antdiv_info_event_fixed_param, fixed_param, WMITLV_SIZE_FIX) \
+ WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_ARRAY_STRUC, wmi_peer_antdiv_info, peer_info, WMITLV_SIZE_VAR)
+WMITLV_CREATE_PARAM_STRUC(WMI_PEER_ANTDIV_INFO_EVENTID);
+
#define WMITLV_TABLE_WMI_PEER_TX_FAIL_CNT_THR_EVENTID(id,op,buf,len) \
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_peer_tx_fail_cnt_thr_event_fixed_param, wmi_peer_tx_fail_cnt_thr_event_fixed_param, fixed_param, WMITLV_SIZE_FIX)
WMITLV_CREATE_PARAM_STRUC(WMI_PEER_TX_FAIL_CNT_THR_EVENTID);
@@ -3601,6 +3626,11 @@ WMITLV_CREATE_PARAM_STRUC(WMI_D0_WOW_DISABLE_ACK_EVENTID);
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_pdev_temperature_event_fixed_param, wmi_pdev_temperature_event_fixed_param, fixed_param, WMITLV_SIZE_FIX)
WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_TEMPERATURE_EVENTID);
+/* Pdev get ANT DIV feature status event */
+#define WMITLV_TABLE_WMI_PDEV_ANTDIV_STATUS_EVENTID(id, op, buf, len) \
+ WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_STRUC_wmi_pdev_antdiv_status_event_fixed_param, wmi_pdev_antdiv_status_event_fixed_param, fixed_param, WMITLV_SIZE_FIX)
+WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_ANTDIV_STATUS_EVENTID);
+
/* mDNS offload stats event */
#define WMITLV_TABLE_WMI_MDNS_STATS_EVENTID(id,op,buf,len) \
WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_mdns_stats_event_fixed_param, wmi_mdns_stats_event_fixed_param, fixed_param, WMITLV_SIZE_FIX)
diff --git a/CORE/SERVICES/COMMON/wmi_unified.h b/CORE/SERVICES/COMMON/wmi_unified.h
index ae16dce2a7e6..d76a353ec816 100644
--- a/CORE/SERVICES/COMMON/wmi_unified.h
+++ b/CORE/SERVICES/COMMON/wmi_unified.h
@@ -347,6 +347,8 @@ typedef enum {
WMI_PDEV_SET_REORDER_TIMEOUT_VAL_CMDID,
/** WMI command for WOW gpio and type */
WMI_PDEV_SET_WAKEUP_CONFIG_CMDID,
+ /* Get current ANT's per chain's RSSI info */
+ WMI_PDEV_GET_ANTDIV_STATUS_CMDID,
/* VDEV (virtual device) specific commands */
/** vdev create */
@@ -446,6 +448,11 @@ typedef enum {
WMI_PEER_REORDER_QUEUE_REMOVE_CMDID,
/** specify a limit for rx A-MPDU block size */
WMI_PEER_SET_RX_BLOCKSIZE_CMDID,
+ /**
+ * request peer antdiv info from FW. FW shall respond with
+ * PEER_ANTDIV_INFO_EVENTID
+ */
+ WMI_PEER_ANTDIV_INFO_REQ_CMDID,
/* beacon/management specific commands */
@@ -1031,6 +1038,8 @@ typedef enum {
WMI_PDEV_SET_HW_MODE_RESP_EVENTID,
WMI_PDEV_HW_MODE_TRANSITION_EVENTID,
WMI_PDEV_SET_MAC_CONFIG_RESP_EVENTID,
+ /** Report ANT DIV feature's status */
+ WMI_PDEV_ANTDIV_STATUS_EVENTID,
/* VDEV specific events */
/** VDEV started event in response to VDEV_START request */
@@ -1084,6 +1093,8 @@ typedef enum {
WMI_PEER_RATECODE_LIST_EVENTID,
WMI_WDS_PEER_EVENTID,
WMI_PEER_STA_PS_STATECHG_EVENTID,
+ /** Peer Ant Div Info Event with rssi per chain, etc */
+ WMI_PEER_ANTDIV_INFO_EVENTID,
/* beacon/mgmt specific events */
/** RX management frame. the entire frame is carried along with the event. */
@@ -10626,6 +10637,69 @@ typedef struct {
*/
} wmi_peer_info_event_fixed_param;
+/**
+ * WMI_PEER_ANTDIV_INFO_REQ_CMDID
+ * Request FW to provide peer info
+ */
+typedef struct {
+ /**
+ * TLV tag and len; tag equals
+ * WMITLV_TAG_STRUC_wmi_peer_antdiv_info_req_cmd_fixed_param
+ */
+ A_UINT32 tlv_header;
+ /**
+ * In order to get the peer antdiv info for a single peer, host shall
+ * issue the peer_mac_address of that peer. For getting the
+ * info all peers, the host shall issue 0xFFFFFFFF as the mac
+ * address. The firmware will return the peer info for all the
+ * peers on the specified vdev_id
+ */
+ wmi_mac_addr peer_mac_address;
+ /** vdev id */
+ A_UINT32 vdev_id;
+} wmi_peer_antdiv_info_req_cmd_fixed_param;
+
+/** FW response with the peer antdiv info */
+typedef struct {
+ /** TLV tag and len; tag equals
+ * WMITLV_TAG_STRUC_wmi_peer_antdiv_info_event_fixed_param
+ */
+ A_UINT32 tlv_header;
+ /** number of peers in peer_info */
+ A_UINT32 num_peers;
+ /** VDEV to which the peer belongs to */
+ A_UINT32 vdev_id;
+ /**
+ * This TLV is followed by another TLV of array of structs
+ * wmi_peer_antdiv_info peer_antdiv_info[];
+ */
+} wmi_peer_antdiv_info_event_fixed_param;
+
+typedef struct {
+ /**
+ * TLV tag and len; tag equals
+ * WMITLV_TAG_STRUC_wmi_peer_antdiv_info
+ */
+ A_UINT32 tlv_header;
+ /** mac addr of the peer */
+ wmi_mac_addr peer_mac_address;
+ /**
+ * per chain rssi of the peer, for up to 8 chains.
+ * Each chain's entry reports the RSSI for different bandwidths:
+ * bits 7:0 -> primary 20 MHz
+ * bits 15:8 -> secondary 20 MHz of 40 MHz channel (if applicable)
+ * bits 23:16 -> secondary 40 MHz of 80 MHz channel (if applicable)
+ * bits 31:24 -> secondary 80 MHz of 160 MHz channel (if applicable)
+ * Each of these 8-bit RSSI reports is in dB units, with respect to
+ * the noise floor.
+ * 0x80 means invalid.
+ * All unused bytes within used chain_rssi indices shall be set
+ * to 0x80.
+ * All unused chain_rssi indices shall be set to 0x80808080.
+ */
+ A_INT32 chain_rssi[8];
+} wmi_peer_antdiv_info;
+
/** FW response when tx failure count has reached threshold
* for a peer */
typedef struct {
@@ -12633,6 +12707,50 @@ typedef struct {
A_UINT32 pdev_id;
} wmi_pdev_temperature_event_fixed_param;
+typedef enum {
+ ANTDIV_HW_CFG_STATUS,
+ ANTDIV_SW_CFG_STATUS,
+ ANTDIV_MAX_STATUS_TYPE_NUM
+} ANTDIV_STATUS_TYPE;
+
+typedef struct {
+ /**
+ * TLV tag and len; tag equals
+ * WMITLV_TAG_STRUC_wmi_pdev_get_antdiv_status_cmd_fixed_param
+ */
+ A_UINT32 tlv_header;
+ /* Status event ID - see ANTDIV_STATUS_TYPE */
+ A_UINT32 status_event_id;
+ /**
+ * pdev_id for identifying the MAC
+ * See macros starting with WMI_PDEV_ID_ for values.
+ */
+ A_UINT32 pdev_id;
+} wmi_pdev_get_antdiv_status_cmd_fixed_param;
+
+typedef struct {
+ /**
+ * TLV tag and len; tag equals
+ * WMITLV_TAG_STRUC_wmi_pdev_antdiv_status_event_fixed_param
+ */
+ A_UINT32 tlv_header;
+ /* ANT DIV feature enabled or not */
+ A_UINT32 support;
+ A_UINT32 chain_num; /* how many chain supported */
+ /* how many ANT supported, 32 max */
+ A_UINT32 ant_num;
+ /**
+ * Each entry is for a tx/rx chain, and contains a bitmap identifying
+ * the antennas attached to that tx/rx chain.
+ */
+ A_UINT32 selectable_ant_mask[8];
+ /**
+ * pdev_id for identifying the MAC
+ * See macros starting with WMI_PDEV_ID_ for values.
+ */
+ A_UINT32 pdev_id;
+} wmi_pdev_antdiv_status_event_fixed_param;
+
typedef struct {
A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_set_dhcp_server_offload_cmd_fixed_param */
A_UINT32 vdev_id;
diff --git a/CORE/SERVICES/COMMON/wmi_version.h b/CORE/SERVICES/COMMON/wmi_version.h
index e1c0a5b65854..5b8959f714dc 100644
--- a/CORE/SERVICES/COMMON/wmi_version.h
+++ b/CORE/SERVICES/COMMON/wmi_version.h
@@ -36,7 +36,7 @@
#define __WMI_VER_MINOR_ 0
/** WMI revision number has to be incremented when there is a
* change that may or may not break compatibility. */
-#define __WMI_REVISION_ 279
+#define __WMI_REVISION_ 280
/** The Version Namespace should not be normally changed. Only
* host and firmware of the same WMI namespace will work
diff --git a/CORE/SERVICES/WMI/wmi_unified.c b/CORE/SERVICES/WMI/wmi_unified.c
index 6e1876a94938..ae7671c99cae 100644
--- a/CORE/SERVICES/WMI/wmi_unified.c
+++ b/CORE/SERVICES/WMI/wmi_unified.c
@@ -712,6 +712,8 @@ static u_int8_t* get_wmi_cmd_string(WMI_CMD_ID wmi_command)
CASE_RETURN_STRING(WMI_PDEV_SET_REORDER_TIMEOUT_VAL_CMDID);
CASE_RETURN_STRING(WMI_PEER_SET_RX_BLOCKSIZE_CMDID);
CASE_RETURN_STRING(WMI_PDEV_SET_WAKEUP_CONFIG_CMDID);
+ CASE_RETURN_STRING(WMI_PDEV_GET_ANTDIV_STATUS_CMDID);
+ CASE_RETURN_STRING(WMI_PEER_ANTDIV_INFO_REQ_CMDID);
}
return "Invalid WMI cmd";
}