Fix the issue with probe req data rate on 5G channels.
Pass the interface persona to firmware to identify the device mode
and program the data rates accordingly.
Change-Id: Id2607fc806aeec7e91d85ee3c174fb77340680d8
CRs-Fixed: 497478
diff --git a/CORE/HDD/src/wlan_hdd_early_suspend.c b/CORE/HDD/src/wlan_hdd_early_suspend.c
index 0f699ea..cf441dc 100644
--- a/CORE/HDD/src/wlan_hdd_early_suspend.c
+++ b/CORE/HDD/src/wlan_hdd_early_suspend.c
@@ -424,7 +424,8 @@
//Open a SME session for future operation
halStatus = sme_OpenSession( pHddCtx->hHal, hdd_smeRoamCallback, pHddCtx,
- (tANI_U8 *)&pAdapter->macAddressCurrent, &pAdapter->sessionId );
+ (tANI_U8 *)&pAdapter->macAddressCurrent,
+ &pAdapter->sessionId);
if ( !HAL_STATUS_SUCCESS( halStatus ) )
{
hddLog(VOS_TRACE_LEVEL_FATAL,"sme_OpenSession() failed with status code %08d [x%08lx]",
diff --git a/CORE/HDD/src/wlan_hdd_hostapd.c b/CORE/HDD/src/wlan_hdd_hostapd.c
index 1a304c6..91c3e24 100644
--- a/CORE/HDD/src/wlan_hdd_hostapd.c
+++ b/CORE/HDD/src/wlan_hdd_hostapd.c
@@ -2929,11 +2929,14 @@
{
hdd_hostapd_state_t * phostapdBuf;
struct net_device *dev = pAdapter->dev;
+ hdd_context_t *pHddCtx = WLAN_HDD_GET_CTX(pAdapter);
VOS_STATUS status;
ENTER();
// Allocate the Wireless Extensions state structure
phostapdBuf = WLAN_HDD_GET_HOSTAP_STATE_PTR( pAdapter );
+ sme_SetCurrDeviceMode(pHddCtx->hHal, pAdapter->device_mode);
+
// Zero the memory. This zeros the profile structure.
memset(phostapdBuf, 0,sizeof(hdd_hostapd_state_t));
diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c
index 05b4971..a561f1b 100644
--- a/CORE/HDD/src/wlan_hdd_main.c
+++ b/CORE/HDD/src/wlan_hdd_main.c
@@ -3244,9 +3244,10 @@
int rc = 0;
INIT_COMPLETION(pAdapter->session_open_comp_var);
+ sme_SetCurrDeviceMode(pHddCtx->hHal, pAdapter->device_mode);
//Open a SME session for future operation
halStatus = sme_OpenSession( pHddCtx->hHal, hdd_smeRoamCallback, pAdapter,
- (tANI_U8 *)&pAdapter->macAddressCurrent, &pAdapter->sessionId );
+ (tANI_U8 *)&pAdapter->macAddressCurrent, &pAdapter->sessionId);
if ( !HAL_STATUS_SUCCESS( halStatus ) )
{
hddLog(VOS_TRACE_LEVEL_FATAL,
diff --git a/CORE/MAC/inc/sirApi.h b/CORE/MAC/inc/sirApi.h
index 1b6a5c5..aed8177 100644
--- a/CORE/MAC/inc/sirApi.h
+++ b/CORE/MAC/inc/sirApi.h
@@ -3319,6 +3319,7 @@
tANI_U16 mesgType;
tANI_U16 mesgLen;
tSirMacAddr selfMacAddr;
+ tVOS_CON_MODE currDeviceMode;
}tSirSmeAddStaSelfReq, *tpSirSmeAddStaSelfReq;
typedef struct sSirSmeDelStaSelfReq
diff --git a/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c b/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
index bca0be3..b1b4d25 100644
--- a/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
+++ b/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
@@ -4535,7 +4535,7 @@
}
palCopyMemory( pMac->hHdd, pAddStaSelfParams->selfMacAddr, pSmeReq->selfMacAddr, sizeof(tSirMacAddr) );
-
+ pAddStaSelfParams->currDeviceMode = pSmeReq->currDeviceMode;
msg.type = SIR_HAL_ADD_STA_SELF_REQ;
msg.reserved = 0;
msg.bodyptr = pAddStaSelfParams;
diff --git a/CORE/SME/inc/csrInternal.h b/CORE/SME/inc/csrInternal.h
index 9a5dfea..de7ee50 100644
--- a/CORE/SME/inc/csrInternal.h
+++ b/CORE/SME/inc/csrInternal.h
@@ -462,10 +462,12 @@
}tWmStatusChangeCmd;
+
typedef struct tagAddStaForSessionCmd
{
//Session self mac addr
tSirMacAddr selfMacAddr;
+ tVOS_CON_MODE currDeviceMode;
}tAddStaForSessionCmd;
typedef struct tagDelStaForSessionCmd
diff --git a/CORE/SME/inc/smeInternal.h b/CORE/SME/inc/smeInternal.h
index 24c7f6e..e646d01 100644
--- a/CORE/SME/inc/smeInternal.h
+++ b/CORE/SME/inc/smeInternal.h
@@ -156,6 +156,7 @@
tDblLinkList smeCmdFreeList; //preallocated roam cmd list
void (*pTxPerHitCallback) (void *pCallbackContext); /* callback for Tx PER hit to HDD */
void *pTxPerHitCbContext;
+ tVOS_CON_MODE currDeviceMode;
} tSmeStruct, *tpSmeStruct;
diff --git a/CORE/SME/inc/sme_Api.h b/CORE/SME/inc/sme_Api.h
index a9d2603..94aac47 100644
--- a/CORE/SME/inc/sme_Api.h
+++ b/CORE/SME/inc/sme_Api.h
@@ -223,9 +223,18 @@
\sa
--------------------------------------------------------------------------*/
-eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback, void *pContext,
- tANI_U8 *pSelfMacAddr, tANI_U8 *pbSessionId);
+eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback,
+ void *pContext, tANI_U8 *pSelfMacAddr,
+ tANI_U8 *pbSessionId);
+/*--------------------------------------------------------------------------
+
+ \brief sme_SetCurrDeviceMode() - Sets the current operating device mode.
+ \param hHal - The handle returned by macOpen.
+ \param currDeviceMode - Current operating device mode.
+ --------------------------------------------------------------------------*/
+
+void sme_SetCurrDeviceMode (tHalHandle hHal, tVOS_CON_MODE currDeviceMode);
/*--------------------------------------------------------------------------
diff --git a/CORE/SME/src/csr/csrApiRoam.c b/CORE/SME/src/csr/csrApiRoam.c
index 5b6bb0a..e8ec8a3 100644
--- a/CORE/SME/src/csr/csrApiRoam.c
+++ b/CORE/SME/src/csr/csrApiRoam.c
@@ -13303,22 +13303,26 @@
} while(0);
return status;
}
-eHalStatus csrSendMBAddSelfStaReqMsg( tpAniSirGlobal pMac, tSirMacAddr macAddr )
+eHalStatus csrSendMBAddSelfStaReqMsg(tpAniSirGlobal pMac,
+ tAddStaForSessionCmd *pAddStaReq)
{
tSirSmeAddStaSelfReq *pMsg;
tANI_U16 msgLen;
eHalStatus status = eHAL_STATUS_FAILURE;
do {
- msgLen = sizeof( tANI_U16 ) + sizeof( tANI_U16 ) + sizeof( tSirMacAddr ) /*+
- sizeof( tSirBssType )*/;
+ msgLen = sizeof(tSirSmeAddStaSelfReq);
status = palAllocateMemory(pMac->hHdd, (void **)&pMsg, msgLen);
if ( !HAL_STATUS_SUCCESS(status) ) break;
palZeroMemory(pMac->hHdd, pMsg, msgLen);
pMsg->mesgType = pal_cpu_to_be16((tANI_U16)eWNI_SME_ADD_STA_SELF_REQ);
pMsg->mesgLen = pal_cpu_to_be16(msgLen);
// self station address
- palCopyMemory( pMac->hHdd, (tANI_U8 *)pMsg->selfMacAddr, (tANI_U8 *)macAddr, sizeof(tSirMacAddr) );
- smsLog( pMac, LOG1, FL("selfMac=%02x, %02x, %02x, %02x, %02x, %02x"),
+ palCopyMemory(pMac->hHdd, (tANI_U8 *)pMsg->selfMacAddr,
+ (tANI_U8 *)&pAddStaReq->selfMacAddr, sizeof(tSirMacAddr));
+
+ pMsg->currDeviceMode = pAddStaReq->currDeviceMode;
+
+ smsLog( pMac, LOG1, FL("selfMac=%02x, %02x, %02x, %02x, %02x, %02x"),
pMsg->selfMacAddr[0],
pMsg->selfMacAddr[1],
pMsg->selfMacAddr[2],
@@ -13329,7 +13333,9 @@
} while( 0 );
return( status );
}
-eHalStatus csrIssueAddStaForSessionReq(tpAniSirGlobal pMac, tANI_U32 sessionId, tSirMacAddr sessionMacAddr)
+eHalStatus csrIssueAddStaForSessionReq(tpAniSirGlobal pMac,
+ tANI_U32 sessionId,
+ tSirMacAddr sessionMacAddr)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
tSmeCmd *pCommand;
@@ -13343,6 +13349,7 @@
pCommand->command = eSmeCommandAddStaSession;
pCommand->sessionId = (tANI_U8)sessionId;
palCopyMemory( pMac->hHdd, pCommand->u.addStaSessionCmd.selfMacAddr, sessionMacAddr, sizeof( tSirMacAddr ) );
+ pCommand->u.addStaSessionCmd.currDeviceMode = pMac->sme.currDeviceMode;
status = csrQueueSmeCommand(pMac, pCommand, TRUE);
if( !HAL_STATUS_SUCCESS( status ) )
{
@@ -13354,11 +13361,12 @@
}
eHalStatus csrProcessAddStaSessionCommand( tpAniSirGlobal pMac, tSmeCmd *pCommand )
{
- return csrSendMBAddSelfStaReqMsg( pMac,
- pCommand->u.addStaSessionCmd.selfMacAddr );
+ return csrSendMBAddSelfStaReqMsg(pMac, &pCommand->u.addStaSessionCmd);
}
-eHalStatus csrRoamOpenSession( tpAniSirGlobal pMac, csrRoamCompleteCallback callback, void *pContext,
- tANI_U8 *pSelfMacAddr, tANI_U8 *pbSessionId )
+eHalStatus csrRoamOpenSession(tpAniSirGlobal pMac,
+ csrRoamCompleteCallback callback,
+ void *pContext, tANI_U8 *pSelfMacAddr,
+ tANI_U8 *pbSessionId)
{
eHalStatus status = eHAL_STATUS_SUCCESS;
tANI_U32 i;
@@ -13401,7 +13409,7 @@
smsLog(pMac, LOGE, FL("cannot allocate memory for IbssJoining timer"));
break;
}
- status = csrIssueAddStaForSessionReq ( pMac, i, pSelfMacAddr );
+ status = csrIssueAddStaForSessionReq (pMac, i, pSelfMacAddr);
break;
}
}
diff --git a/CORE/SME/src/csr/csrInsideApi.h b/CORE/SME/src/csr/csrInsideApi.h
index ae49b10..139513d 100644
--- a/CORE/SME/src/csr/csrInsideApi.h
+++ b/CORE/SME/src/csr/csrInsideApi.h
@@ -410,8 +410,10 @@
//pIes cannot be NULL
tANI_BOOLEAN csrMatchCountryCode( tpAniSirGlobal pMac, tANI_U8 *pCountry, tDot11fBeaconIEs *pIes );
eHalStatus csrRoamSetKey( tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamSetKey *pSetKey, tANI_U32 roamId );
-eHalStatus csrRoamOpenSession( tpAniSirGlobal pMac, csrRoamCompleteCallback callback, void *pContext,
- tANI_U8 *pSelfMacAddr, tANI_U8 *pbSessionId );
+eHalStatus csrRoamOpenSession(tpAniSirGlobal pMac,
+ csrRoamCompleteCallback callback,
+ void *pContext, tANI_U8 *pSelfMacAddr,
+ tANI_U8 *pbSessionId);
//fSync: TRUE means cleanupneeds to handle synchronously.
eHalStatus csrRoamCloseSession( tpAniSirGlobal pMac, tANI_U32 sessionId,
tANI_BOOLEAN fSync,
diff --git a/CORE/SME/src/sme_common/sme_Api.c b/CORE/SME/src/sme_common/sme_Api.c
index 9df6c2b..6a47803 100644
--- a/CORE/SME/src/sme_common/sme_Api.c
+++ b/CORE/SME/src/sme_common/sme_Api.c
@@ -899,6 +899,7 @@
do {
pMac->sme.state = SME_STATE_STOP;
+ pMac->sme.currDeviceMode = VOS_STA_MODE;
if( !VOS_IS_STATUS_SUCCESS( vos_lock_init( &pMac->sme.lkSmeGlobalLock ) ) )
{
smsLog( pMac, LOGE, "sme_Open failed init lock" );
@@ -5115,8 +5116,9 @@
\sa
--------------------------------------------------------------------------*/
-eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback, void *pContext,
- tANI_U8 *pSelfMacAddr, tANI_U8 *pbSessionId)
+eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback,
+ void *pContext, tANI_U8 *pSelfMacAddr,
+ tANI_U8 *pbSessionId)
{
eHalStatus status;
tpAniSirGlobal pMac = PMAC_STRUCT( hHal );
@@ -5130,7 +5132,8 @@
status = sme_AcquireGlobalLock( &pMac->sme );
if ( HAL_STATUS_SUCCESS( status ) )
{
- status = csrRoamOpenSession( pMac, callback, pContext, pSelfMacAddr, pbSessionId );
+ status = csrRoamOpenSession(pMac, callback, pContext,
+ pSelfMacAddr, pbSessionId);
sme_ReleaseGlobalLock( &pMac->sme );
}
@@ -8544,6 +8547,20 @@
return VOS_STATUS_SUCCESS;
}
+/*--------------------------------------------------------------------------
+
+ \brief sme_SetCurrDeviceMode() - Sets the current operating device mode.
+ \param hHal - The handle returned by macOpen.
+ \param currDeviceMode - Current operating device mode.
+ --------------------------------------------------------------------------*/
+
+void sme_SetCurrDeviceMode (tHalHandle hHal, tVOS_CON_MODE currDeviceMode)
+{
+ tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ pMac->sme.currDeviceMode = currDeviceMode;
+ return;
+}
+
#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
/*--------------------------------------------------------------------------
\brief sme_HandoffRequest() - a wrapper function to Request a handoff
diff --git a/CORE/VOSS/inc/vos_types.h b/CORE/VOSS/inc/vos_types.h
index 1758d55..176ad6a 100644
--- a/CORE/VOSS/inc/vos_types.h
+++ b/CORE/VOSS/inc/vos_types.h
@@ -1,73 +1,36 @@
/*
- * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
- *
- * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
- *
- *
- * Permission to use, copy, modify, and/or distribute this software for
- * any purpose with or without fee is hereby granted, provided that the
- * above copyright notice and this permission notice appear in all
- * copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
- * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
- * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
- * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- * PERFORMANCE OF THIS SOFTWARE.
- */
-/*
- * Copyright (c) 2012, The Linux Foundation. All rights reserved.
- *
- * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
- *
- *
- * Permission to use, copy, modify, and/or distribute this software for
- * any purpose with or without fee is hereby granted, provided that the
- * above copyright notice and this permission notice appear in all
- * copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
- * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
- * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
- * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- * PERFORMANCE OF THIS SOFTWARE.
- */
-
+ * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
+ *
+ * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
+ *
+ *
+ * Permission to use, copy, modify, and/or distribute this software for
+ * any purpose with or without fee is hereby granted, provided that the
+ * above copyright notice and this permission notice appear in all
+ * copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
+ * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
+ * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+ * PERFORMANCE OF THIS SOFTWARE.
+*/
#if !defined( __VOS_TYPES_H )
#define __VOS_TYPES_H
-/*
-* Copyright (c) 2013 Qualcomm Atheros, Inc.
-* All Rights Reserved.
-* Qualcomm Atheros Confidential and Proprietary.
-*/
-
/**=========================================================================
\file vos_Types.h
\brief virtual Operating System Servies (vOS)
-<<<<<<< HEAD:CORE/VOSS/inc/vos_types.h
-
- Basic type definitions
-
- Copyright 2008 (c) Qualcomm, Incorporated. All Rights Reserved.
-
- Qualcomm Confidential and Proprietary.
-
-=======
Basic type definitions
- Copyright 2008 (c) Qualcomm, Incorporated.
+ Copyright 2008 (c) Qualcomm Technologies, Inc.
All Rights Reserved.
- Qualcomm Confidential and Proprietary.
->>>>>>> b682f18... wlan: qnx awareness to corestack:prima/CORE/VOSS/inc/vos_types.h
+ Qualcomm Technologies Confidential and Proprietary.
========================================================================*/
/* $Header$ */
@@ -169,8 +132,8 @@
VOS_MONITOR_MODE,
VOS_FTM_MODE = 5,
VOS_IBSS_MODE,
+ VOS_P2P_DEVICE,
VOS_MAX_NO_OF_MODE
-
} tVOS_CON_MODE;
//This is a bit pattern to be set for each mode
diff --git a/CORE/WDA/inc/legacy/halMsgApi.h b/CORE/WDA/inc/legacy/halMsgApi.h
index ff10c44..28c938c 100644
--- a/CORE/WDA/inc/legacy/halMsgApi.h
+++ b/CORE/WDA/inc/legacy/halMsgApi.h
@@ -1296,7 +1296,7 @@
typedef struct sAddStaSelfParams
{
tSirMacAddr selfMacAddr;
-
+ tVOS_CON_MODE currDeviceMode;
tANI_U32 status;
}tAddStaSelfParams, *tpAddStaSelfParams;
diff --git a/CORE/WDA/src/wlan_qct_wda.c b/CORE/WDA/src/wlan_qct_wda.c
index dd58ad4..0c89119 100644
--- a/CORE/WDA/src/wlan_qct_wda.c
+++ b/CORE/WDA/src/wlan_qct_wda.c
@@ -3486,6 +3486,7 @@
}
wdiAddStaSelfReq->wdiReqStatusCB = NULL;
vos_mem_copy( wdiAddStaSelfReq->wdiAddSTASelfInfo.selfMacAddr, pAddStaSelfReq->selfMacAddr, 6);
+ wdiAddStaSelfReq->wdiAddSTASelfInfo.currDeviceMode = pAddStaSelfReq->currDeviceMode;
/* Store Init Req pointer, as this will be used for response */
/* store Params pass it to WDI */
pWdaParams->pWdaContext = pWDA;
diff --git a/CORE/WDI/CP/inc/wlan_qct_wdi.h b/CORE/WDI/CP/inc/wlan_qct_wdi.h
index 4d84e07..33ef3e8 100644
--- a/CORE/WDI/CP/inc/wlan_qct_wdi.h
+++ b/CORE/WDI/CP/inc/wlan_qct_wdi.h
@@ -3112,6 +3112,9 @@
/*Self Station MAC address*/
wpt_macAddr selfMacAddr;
+ /*Self STA device mode*/
+ wpt_uint32 currDeviceMode;
+
/*Status of the operation*/
wpt_uint32 uStatus;
}WDI_AddSTASelfInfoType;
diff --git a/CORE/WDI/CP/src/wlan_qct_wdi.c b/CORE/WDI/CP/src/wlan_qct_wdi.c
index f8c2fb5..833f975 100644
--- a/CORE/WDI/CP/src/wlan_qct_wdi.c
+++ b/CORE/WDI/CP/src/wlan_qct_wdi.c
@@ -10152,7 +10152,7 @@
wpt_uint8* pSendBuffer = NULL;
wpt_uint16 usDataOffset = 0;
wpt_uint16 usSendSize = 0;
- tAddStaSelfParams halAddSTASelfParams;
+ tAddStaSelfParams_V1 halAddSTASelfParams;
/*- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
/*-------------------------------------------------------------------------
@@ -10177,9 +10177,9 @@
-----------------------------------------------------------------------*/
if (( WDI_STATUS_SUCCESS != WDI_GetMessageBuffer( pWDICtx,
WDI_ADD_STA_SELF_REQ,
- sizeof(tAddStaSelfParams),
+ sizeof(tAddStaSelfParams_V1),
&pSendBuffer, &usDataOffset, &usSendSize))||
- ( usSendSize < (usDataOffset + sizeof(tAddStaSelfParams) )))
+ ( usSendSize < (usDataOffset + sizeof(tAddStaSelfParams_V1) )))
{
WPAL_TRACE( eWLAN_MODULE_DAL_CTRL, eWLAN_PAL_TRACE_LEVEL_WARN,
"Unable to get send buffer in ADD STA SELF REQ %x %x %x",
@@ -10193,10 +10193,21 @@
sizeof(pWDICtx->wdiCacheAddSTASelfReq));
wpalMemoryCopy(halAddSTASelfParams.selfMacAddr,
- pwdiAddSTASelfReqParams->wdiAddSTASelfInfo.selfMacAddr, 6) ;
-
+ pwdiAddSTASelfReqParams->wdiAddSTASelfInfo.selfMacAddr, 6);
+ halAddSTASelfParams.iface_persona = HAL_IFACE_UNKNOWN;
+ if (pwdiAddSTASelfReqParams->wdiAddSTASelfInfo.currDeviceMode == VOS_STA_MODE)
+ {
+ halAddSTASelfParams.iface_persona = HAL_IFACE_STA_MODE;
+ }
+ else if ((pwdiAddSTASelfReqParams->wdiAddSTASelfInfo.currDeviceMode ==
+ VOS_P2P_CLIENT_MODE) ||
+ (pwdiAddSTASelfReqParams->wdiAddSTASelfInfo.currDeviceMode ==
+ VOS_P2P_DEVICE))
+ {
+ halAddSTASelfParams.iface_persona = HAL_IFACE_P2P_MODE;
+ }
wpalMemoryCopy( pSendBuffer+usDataOffset, &halAddSTASelfParams,
- sizeof(tAddStaSelfParams));
+ sizeof(tAddStaSelfParams_V1));
pWDICtx->wdiReqStatusCB = pwdiAddSTASelfReqParams->wdiReqStatusCB;
pWDICtx->pReqStatusUserData = pwdiAddSTASelfReqParams->pUserData;
diff --git a/riva/inc/wlan_hal_msg.h b/riva/inc/wlan_hal_msg.h
index a38799b..1233239 100644
--- a/riva/inc/wlan_hal_msg.h
+++ b/riva/inc/wlan_hal_msg.h
@@ -1644,6 +1644,15 @@
HAL_MAX_CONCURRENCY_PERSONA=4
} tHalConcurrencyMode;
+// IFACE PERSONA for different Operating modes
+typedef enum
+{
+ HAL_IFACE_UNKNOWN,
+ HAL_IFACE_STA_MODE,
+ HAL_IFACE_P2P_MODE,
+ HAL_IFACE_MAX
+} tHalIfacePersona;
+
typedef PACKED_PRE struct PACKED_POST
{
/* BSSID */
@@ -4563,11 +4572,20 @@
tANI_U32 status;
}tAddStaSelfParams, *tpAddStaSelfParams;
+typedef PACKED_PRE struct PACKED_POST
+{
+ tSirMacAddr selfMacAddr;
+ tANI_U32 status;
+ tHalIfacePersona iface_persona;
+}tAddStaSelfParams_V1, *tpAddStaSelfParams_V1;
typedef PACKED_PRE struct PACKED_POST
{
tHalMsgHeader header;
+ PACKED_PRE union PACKED_POST {
tAddStaSelfParams addStaSelfParams;
+ tAddStaSelfParams_V1 addStaSelfParams_V1;
+ }uAddStaSelfParams;
}tAddStaSelfReq, *tpAddStaSelfReq;
/*---------------------------------------------------------------------------