Merge "qcacld-3.0: Fix buffer overflow" into wlan-cld3.driver.lnx.1.1-dev
此提交包含在:

提交者
Gerrit - the friendly Code Review server

當前提交
061013e1ea
@@ -50,37 +50,32 @@
|
|||||||
#define LIM_START_PEER_IDX 1
|
#define LIM_START_PEER_IDX 1
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* lim_init_peer_idxpool()
|
* lim_init_peer_idxpool() -- initializes peer index pool
|
||||||
|
* @pMac: mac context
|
||||||
|
* @pSessionEntry: session entry
|
||||||
*
|
*
|
||||||
***FUNCTION:
|
|
||||||
* This function is called while starting a BSS at AP
|
* This function is called while starting a BSS at AP
|
||||||
* to initialize AID pool. This may also be called while
|
* to initialize AID pool. This may also be called while
|
||||||
* starting/joining an IBSS if 'Association' is allowed
|
* starting/joining an IBSS if 'Association' is allowed
|
||||||
* in IBSS.
|
* in IBSS.
|
||||||
*
|
*
|
||||||
***LOGIC:
|
* Return: None
|
||||||
*
|
|
||||||
***ASSUMPTIONS:
|
|
||||||
* NA
|
|
||||||
*
|
|
||||||
***NOTE:
|
|
||||||
* NA
|
|
||||||
*
|
|
||||||
* @param pMac - Pointer to Global MAC structure
|
|
||||||
* @return None
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void lim_init_peer_idxpool(tpAniSirGlobal pMac, tpPESession pSessionEntry)
|
void lim_init_peer_idxpool(tpAniSirGlobal pMac, tpPESession pSessionEntry)
|
||||||
{
|
{
|
||||||
uint8_t i;
|
uint8_t i;
|
||||||
uint8_t maxAssocSta = pMac->lim.gLimAssocStaLimit;
|
uint8_t maxAssocSta = pMac->lim.maxStation;
|
||||||
|
|
||||||
pSessionEntry->gpLimPeerIdxpool[0] = 0;
|
pSessionEntry->gpLimPeerIdxpool[0] = 0;
|
||||||
|
|
||||||
#ifdef FEATURE_WLAN_TDLS
|
#ifdef FEATURE_WLAN_TDLS
|
||||||
/* In station role, DPH_STA_HASH_INDEX_PEER (index 1) is reserved for peer */
|
/*
|
||||||
/* station index corresponding to AP. Avoid choosing that index and get index */
|
* In station role, DPH_STA_HASH_INDEX_PEER (index 1) is reserved
|
||||||
/* starting from (DPH_STA_HASH_INDEX_PEER + 1) (index 2) for TDLS stations; */
|
* for peer station index corresponding to AP. Avoid choosing that index
|
||||||
|
* and get index starting from (DPH_STA_HASH_INDEX_PEER + 1)
|
||||||
|
* (index 2) for TDLS stations;
|
||||||
|
*/
|
||||||
if (LIM_IS_STA_ROLE(pSessionEntry)) {
|
if (LIM_IS_STA_ROLE(pSessionEntry)) {
|
||||||
pSessionEntry->freePeerIdxHead = DPH_STA_HASH_INDEX_PEER + 1;
|
pSessionEntry->freePeerIdxHead = DPH_STA_HASH_INDEX_PEER + 1;
|
||||||
} else
|
} else
|
||||||
@@ -88,7 +83,6 @@ void lim_init_peer_idxpool(tpAniSirGlobal pMac, tpPESession pSessionEntry)
|
|||||||
#ifdef QCA_IBSS_SUPPORT
|
#ifdef QCA_IBSS_SUPPORT
|
||||||
if (LIM_IS_IBSS_ROLE(pSessionEntry)) {
|
if (LIM_IS_IBSS_ROLE(pSessionEntry)) {
|
||||||
pSessionEntry->freePeerIdxHead = LIM_START_PEER_IDX;
|
pSessionEntry->freePeerIdxHead = LIM_START_PEER_IDX;
|
||||||
maxAssocSta = pMac->lim.gLimIbssStaLimit;
|
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
|
新增問題並參考
封鎖使用者