diff options
| author | Ryan Hsu <ryanhsu@qca.qualcomm.com> | 2014-09-11 07:50:39 -0700 |
|---|---|---|
| committer | Akash Patel <c_akashp@qca.qualcomm.com> | 2014-09-12 20:31:08 -0700 |
| commit | b082b68db81d09bb5cfb23ee2d747caaa1b13a5d (patch) | |
| tree | 1df046ca6a36886e2fa69350a1048c0e87f0429b | |
| parent | 5dae33cb63dbe7e683afdfcb6786566f891d8195 (diff) | |
qcacld: UMAC: Updating the probe response ssid from PE session
In the case of multiple bssid, when PE prepares the probe response
template, it should populate the ssid string from PE session
instead of the configuration string, which might store the other
BSS's ssid info.
Change-Id: I0c593b37264db37a5a7704d339c4863c8222592a
CRs-fixed: 723095
| -rw-r--r-- | CORE/MAC/src/pe/include/schApi.h | 3 | ||||
| -rw-r--r-- | CORE/MAC/src/pe/sch/schBeaconGen.c | 35 |
2 files changed, 29 insertions, 9 deletions
diff --git a/CORE/MAC/src/pe/include/schApi.h b/CORE/MAC/src/pe/include/schApi.h index 111480b0a827..3c45a8b9bdce 100644 --- a/CORE/MAC/src/pe/include/schApi.h +++ b/CORE/MAC/src/pe/include/schApi.h @@ -93,7 +93,8 @@ void schSetBeaconInterval(tpAniSirGlobal pMac,tpPESession psessionEntry); tSirRetStatus schSendBeaconReq( tpAniSirGlobal, tANI_U8 *, tANI_U16, tpPESession psessionEntry ); -void limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal,tDot11fBeacon1*,tANI_U32*,tDot11fProbeResponse*); +tSirRetStatus limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal, + tDot11fBeacon1*, tpPESession psessionEntry); void limUpdateProbeRspTemplateIeBitmapBeacon2(tpAniSirGlobal,tDot11fBeacon2*,tANI_U32*,tDot11fProbeResponse*); void SetProbeRspIeBitmap(tANI_U32*,tANI_U32); tANI_U32 limSendProbeRspTemplateToHal(tpAniSirGlobal,tpPESession, diff --git a/CORE/MAC/src/pe/sch/schBeaconGen.c b/CORE/MAC/src/pe/sch/schBeaconGen.c index 7be0d7464122..10e7b7ef3aa7 100644 --- a/CORE/MAC/src/pe/sch/schBeaconGen.c +++ b/CORE/MAC/src/pe/sch/schBeaconGen.c @@ -275,9 +275,14 @@ tSirRetStatus schSetFixedBeaconFields(tpAniSirGlobal pMac,tpPESession psessionEn vos_mem_set(( tANI_U8* )&(psessionEntry->probeRespFrame), sizeof(psessionEntry->probeRespFrame), 0); - /* Can be efficiently updated whenever new IE added in Probe response in future */ - limUpdateProbeRspTemplateIeBitmapBeacon1(pMac,pBcn1,&psessionEntry->DefProbeRspIeBitmap[0], - &psessionEntry->probeRespFrame); + /* Can be efficiently updated whenever new IE added + * in Probe response in future + */ + if (limUpdateProbeRspTemplateIeBitmapBeacon1(pMac, pBcn1, + psessionEntry) != eSIR_SUCCESS) { + schLog(pMac, LOGE, + FL("Failed to build ProbeRsp template")); + } } nStatus = dot11fPackBeacon1( pMac, pBcn1, ptr, @@ -511,11 +516,21 @@ tSirRetStatus schSetFixedBeaconFields(tpAniSirGlobal pMac,tpPESession psessionEn return eSIR_SUCCESS; } -void limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal pMac, +tSirRetStatus limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal pMac, tDot11fBeacon1* beacon1, - tANI_U32* DefProbeRspIeBitmap, - tDot11fProbeResponse* prb_rsp) + tpPESession psessionEntry) { + tANI_U32* DefProbeRspIeBitmap; + tDot11fProbeResponse* prb_rsp; + + if (!psessionEntry) { + schLog(pMac, LOGE, FL("PESession is null!")); + return eSIR_FAILURE; + } + + DefProbeRspIeBitmap = &psessionEntry->DefProbeRspIeBitmap[0]; + prb_rsp = &psessionEntry->probeRespFrame; + prb_rsp->BeaconInterval = beacon1->BeaconInterval; vos_mem_copy((void *)&prb_rsp->Capabilities, (void *)&beacon1->Capabilities, sizeof(beacon1->Capabilities)); @@ -524,8 +539,10 @@ void limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal pMac, if(beacon1->SSID.present) { SetProbeRspIeBitmap(DefProbeRspIeBitmap,SIR_MAC_SSID_EID); - /* populating it, because probe response has to go with SSID even in hidden case */ - PopulateDot11fSSID2( pMac, &prb_rsp->SSID ); + /* populating it, because probe response has to go with + * SSID even in hidden case + */ + PopulateDot11fSSID(pMac, &psessionEntry->ssId, &prb_rsp->SSID); } /* supported rates */ if(beacon1->SuppRates.present) @@ -545,6 +562,8 @@ void limUpdateProbeRspTemplateIeBitmapBeacon1(tpAniSirGlobal pMac, } /* IBSS params will not be present in the Beacons transmitted by AP */ + + return eSIR_SUCCESS; } void limUpdateProbeRspTemplateIeBitmapBeacon2(tpAniSirGlobal pMac, |
