Debug enhancement for UMAC, Timeout for cmdActivelist.
A Timer will be started as soon as cmd inserted into cmdActiveList.
The timer will be stopped whenever remove an entry from
cmdActiveList. Expiring of timer after 30 Seconds, predicts a cmd
still pending into cmdActiveList.
CRs-fixed: 553336
Change-Id: I08170af2813c3f71e6df18ba4871904dd8d001a2
diff --git a/CORE/SME/inc/csrLinkList.h b/CORE/SME/inc/csrLinkList.h
index f485521..a601244 100644
--- a/CORE/SME/inc/csrLinkList.h
+++ b/CORE/SME/inc/csrLinkList.h
@@ -77,6 +77,10 @@
tANI_U32 Count;
tHddHandle hHdd;
tListFlag Flag;
+
+ /*command debugging */
+ tANI_U32 cmdTimeoutDuration; /* command timeout duration */
+ vos_timer_t *cmdTimeoutTimer; /*command timeout Timer */
}tDblLinkList;
//To get the address of an object of (type) base on the (address) of one of its (field)
diff --git a/CORE/SME/inc/smeInside.h b/CORE/SME/inc/smeInside.h
index a107768..196254a 100644
--- a/CORE/SME/inc/smeInside.h
+++ b/CORE/SME/inc/smeInside.h
@@ -340,5 +340,6 @@
tANI_U8 numChannels,
const eCsrBand eBand);
#endif
+void activeListCmdTimeoutHandle(void *userData);
#endif //#if !defined( __SMEINSIDE_H )
diff --git a/CORE/SME/src/csr/csrLinkList.c b/CORE/SME/src/csr/csrLinkList.c
index 9983212..4b33fa7 100644
--- a/CORE/SME/src/csr/csrLinkList.c
+++ b/CORE/SME/src/csr/csrLinkList.c
@@ -55,6 +55,8 @@
#include "vos_memory.h"
#include "vos_trace.h"
+#include "vos_timer.h"
+
ANI_INLINE_FUNCTION void csrListInit(tListElem *pList)
{
pList->last = pList->next = pList;
@@ -274,7 +276,7 @@
if ( LIST_FLAG_OPEN != pList->Flag )
{
pList->Count = 0;
-
+ pList->cmdTimeoutTimer = NULL;
vosStatus = vos_lock_init(&pList->Lock);
if(VOS_IS_STATUS_SUCCESS(vosStatus))
@@ -354,6 +356,12 @@
{
csrLLUnlock(pList);
}
+ if ( pList->cmdTimeoutTimer && pList->cmdTimeoutDuration )
+ {
+ /* timer to detect pending command in activelist*/
+ vos_timer_start( pList->cmdTimeoutTimer,
+ pList->cmdTimeoutDuration);
+ }
}
}
@@ -583,6 +591,10 @@
{
csrLLUnlock( pList );
}
+ if ( pList->cmdTimeoutTimer )
+ {
+ vos_timer_stop(pList->cmdTimeoutTimer);
+ }
}
return( fFound );
diff --git a/CORE/SME/src/sme_common/sme_Api.c b/CORE/SME/src/sme_common/sme_Api.c
index 31dc372..8dc51c6 100644
--- a/CORE/SME/src/sme_common/sme_Api.c
+++ b/CORE/SME/src/sme_common/sme_Api.c
@@ -96,6 +96,9 @@
#define READ_MEMORY_DUMP_CMD 9
#define TL_INIT_STATE 0
+
+#define CSR_ACTIVE_LIST_CMD_TIMEOUT_VALUE 1000*30 //30s
+
// TxMB Functions
extern eHalStatus pmcPrepareCommand( tpAniSirGlobal pMac, eSmeCommandType cmdType, void *pvParam,
tANI_U32 size, tSmeCmd **ppCmd );
@@ -169,6 +172,8 @@
eHalStatus status;
tSmeCmd *pCmd;
tANI_U32 cmd_idx;
+ VOS_STATUS vosStatus;
+ vos_timer_t* cmdTimeoutTimer = NULL;
pMac->sme.totalSmeCmd = SME_TOTAL_COMMAND;
if (!HAL_STATUS_SUCCESS(status = csrLLOpen(pMac->hHdd,
@@ -208,6 +213,30 @@
}
}
+ /* This timer is only to debug the active list command timeout */
+
+ cmdTimeoutTimer = (vos_timer_t*)vos_mem_malloc(sizeof(vos_timer_t));
+ if (cmdTimeoutTimer)
+ {
+ pMac->sme.smeCmdActiveList.cmdTimeoutTimer = cmdTimeoutTimer;
+ vosStatus =
+ vos_timer_init( pMac->sme.smeCmdActiveList.cmdTimeoutTimer,
+ VOS_TIMER_TYPE_SW,
+ activeListCmdTimeoutHandle,
+ (void*) pMac);
+
+ if (!VOS_IS_STATUS_SUCCESS(vosStatus))
+ {
+ VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR,
+ "Init Timer fail for active list command process time out");
+ vos_mem_free(pMac->sme.smeCmdActiveList.cmdTimeoutTimer);
+ }
+ else
+ {
+ pMac->sme.smeCmdActiveList.cmdTimeoutDuration =
+ CSR_ACTIVE_LIST_CMD_TIMEOUT_VALUE;
+ }
+ }
end:
if (!HAL_STATUS_SUCCESS(status))
smsLog(pMac, LOGE, "failed to initialize sme command list:%d\n",
@@ -300,6 +329,11 @@
csrLLClose(&pMac->sme.smeScanCmdActiveList);
csrLLClose(&pMac->sme.smeCmdFreeList);
+ /*destroy active list command time out timer */
+ vos_timer_destroy(pMac->sme.smeCmdActiveList.cmdTimeoutTimer);
+ vos_mem_free(pMac->sme.smeCmdActiveList.cmdTimeoutTimer);
+ pMac->sme.smeCmdActiveList.cmdTimeoutTimer = NULL;
+
status = vos_lock_acquire(&pMac->sme.lkSmeGlobalLock);
if(status != eHAL_STATUS_SUCCESS)
{
@@ -352,6 +386,8 @@
break;
default:
+ smsLog( pMac, LOGE, " default: Unhandled command %d",
+ pCmd->command);
break;
}
}
@@ -465,11 +501,11 @@
( eSmeCommandDelTs == pCommand->command ) );
if( fFullPowerNeeded ) break;
#ifdef FEATURE_OEM_DATA_SUPPORT
- fFullPowerNeeded = (pmcState == IMPS &&
+ fFullPowerNeeded = (pmcState == IMPS &&
eSmeCommandOemDataReq == pCommand->command);
if(fFullPowerNeeded) break;
#endif
- fFullPowerNeeded = (pmcState == IMPS &&
+ fFullPowerNeeded = (pmcState == IMPS &&
eSmeCommandRemainOnChannel == pCommand->command);
if(fFullPowerNeeded) break;
} while(0);
@@ -522,12 +558,12 @@
case eSmeCommandRemainOnChannel:
if (NULL != pCommand->u.remainChlCmd.callback)
{
- remainOnChanCallback callback =
+ remainOnChanCallback callback =
pCommand->u.remainChlCmd.callback;
/* process the msg */
if( callback )
{
- callback(pMac, pCommand->u.remainChlCmd.callbackCtx,
+ callback(pMac, pCommand->u.remainChlCmd.callbackCtx,
eCSR_SCAN_ABORT );
}
}
@@ -789,7 +825,7 @@
status = csrRoamProcessCommand( pMac, pCommand );
if(!HAL_STATUS_SUCCESS(status))
{
- if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
+ if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
&pCommand->Link, LL_ACCESS_LOCK ) )
{
csrReleaseCommandRoam( pMac, pCommand );
@@ -807,7 +843,7 @@
status = csrRoamProcessSetKeyCommand( pMac, pCommand );
if(!HAL_STATUS_SUCCESS(status))
{
- if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
+ if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
&pCommand->Link, LL_ACCESS_LOCK ) )
{
csrReleaseCommandSetKey( pMac, pCommand );
@@ -820,7 +856,7 @@
status = csrRoamProcessRemoveKeyCommand( pMac, pCommand );
if(!HAL_STATUS_SUCCESS(status))
{
- if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
+ if( csrLLRemoveEntry( &pMac->sme.smeCmdActiveList,
&pCommand->Link, LL_ACCESS_LOCK ) )
{
csrReleaseCommandRemoveKey( pMac, pCommand );
@@ -832,7 +868,7 @@
csrLLUnlock( &pMac->sme.smeCmdActiveList );
csrProcessAddStaSessionCommand( pMac, pCommand );
break;
- case eSmeCommandDelStaSession:
+ case eSmeCommandDelStaSession:
csrLLUnlock( &pMac->sme.smeCmdActiveList );
csrProcessDelStaSessionCommand( pMac, pCommand );
break;
@@ -958,7 +994,7 @@
#endif
break;
#ifdef FEATURE_WLAN_TDLS
- case eSmeCommandTdlsSendMgmt:
+ case eSmeCommandTdlsSendMgmt:
case eSmeCommandTdlsAddPeer:
case eSmeCommandTdlsDelPeer:
case eSmeCommandTdlsLinkEstablish:
@@ -1234,11 +1270,11 @@
if (NULL == domainIdSoftAp ) {
smsLog( pMac, LOGE, "Uninitialized domain Id");
return status;
- }
+ }
*domainIdSoftAp = pMac->scan.domainIdCurrent;
status = eHAL_STATUS_SUCCESS;
-
+
return status;
}
@@ -1267,14 +1303,14 @@
/*--------------------------------------------------------------------------
\brief sme_UpdateChannelConfig() - Update channel configuration in RIVA.
-
- It is used at driver start up to inform RIVA of the default channel
- configuration.
+
+ It is used at driver start up to inform RIVA of the default channel
+ configuration.
This is a synchronous call
\param hHal - The handle returned by macOpen.
-
+
\return eHAL_STATUS_SUCCESS - SME update the channel config successfully.
Other status means SME is failed to update the channel config.
@@ -1842,7 +1878,7 @@
case eWNI_SME_DELTS_IND:
#ifdef WLAN_FEATURE_VOWIFI_11R
case eWNI_SME_FT_AGGR_QOS_RSP:
-#endif
+#endif
//QoS
if (pMsg->bodyptr)
{
@@ -1939,7 +1975,7 @@
vos_mem_free(pMsg->bodyptr);
}
else
- {
+ {
smsLog( pMac, LOGE, "Empty rsp message for meas (eWNI_SME_MGMT_FRM_IND), nothing to process");
}
break;
@@ -1964,7 +2000,7 @@
{
smsLog(pMac, LOGE, "Empty rsp message for meas (eWNI_SME_COEX_IND), nothing to process");
}
- break;
+ break;
#ifdef FEATURE_WLAN_SCAN_PNO
case eWNI_SME_PREF_NETWORK_FOUND_IND:
@@ -1979,7 +2015,7 @@
}
break;
#endif // FEATURE_WLAN_SCAN_PNO
-
+
case eWNI_SME_TX_PER_HIT_IND:
if (pMac->sme.pTxPerHitCallback)
{
@@ -2030,7 +2066,7 @@
status = sme_HandlePreChannelSwitchInd(pMac);
break;
}
-
+
case eWNI_SME_POST_SWITCH_CHL_IND:
{
status = sme_HandlePostChannelSwitchInd(pMac);
@@ -2056,8 +2092,8 @@
* command rescived from PE, SME tdls msg processor shall be called
* to process commands recieved from PE
*/
- case eWNI_SME_TDLS_SEND_MGMT_RSP:
- case eWNI_SME_TDLS_ADD_STA_RSP:
+ case eWNI_SME_TDLS_SEND_MGMT_RSP:
+ case eWNI_SME_TDLS_ADD_STA_RSP:
case eWNI_SME_TDLS_DEL_STA_RSP:
case eWNI_SME_TDLS_DEL_STA_IND:
case eWNI_SME_TDLS_DEL_ALL_PEER_IND:
@@ -2425,8 +2461,8 @@
\param pContext - a pointer passed in for the callback
\return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_ScanRequest(tHalHandle hHal, tANI_U8 sessionId, tCsrScanRequest *pscanReq,
- tANI_U32 *pScanRequestID,
+eHalStatus sme_ScanRequest(tHalHandle hHal, tANI_U8 sessionId, tCsrScanRequest *pscanReq,
+ tANI_U32 *pScanRequestID,
csrScanCompleteCallback callback, void *pContext)
{
eHalStatus status = eHAL_STATUS_FAILURE;
@@ -2443,7 +2479,7 @@
{
{
#ifdef FEATURE_WLAN_LFR
- if(csrIsScanAllowed(pMac))
+ if(csrIsScanAllowed(pMac))
{
#endif
status = csrScanRequest( hHal, sessionId, pscanReq,
@@ -2454,8 +2490,8 @@
" SId=%d"), sessionId);
}
#ifdef FEATURE_WLAN_LFR
- }
- else
+ }
+ else
{
smsLog(pMac, LOGE, FL("Scan denied in state %d (sub-state %d)"),
pMac->roam.neighborRoamInfo.neighborRoamState,
@@ -2465,7 +2501,7 @@
}
#endif
}
-
+
sme_ReleaseGlobalLock( &pMac->sme );
} //sme_AcquireGlobalLock success
else
@@ -2680,7 +2716,7 @@
not sizeof(tPmkidCandidateInfo) * something
---------------------------------------------------------------------------*/
eHalStatus sme_ScanGetPMKIDCandidateList(tHalHandle hHal, tANI_U8 sessionId,
- tPmkidCandidateInfo *pPmkidList,
+ tPmkidCandidateInfo *pPmkidList,
tANI_U32 *pNumItems )
{
eHalStatus status = eHAL_STATUS_FAILURE;
@@ -2844,8 +2880,8 @@
{
if( CSR_IS_SESSION_VALID( pMac, sessionId ) )
{
- if((NULL == pProfile) && (fForce == 1))
- {
+ if((NULL == pProfile) && (fForce == 1))
+ {
tCsrRoamSession *pSession = CSR_GET_SESSION( pMac, sessionId );
/* to force the AP initiate fresh 802.1x authentication need to clear
* the PMKID cache for that set the following boolean. this is needed
@@ -2856,7 +2892,7 @@
else
{
status = csrRoamReassoc( pMac, sessionId, pProfile, modProfileFields, pRoamId );
- }
+ }
}
else
{
@@ -2985,7 +3021,7 @@
{
if( CSR_IS_SESSION_VALID( pMac, sessionId ) )
{
- status = csrRoamIssueDisassociateStaCmd( pMac, sessionId, pPeerMacAddr,
+ status = csrRoamIssueDisassociateStaCmd( pMac, sessionId, pPeerMacAddr,
eSIR_MAC_DEAUTH_LEAVING_BSS_REASON);
}
else
@@ -3023,7 +3059,7 @@
{
if( CSR_IS_SESSION_VALID( pMac, sessionId ) )
{
- status = csrRoamIssueDeauthStaCmd( pMac, sessionId, pPeerMacAddr,
+ status = csrRoamIssueDeauthStaCmd( pMac, sessionId, pPeerMacAddr,
eSIR_MAC_DEAUTH_LEAVING_BSS_REASON);
}
else
@@ -3125,7 +3161,7 @@
\return eHalStatus
-------------------------------------------------------------------------------*/
eHalStatus sme_RoamGetWpsSessionOverlap(tHalHandle hHal, tANI_U8 sessionId,
- void *pUsrContext, void
+ void *pUsrContext, void
*pfnSapEventCallback, v_MACADDR_t pRemoveMac)
{
eHalStatus status = eHAL_STATUS_FAILURE;
@@ -3904,8 +3940,8 @@
/* ---------------------------------------------------------------------------
\fn sme_SetDHCPTillPowerActiveFlag
- \brief Sets/Clears DHCP related flag in PMC to disable/enable auto BMPS
- entry by PMC
+ \brief Sets/Clears DHCP related flag in PMC to disable/enable auto BMPS
+ entry by PMC
\param hHal - The handle returned by macOpen.
---------------------------------------------------------------------------*/
void sme_SetDHCPTillPowerActiveFlag(tHalHandle hHal, tANI_U8 flag)
@@ -4221,9 +4257,9 @@
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
- status = pmcEnterWowl (hHal, enterWowlCallbackRoutine, enterWowlCallbackContext,
+ status = pmcEnterWowl (hHal, enterWowlCallbackRoutine, enterWowlCallbackContext,
#ifdef WLAN_WAKEUP_EVENTS
- wakeIndicationCB, wakeIndicationCBContext,
+ wakeIndicationCB, wakeIndicationCBContext,
#endif // WLAN_WAKEUP_EVENTS
wowlEnterParams, sessionId);
sme_ReleaseGlobalLock( &pMac->sme );
@@ -4389,7 +4425,7 @@
---------------------------------------------------------------------------*/
eHalStatus sme_GetRssi(tHalHandle hHal,
tCsrRssiCallback callback,
- tANI_U8 staId, tCsrBssid bssId,
+ tANI_U8 staId, tCsrBssid bssId,
void *pContext, void* pVosContext)
{
eHalStatus status = eHAL_STATUS_FAILURE;
@@ -5177,7 +5213,7 @@
\brief API to set configure privacy parameters
\param hHal - The handle returned by macOpen.
\param pProfile - Pointer CSR Roam profile.
- \param fPrivacy - This parameter indicates status of privacy
+ \param fPrivacy - This parameter indicates status of privacy
\return void
---------------------------------------------------------------------------*/
@@ -5270,7 +5306,7 @@
status = VOS_STATUS_SUCCESS;
}
else
- {
+ {
status = VOS_STATUS_E_FAILURE;
}
}
@@ -5287,10 +5323,10 @@
*pRegValue = 0xDEADBEEF;
status = VOS_STATUS_SUCCESS;
}
-
+
/* Release SME global lock */
sme_ReleaseGlobalLock(&pMac->sme);
-
+
return (status);
}
@@ -5344,10 +5380,10 @@
status = VOS_STATUS_E_FAILURE;
}
}
-
+
/* Release SME global lock */
sme_ReleaseGlobalLock(&pMac->sme);
-
+
return (status);
}
@@ -5419,7 +5455,7 @@
/* Release SME lock */
sme_ReleaseGlobalLock(&pMac->sme);
-
+
return (status);
}
@@ -5475,7 +5511,7 @@
/* Release Global lock */
sme_ReleaseGlobalLock(&pMac->sme);
-
+
return (status);
}
@@ -5785,9 +5821,9 @@
\brief a wrapper function to obtain the OEM DATA RSP
\param pOemDataRsp - A pointer to the response object
\param pContext - a pointer passed in for the callback
- \return eHalStatus
+ \return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_getOemDataRsp(tHalHandle hHal,
+eHalStatus sme_getOemDataRsp(tHalHandle hHal,
tOemDataRsp **pOemDataRsp)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -5827,13 +5863,13 @@
\param pOemDataReqId - pointer to an object to get back the request ID
\param callback - a callback function that is called upon finish
\param pContext - a pointer passed in for the callback
- \return eHalStatus
+ \return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_OemDataReq(tHalHandle hHal,
+eHalStatus sme_OemDataReq(tHalHandle hHal,
tANI_U8 sessionId,
- tOemDataReqConfig *pOemDataReqConfig,
- tANI_U32 *pOemDataReqID,
- oemData_OemDataReqCompleteCallback callback,
+ tOemDataReqConfig *pOemDataReqConfig,
+ tANI_U32 *pOemDataReqID,
+ oemData_OemDataReqCompleteCallback callback,
void *pContext)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -5950,7 +5986,7 @@
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
- status = csrRoamCloseSession( pMac, sessionId, FALSE,
+ status = csrRoamCloseSession( pMac, sessionId, FALSE,
callback, pContext );
sme_ReleaseGlobalLock( &pMac->sme );
@@ -6025,14 +6061,14 @@
\fn sme_ChangeMCCBeaconInterval
- \brief To update P2P-GO beaconInterval. This function should be called after
- disassociating all the station is done
+ \brief To update P2P-GO beaconInterval. This function should be called after
+ disassociating all the station is done
This is an asynchronous API.
- \param
+ \param
- \return eHalStatus SUCCESS
- FAILURE or RESOURCES
+ \return eHalStatus SUCCESS
+ FAILURE or RESOURCES
The API finished and failed.
-------------------------------------------------------------------------------*/
@@ -6171,7 +6207,7 @@
\param pRequest - Pointer to the offload request.
\return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_SetHostOffload (tHalHandle hHal, tANI_U8 sessionId,
+eHalStatus sme_SetHostOffload (tHalHandle hHal, tANI_U8 sessionId,
tpSirHostOffloadReq pRequest)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -6205,7 +6241,7 @@
\param pRequest - Pointer to the GTK offload request.
\return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_SetGTKOffload (tHalHandle hHal, tpSirGtkOffloadParams pRequest,
+eHalStatus sme_SetGTKOffload (tHalHandle hHal, tpSirGtkOffloadParams pRequest,
tANI_U8 sessionId)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -6229,7 +6265,7 @@
\param pRequest - Pointer to the GTK offload response.
\return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_GetGTKOffload (tHalHandle hHal, GTKOffloadGetInfoCallback callbackRoutine,
+eHalStatus sme_GetGTKOffload (tHalHandle hHal, GTKOffloadGetInfoCallback callbackRoutine,
void *callbackContext, tANI_U8 sessionId )
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -6254,7 +6290,7 @@
\param pRequest - Pointer to the Keep Alive request.
\return eHalStatus
---------------------------------------------------------------------------*/
-eHalStatus sme_SetKeepAlive (tHalHandle hHal, tANI_U8 sessionId,
+eHalStatus sme_SetKeepAlive (tHalHandle hHal, tANI_U8 sessionId,
tpSirKeepAliveReq pRequest)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -6342,10 +6378,10 @@
if ( HAL_STATUS_SUCCESS( status ) )
{
status = csrScanAbortMacScan(pMac, sessionId);
-
+
sme_ReleaseGlobalLock( &pMac->sme );
}
-
+
return ( status );
}
@@ -6366,7 +6402,7 @@
{
pSession = CSR_GET_SESSION( pMac, sessionId );
- if(( pSession->connectedProfile.BSSType == eCSR_BSS_TYPE_INFRASTRUCTURE ) ||
+ if(( pSession->connectedProfile.BSSType == eCSR_BSS_TYPE_INFRASTRUCTURE ) ||
( pSession->connectedProfile.BSSType == eCSR_BSS_TYPE_IBSS ) ||
( pSession->connectedProfile.BSSType == eCSR_BSS_TYPE_INFRA_AP ) ||
( pSession->connectedProfile.BSSType == eCSR_BSS_TYPE_START_IBSS ))
@@ -6382,14 +6418,14 @@
\fn sme_RegisterMgtFrame
- \brief To register managment frame of specified type and subtype.
+ \brief To register managment frame of specified type and subtype.
\param frameType - type of the frame that needs to be passed to HDD.
- \param matchData - data which needs to be matched before passing frame
- to HDD.
+ \param matchData - data which needs to be matched before passing frame
+ to HDD.
\param matchDataLen - Length of matched data.
- \return eHalStatus
+ \return eHalStatus
-------------------------------------------------------------------------------*/
-eHalStatus sme_RegisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
+eHalStatus sme_RegisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -6409,7 +6445,7 @@
sme_ReleaseGlobalLock( &pMac->sme );
return eHAL_STATUS_FAILURE;
}
-
+
if( !pSession->sessionActive )
{
VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR,
@@ -6417,7 +6453,7 @@
sme_ReleaseGlobalLock( &pMac->sme );
return eHAL_STATUS_FAILURE;
}
-
+
len = sizeof(tSirRegisterMgmtFrame) + matchLen;
pMsg = vos_mem_malloc(len);
@@ -6444,14 +6480,14 @@
\fn sme_DeregisterMgtFrame
- \brief To De-register managment frame of specified type and subtype.
+ \brief To De-register managment frame of specified type and subtype.
\param frameType - type of the frame that needs to be passed to HDD.
- \param matchData - data which needs to be matched before passing frame
- to HDD.
+ \param matchData - data which needs to be matched before passing frame
+ to HDD.
\param matchDataLen - Length of matched data.
- \return eHalStatus
+ \return eHalStatus
-------------------------------------------------------------------------------*/
-eHalStatus sme_DeregisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
+eHalStatus sme_DeregisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -6471,8 +6507,8 @@
sme_ReleaseGlobalLock( &pMac->sme );
return eHAL_STATUS_FAILURE;
}
-
- if( !pSession->sessionActive )
+
+ if( !pSession->sessionActive )
{
VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR,
"%s Invalid Sessionid", __func__);
@@ -6489,7 +6525,7 @@
{
vos_mem_set(pMsg, len, 0);
pMsg->messageType = eWNI_SME_REGISTER_MGMT_FRAME_REQ;
- pMsg->length = len;
+ pMsg->length = len;
pMsg->registerFrame = VOS_FALSE;
pMsg->frameType = frameType;
pMsg->matchLen = matchLen;
@@ -6603,7 +6639,7 @@
sirDumpBuf( pMac, SIR_LIM_MODULE_ID, LOG2,
pMac->p2pContext.probeRspIe,
- pMac->p2pContext.probeRspIeLength );
+ pMac->p2pContext.probeRspIeLength );
vos_mem_copy((tANI_U8 *)pMac->p2pContext.probeRspIe, p2pIe,
p2pIeLength);
}
@@ -6611,7 +6647,7 @@
//release the lock for the sme object
sme_ReleaseGlobalLock( &pMac->sme );
}
-
+
smsLog(pMac, LOG2, "exiting function %s", __func__);
return(status);
@@ -6682,14 +6718,14 @@
\fn sme_ConfigureRxpFilter
- \brief
+ \brief
SME will pass this request to lower mac to set/reset the filter on RXP for
multicast & broadcast traffic.
- \param
+ \param
- hHal - The handle returned by macOpen.
-
+ hHal - The handle returned by macOpen.
+
filterMask- Currently the API takes a 1 or 0 (set or reset) as filter.
Basically to enable/disable the filter (to filter "all" mcbc traffic) based
on this param. In future we can use this as a mask to set various types of
@@ -6698,12 +6734,12 @@
FILTER_ALL_BROADCAST:
FILTER_ALL_MULTICAST_BROADCAST:
-
- \return eHalStatus
-
-
+
+ \return eHalStatus
+
+
--------------------------------------------------------------------------- */
-eHalStatus sme_ConfigureRxpFilter( tHalHandle hHal,
+eHalStatus sme_ConfigureRxpFilter( tHalHandle hHal,
tpSirWlanSetRxpFilters wlanRxpFilterParam)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -6732,22 +6768,22 @@
\fn sme_ConfigureSuspendInd
- \brief
- SME will pass this request to lower mac to Indicate that the wlan needs to
+ \brief
+ SME will pass this request to lower mac to Indicate that the wlan needs to
be suspended
- \param
+ \param
- hHal - The handle returned by macOpen.
-
+ hHal - The handle returned by macOpen.
+
wlanSuspendParam- Depicts the wlan suspend params
-
- \return eHalStatus
-
-
+
+ \return eHalStatus
+
+
--------------------------------------------------------------------------- */
-eHalStatus sme_ConfigureSuspendInd( tHalHandle hHal,
+eHalStatus sme_ConfigureSuspendInd( tHalHandle hHal,
tpSirWlanSuspendParam wlanSuspendParam)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -6776,22 +6812,22 @@
\fn sme_ConfigureResumeReq
- \brief
- SME will pass this request to lower mac to Indicate that the wlan needs to
+ \brief
+ SME will pass this request to lower mac to Indicate that the wlan needs to
be Resumed
- \param
+ \param
- hHal - The handle returned by macOpen.
-
+ hHal - The handle returned by macOpen.
+
wlanResumeParam- Depicts the wlan resume params
-
- \return eHalStatus
-
-
+
+ \return eHalStatus
+
+
--------------------------------------------------------------------------- */
-eHalStatus sme_ConfigureResumeReq( tHalHandle hHal,
+eHalStatus sme_ConfigureResumeReq( tHalHandle hHal,
tpSirWlanResumeParam wlanResumeParam)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
@@ -6833,7 +6869,7 @@
eHalStatus status = eHAL_STATUS_FAILURE;
tANI_S8 sessionid = -1;
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
-
+
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
@@ -6877,11 +6913,11 @@
}
//This routine will return poerating channel on which other BSS is operating to be used for concurrency mode.
-//If other BSS is not up or not connected it will return 0
+//If other BSS is not up or not connected it will return 0
tANI_U8 sme_GetConcurrentOperationChannel( tHalHandle hHal )
{
eHalStatus status = eHAL_STATUS_FAILURE;
- tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
+ tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
tANI_U8 channel = 0;
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
@@ -6902,7 +6938,7 @@
* Name: sme_PreferredNetworkFoundInd
*
* Description:
-* Invoke Preferred Network Found Indication
+* Invoke Preferred Network Found Indication
*
* Parameters:
* hHal - HAL handle for device
@@ -6983,14 +7019,14 @@
{
eHalStatus status = eHAL_STATUS_FAILURE;
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
-
+
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
status = csrGetCfgValidChannels(pMac, aValidChannels, len);
sme_ReleaseGlobalLock( &pMac->sme );
}
-
+
return (status);
}
@@ -7007,8 +7043,8 @@
\return eHalStatus
-------------------------------------------------------------------------------*/
-eHalStatus sme_SetTxPerTracking(tHalHandle hHal,
- void (*pCallbackfn) (void *pCallbackContext),
+eHalStatus sme_SetTxPerTracking(tHalHandle hHal,
+ void (*pCallbackfn) (void *pCallbackContext),
void *pCallbackContext,
tpSirTxPerTrackingParam pTxPerTrackingParam)
{
@@ -7022,7 +7058,7 @@
pMac->sme.pTxPerHitCbContext = pCallbackContext;
sme_ReleaseGlobalLock( &pMac->sme );
}
-
+
// free this memory in failure case or WDA request callback function
pTxPerTrackingParamReq = vos_mem_malloc(sizeof(tSirTxPerTrackingParam));
if (NULL == pTxPerTrackingParamReq)
@@ -7137,7 +7173,7 @@
/* Supplicant country code failed. So give 11D priority */
pMac->roam.configParam.Is11dSupportEnabled = pMac->roam.configParam.Is11dSupportEnabledOriginal;
smsLog(pMac, LOGE, "Set Country Code Fail %d", status);
- return status;
+ return status;
}
/* overwrite the defualt country code */
@@ -7477,7 +7513,7 @@
return eHAL_STATUS_SUCCESS;
}
-eHalStatus sme_ReceiveFilterSetFilter(tHalHandle hHal, tpSirRcvPktFilterCfgType pRcvPktFilterCfg,
+eHalStatus sme_ReceiveFilterSetFilter(tHalHandle hHal, tpSirRcvPktFilterCfgType pRcvPktFilterCfg,
tANI_U8 sessionId)
{
tpSirRcvPktFilterCfgType pRequestBuf;
@@ -7490,9 +7526,9 @@
VOS_TRACE( VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, "%s: filterType=%d, "
"filterId = %d", __func__,
pRcvPktFilterCfg->filterType, pRcvPktFilterCfg->filterId);
-
+
allocSize = sizeof(tSirRcvPktFilterCfgType);
-
+
pRequestBuf = vos_mem_malloc(allocSize);
if (NULL == pRequestBuf)
@@ -7520,12 +7556,12 @@
msg.bodyptr = pRequestBuf;
VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, "Pkt Flt Req : "
- "FT %d FID %d ",
- pRequestBuf->filterType, pRequestBuf->filterId);
+ "FT %d FID %d ",
+ pRequestBuf->filterType, pRequestBuf->filterId);
VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, "Pkt Flt Req : "
- "params %d CT %d",
- pRequestBuf->numFieldParams, pRequestBuf->coalesceTime);
+ "params %d CT %d",
+ pRequestBuf->numFieldParams, pRequestBuf->coalesceTime);
for (idx=0; idx<pRequestBuf->numFieldParams; idx++)
{
@@ -7543,16 +7579,16 @@
VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO,
"CData: %d:%d:%d:%d:%d:%d",
pRequestBuf->paramsData[idx].compareData[0],
- pRequestBuf->paramsData[idx].compareData[1],
+ pRequestBuf->paramsData[idx].compareData[1],
pRequestBuf->paramsData[idx].compareData[2],
pRequestBuf->paramsData[idx].compareData[3],
pRequestBuf->paramsData[idx].compareData[4],
pRequestBuf->paramsData[idx].compareData[5]);
- VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO,
+ VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO,
"MData: %d:%d:%d:%d:%d:%d",
pRequestBuf->paramsData[idx].dataMask[0],
- pRequestBuf->paramsData[idx].dataMask[1],
+ pRequestBuf->paramsData[idx].dataMask[1],
pRequestBuf->paramsData[idx].dataMask[2],
pRequestBuf->paramsData[idx].dataMask[3],
pRequestBuf->paramsData[idx].dataMask[4],
@@ -7571,9 +7607,9 @@
return eHAL_STATUS_SUCCESS;
}
-eHalStatus sme_GetFilterMatchCount(tHalHandle hHal,
+eHalStatus sme_GetFilterMatchCount(tHalHandle hHal,
FilterMatchCountCallback callbackRoutine,
- void *callbackContext,
+ void *callbackContext,
tANI_U8 sessionId)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -7592,7 +7628,7 @@
return (status);
}
-eHalStatus sme_ReceiveFilterClearFilter(tHalHandle hHal, tpSirRcvFltPktClearParam pRcvFltPktClearParam,
+eHalStatus sme_ReceiveFilterClearFilter(tHalHandle hHal, tpSirRcvFltPktClearParam pRcvFltPktClearParam,
tANI_U8 sessionId)
{
tpSirRcvFltPktClearParam pRequestBuf;
@@ -7602,7 +7638,7 @@
VOS_TRACE( VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, "%s: filterId = %d", __func__,
pRcvFltPktClearParam->filterId);
-
+
pRequestBuf = vos_mem_malloc(sizeof(tSirRcvFltPktClearParam));
if (NULL == pRequestBuf)
{
@@ -7643,12 +7679,12 @@
/* ---------------------------------------------------------------------------
\fn sme_PreChannelSwitchIndFullPowerCB
- \brief call back function for the PMC full power request because of pre
+ \brief call back function for the PMC full power request because of pre
channel switch.
\param callbackContext
\param status
---------------------------------------------------------------------------*/
-void sme_PreChannelSwitchIndFullPowerCB(void *callbackContext,
+void sme_PreChannelSwitchIndFullPowerCB(void *callbackContext,
eHalStatus status)
{
tpAniSirGlobal pMac = (tpAniSirGlobal)callbackContext;
@@ -7663,7 +7699,7 @@
pMsg->type = pal_cpu_to_be16((tANI_U16)eWNI_SME_PRE_CHANNEL_SWITCH_FULL_POWER);
pMsg->msgLen = pal_cpu_to_be16(msgLen);
status = palSendMBMessage(pMac->hHdd, pMsg);
- }
+ }
return;
}
@@ -7681,8 +7717,8 @@
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
- status = pmcRequestFullPower(hHal, sme_PreChannelSwitchIndFullPowerCB,
- pMac, eSME_FULL_PWR_NEEDED_BY_CHANNEL_SWITCH);
+ status = pmcRequestFullPower(hHal, sme_PreChannelSwitchIndFullPowerCB,
+ pMac, eSME_FULL_PWR_NEEDED_BY_CHANNEL_SWITCH);
sme_ReleaseGlobalLock( &pMac->sme );
}
@@ -7728,7 +7764,7 @@
eHalStatus status = eHAL_STATUS_FAILURE;
tANI_BOOLEAN valid = FALSE;
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
-
+
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
@@ -7793,7 +7829,7 @@
\param hHal - HAL handle for device
\param pMsg - Message body passed from WDA; includes Wake Reason Indication parameter
- \return eHalStatus
+ \return eHalStatus
******************************************************************************/
eHalStatus sme_WakeReasonIndCallback (tHalHandle hHal, void* pMsg)
{
@@ -7813,7 +7849,7 @@
/* Call Wake Reason Indication callback routine. */
if (pMac->pmc.wakeReasonIndCB != NULL)
pMac->pmc.wakeReasonIndCB(pMac->pmc.wakeReasonIndCBContext, pWakeReasonInd);
-
+
pMac->pmc.wakeReasonIndCB = NULL;
pMac->pmc.wakeReasonIndCBContext = NULL;
@@ -7839,7 +7875,7 @@
\- return eHalStatus
-------------------------------------------------------------------------------*/
-eHalStatus sme_SetMaxTxPower(tHalHandle hHal, tSirMacAddr pBssid,
+eHalStatus sme_SetMaxTxPower(tHalHandle hHal, tSirMacAddr pBssid,
tSirMacAddr pSelfMacAddress, v_S7_t dB)
{
vos_msg_t msg;
@@ -7978,8 +8014,8 @@
sme_ReleaseGlobalLock( &pMac->sme );
return eHAL_STATUS_FAILURE;
}
-
- if( !pSession->sessionActive )
+
+ if( !pSession->sessionActive )
VOS_ASSERT(0);
/* Create the message and send to lim */
@@ -7994,7 +8030,7 @@
pMsg->length = len;
/* Data starts from here */
pMsg->sessionId = sessionId;
- pMsg->ssidHidden = ssidHidden;
+ pMsg->ssidHidden = ssidHidden;
status = palSendMBMessage(pMac->hHdd, pMsg);
}
sme_ReleaseGlobalLock( &pMac->sme );
@@ -8009,7 +8045,7 @@
\param hHal - The handle returned by macOpen.
\param newTMLevel - new Thermal Mitigation Level
\param tmMode - Thermal Mitigation handle mode, default 0
- \return eHalStatus
+ \return eHalStatus
---------------------------------------------------------------------------*/
eHalStatus sme_SetTmLevel(tHalHandle hHal, v_U16_t newTMLevel, v_U16_t tmMode)
{
@@ -8342,7 +8378,7 @@
to configure nImmediateRoamRssiDiff
Usage: adb shell iwpriv wlan0 setConfig gImmediateRoamRssiDiff=[0 .. 125]
\param hHal - HAL handle for device
- \param nImmediateRoamRssiDiff - minimum rssi difference between potential
+ \param nImmediateRoamRssiDiff - minimum rssi difference between potential
candidate and current AP.
\- return Success or failure
-------------------------------------------------------------------------*/
@@ -8410,7 +8446,7 @@
/*--------------------------------------------------------------------------
\brief sme_UpdateFastTransitionEnabled() - enable/disable Fast Transition support at runtime
- It is used at in the REG_DYNAMIC_VARIABLE macro definition of
+ It is used at in the REG_DYNAMIC_VARIABLE macro definition of
isFastTransitionEnabled.
This is a synchronous call
\param hHal - The handle returned by macOpen.
@@ -8418,7 +8454,7 @@
Other status means SME is failed to update isFastTransitionEnabled.
\sa
--------------------------------------------------------------------------*/
-eHalStatus sme_UpdateFastTransitionEnabled(tHalHandle hHal,
+eHalStatus sme_UpdateFastTransitionEnabled(tHalHandle hHal,
v_BOOL_t isFastTransitionEnabled)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -8517,7 +8553,7 @@
#ifdef FEATURE_WLAN_LFR
/*--------------------------------------------------------------------------
\brief sme_UpdateIsFastRoamIniFeatureEnabled() - enable/disable LFR support at runtime
- It is used at in the REG_DYNAMIC_VARIABLE macro definition of
+ It is used at in the REG_DYNAMIC_VARIABLE macro definition of
isFastRoamIniFeatureEnabled.
This is a synchronous call
\param hHal - The handle returned by macOpen.
@@ -8525,7 +8561,7 @@
Other status means SME is failed to update isFastRoamIniFeatureEnabled.
\sa
--------------------------------------------------------------------------*/
-eHalStatus sme_UpdateIsFastRoamIniFeatureEnabled(tHalHandle hHal,
+eHalStatus sme_UpdateIsFastRoamIniFeatureEnabled(tHalHandle hHal,
const v_BOOL_t isFastRoamIniFeatureEnabled)
{
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -9315,9 +9351,11 @@
/* ---------------------------------------------------------------------------
\fn sme_IsFeatureSupportedByFW
+
\brief Check if a feature is enabled by FW
\param featEnumValue - Enumeration value from placeHolderInCapBitmap
+
\- return 1/0 (TRUE/FALSE)
-------------------------------------------------------------------------*/
tANI_U8 sme_IsFeatureSupportedByFW(tANI_U8 featEnumValue)
@@ -9369,7 +9407,7 @@
/* ---------------------------------------------------------------------------
\fn sme_SendTdlsMgmtFrame
\brief API to send TDLS management frames.
-
+
\param peerMac - peer's Mac Adress.
\param frame_type - Type of TDLS mgmt frame to be sent.
\param dialog - dialog token used in the frame.
@@ -9434,7 +9472,7 @@
/* ---------------------------------------------------------------------------
\fn sme_AddTdlsPeerSta
\brief API to Add TDLS peer sta entry.
-
+
\param peerMac - peer's Mac Adress.
\- return VOS_STATUS_SUCCES
-------------------------------------------------------------------------*/
@@ -9457,7 +9495,7 @@
/* ---------------------------------------------------------------------------
\fn sme_DeleteTdlsPeerSta
\brief API to Delete TDLS peer sta entry.
-
+
\param peerMac - peer's Mac Adress.
\- return VOS_STATUS_SUCCES
-------------------------------------------------------------------------*/
@@ -10111,6 +10149,7 @@
#endif
+
#ifdef FEATURE_WLAN_CH_AVOID
/* ---------------------------------------------------------------------------
\fn sme_AddChAvoidCallback
@@ -10147,3 +10186,14 @@
}
#endif /* FEATURE_WLAN_CH_AVOID */
+
+void activeListCmdTimeoutHandle(void *userData)
+{
+ if (NULL == userData)
+ return;
+ VOS_TRACE(VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR,
+ "%s: Active List command timeout Cmd List Count %d", __func__,
+ csrLLCount(&((tpAniSirGlobal) userData)->sme.smeCmdActiveList) );
+ smeGetCommandQStatus((tHalHandle) userData);
+}
+