prima: WLAN Driver Release 3.2.0.9
diff --git a/CORE/SME/src/csr/csrNeighborRoam.c b/CORE/SME/src/csr/csrNeighborRoam.c
index c1d710e..e2919d1 100644
--- a/CORE/SME/src/csr/csrNeighborRoam.c
+++ b/CORE/SME/src/csr/csrNeighborRoam.c
@@ -375,7 +375,15 @@
 
     /* Abort any ongoing BG scans */
     if (eANI_BOOLEAN_TRUE == pNeighborRoamInfo->scanRspPending)
+    {
+        if( pMac->roam.neighborRoamInfo.neighborRoamState != eCSR_NEIGHBOR_ROAM_STATE_CONNECTED)
+        {
+            smsLog(pMac, LOGE, FL("Connected during scan state and we didn't"
+                                    "transition to state"));
+            VOS_ASSERT(0);
+        }
         csrScanAbortMacScan(pMac);
+    }
 
     pNeighborRoamInfo->scanRspPending = eANI_BOOLEAN_FALSE;
     
@@ -1133,11 +1141,13 @@
     vos_mem_zero(&pNeighborRoamInfo->FTRoamInfo.neighboReportBssInfo, sizeof(tCsrNeighborReportBssInfo) * MAX_BSS_IN_NEIGHBOR_RPT);
 #endif
 
+    /* Transition to CONNECTED state */
+    CSR_NEIGHBOR_ROAM_STATE_TRANSITION(eCSR_NEIGHBOR_ROAM_STATE_CONNECTED)
+
     /* Reset all the necessary variables before transitioning to the CONNECTED state */
     csrNeighborRoamResetConnectedStateControlInfo(pMac);
 
-    /* Transition to CONNECTED state */
-    CSR_NEIGHBOR_ROAM_STATE_TRANSITION(eCSR_NEIGHBOR_ROAM_STATE_CONNECTED)
+   
     /* Re-register Neighbor Lookup threshold callback with TL */
     NEIGHBOR_ROAM_DEBUG(pMac, LOG2, FL("Registering DOWN event neighbor lookup callback with TL for RSSI = %d"), pNeighborRoamInfo->currentNeighborLookupThreshold * (-1)); 
     vosStatus = WLANTL_RegRSSIIndicationCB(pMac->roam.gVosContext, (v_S7_t)pNeighborRoamInfo->currentNeighborLookupThreshold * (-1),
@@ -1722,25 +1732,11 @@
         {
             if (pNeighborBssDesc->pNeighborBssDescription->channel)
             {
-                // Make sure to add only if its the same band
-                if ((pNeighborRoamInfo->currAPoperationChannel <= (RF_CHAN_14+1)) &&
-                    (pNeighborBssDesc->pNeighborBssDescription->channel <= (RF_CHAN_14+1)))
-                {
                         VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, 
                                 "%s: [INFOLOG] Adding %d to Neighbor channel list\n", __func__,
                                 pNeighborBssDesc->pNeighborBssDescription->channel);
                         channelList[numChannels] = pNeighborBssDesc->pNeighborBssDescription->channel;
                         numChannels++;
-                }
-                else if ((pNeighborRoamInfo->currAPoperationChannel >= RF_CHAN_128) &&
-                    (pNeighborBssDesc->pNeighborBssDescription->channel >= RF_CHAN_128))
-                {
-                        VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, 
-                                "%s: [INFOLOG] Adding %d to Neighbor channel list\n", __func__,
-                                pNeighborBssDesc->pNeighborBssDescription->channel);
-                        channelList[numChannels] = pNeighborBssDesc->pNeighborBssDescription->channel;
-                        numChannels++;
-                }
             }
         }
             
@@ -1762,27 +1758,12 @@
             {
                 if (pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i])
                 {
-                    // Make sure to add only if its the same band
-                    if ((pNeighborRoamInfo->currAPoperationChannel <= (RF_CHAN_14+1)) &&
-                        (pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i] <= (RF_CHAN_14+1)))
-                    {
                             VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, 
                                     "%s: [INFOLOG] Adding extra %d to Neighbor channel list\n", __func__,
                             pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i]);
                             channelList[numChannels] = 
                             pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i];
                             numChannels++;
-                    }
-                    if ((pNeighborRoamInfo->currAPoperationChannel >= RF_CHAN_128) &&
-                         (pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i] >= RF_CHAN_128))
-                    {
-                            VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_INFO, 
-                                    "%s: [INFOLOG] Adding extra %d to Neighbor channel list\n", __func__,
-                                pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i]);
-                            channelList[numChannels] = 
-                                pNeighborRoamInfo->roamChannelInfo.currentChannelListInfo.ChannelList[i];
-                            numChannels++;
-                    }
                 }
             }
         }
@@ -1961,25 +1942,11 @@
         {
             if (pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i])
             {
-                // Make sure to add only if its the same band
-                if ((pNeighborRoamInfo->currAPoperationChannel <= (RF_CHAN_14+1)) &&
-                    (pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i] <= (RF_CHAN_14+1)))
-                {
                         VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR, 
                                 "%s: [INFOLOG] Adding %d to Neighbor channel list\n", __func__,
                                 pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i]);
                         channelList[numOfChannels] = pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i];
                         numOfChannels++;
-                }
-                if ((pNeighborRoamInfo->currAPoperationChannel >= RF_CHAN_128) &&
-                    (pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i] >= RF_CHAN_128))
-                {
-                        VOS_TRACE (VOS_MODULE_ID_SME, VOS_TRACE_LEVEL_ERROR, 
-                                "%s: [INFOLOG] Adding %d to Neighbor channel list\n", __func__,
-                                pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i]);
-                        channelList[numOfChannels] = pNeighborRoamInfo->cfgParams.channelInfo.ChannelList[i];
-                        numOfChannels++;
-                }
             }
         }
 
@@ -2096,12 +2063,13 @@
 
     pNeighborRoamInfo->currentNeighborLookupThreshold = pNeighborRoamInfo->cfgParams.neighborLookupThreshold;
     
-    /* Reset all the neighbor roam info control variables. Free all the allocated memory. It is like we are just associated now */
-    csrNeighborRoamResetConnectedStateControlInfo(pMac);
-
     /* Recheck whether the below check is needed. */
     if (pNeighborRoamInfo->neighborRoamState != eCSR_NEIGHBOR_ROAM_STATE_CONNECTED)
         CSR_NEIGHBOR_ROAM_STATE_TRANSITION(eCSR_NEIGHBOR_ROAM_STATE_CONNECTED)
+
+    /* Reset all the neighbor roam info control variables. Free all the allocated memory. It is like we are just associated now */
+    csrNeighborRoamResetConnectedStateControlInfo(pMac);
+
     
     NEIGHBOR_ROAM_DEBUG(pMac, LOG2, FL("Registering DOWN event neighbor lookup callback with TL. RSSI = %d,"), pNeighborRoamInfo->currentNeighborLookupThreshold * (-1));
     /* Register Neighbor Lookup threshold callback with TL for DOWN event now */