瀏覽代碼

qcacld-3.0: Enable OBSS scan for open mode after connection

Enable OBSS scan for open mode after connection and optimize the
logs in OBSS path.

Change-Id: I91eefc2fe368f5f92e7345aed87591a8b3fdd913
CRs-Fixed: 3006209
Abhishek Singh 3 年之前
父節點
當前提交
19c5bff34a

+ 5 - 15
core/mac/src/pe/lim/lim_process_message_queue.c

@@ -1559,25 +1559,15 @@ static void lim_process_sme_obss_scan_ind(struct mac_context *mac_ctx,
 	session = pe_find_session_by_bssid(mac_ctx,
 			ht40_scanind->mac_addr.bytes, &session_id);
 	if (!session) {
-		QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_DEBUG,
-			"OBSS Scan not started: session id is NULL");
+		pe_err("OBSS Scan not started: session id is NULL");
 		return;
 	}
+	pe_debug("OBSS Scan Req: vdev %d (pe session %d) htSupportedChannelWidthSet %d",
+		 session->vdev_id, session->peSessionId,
+		 session->htSupportedChannelWidthSet);
 	if (session->htSupportedChannelWidthSet ==
-			WNI_CFG_CHANNEL_BONDING_MODE_ENABLE) {
-		QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_DEBUG,
-			"OBSS Scan Start Req: session id %d"
-			"htSupportedChannelWidthSet %d",
-			session->peSessionId,
-			session->htSupportedChannelWidthSet);
+	    WNI_CFG_CHANNEL_BONDING_MODE_ENABLE)
 		lim_send_ht40_obss_scanind(mac_ctx, session);
-	} else {
-		QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_DEBUG,
-			"OBSS Scan not started: channel width - %d session %d",
-			session->htSupportedChannelWidthSet,
-			session->peSessionId);
-	}
-	return;
 }
 
 /**

+ 4 - 7
core/mac/src/pe/lim/lim_send_messages.c

@@ -478,9 +478,6 @@ QDF_STATUS lim_send_ht40_obss_scanind(struct mac_context *mac_ctx,
 	ht40_obss_scanind = qdf_mem_malloc(sizeof(struct obss_ht40_scanind));
 	if (!ht40_obss_scanind)
 		return QDF_STATUS_E_FAILURE;
-	QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_ERROR,
-		  "OBSS Scan Indication bssid " QDF_MAC_ADDR_FMT,
-		  QDF_MAC_ADDR_REF(session->bssId));
 
 	ht40_obss_scanind->cmd = HT40_OBSS_SCAN_PARAM_START;
 	ht40_obss_scanind->scan_type = eSIR_ACTIVE_SCAN;
@@ -527,10 +524,10 @@ QDF_STATUS lim_send_ht40_obss_scanind(struct mac_context *mac_ctx,
 	msg.reserved = 0;
 	msg.bodyptr = (void *)ht40_obss_scanind;
 	msg.bodyval = 0;
-	pe_debug("Sending WDA_HT40_OBSS_SCAN_IND to WDA"
-		"Obss Scan trigger width: %d, delay factor: %d",
-		ht40_obss_scanind->obss_width_trigger_interval,
-		ht40_obss_scanind->bsswidth_ch_trans_delay);
+	pe_debug("Obss Scan trigger width: %d, delay factor: %d bssid " QDF_MAC_ADDR_FMT,
+		 ht40_obss_scanind->obss_width_trigger_interval,
+		 ht40_obss_scanind->bsswidth_ch_trans_delay,
+		 QDF_MAC_ADDR_REF(session->bssId));
 	ret = wma_post_ctrl_msg(mac_ctx, &msg);
 	if (QDF_STATUS_SUCCESS != ret) {
 		pe_err("WDA_HT40_OBSS_SCAN_IND msg failed, reason=%X",

+ 8 - 1
core/sme/src/csr/csr_api_roam.c

@@ -3906,6 +3906,11 @@ csr_roam_chk_lnk_set_ctx_rsp(struct mac_context *mac_ctx, tSirSmeRsp *msg_ptr)
 							 sessionId);
 	wlan_mlme_get_bssid_vdev_id(mac_ctx->pdev, sessionId,
 				    &connected_bssid);
+	sme_debug("vdev %d, Status %d, peer_macaddr "QDF_MAC_ADDR_FMT " obss offload %d freq %d opmode %d",
+		  pRsp->sessionId, pRsp->status_code,
+		  QDF_MAC_ADDR_REF(pRsp->peer_macaddr.bytes),
+		  mac_ctx->obss_scan_offload, chan_freq,
+		  wlan_get_opmode_vdev_id(mac_ctx->pdev, sessionId));
 
 	if (CSR_IS_WAIT_FOR_KEY(mac_ctx, sessionId)) {
 		/* We are done with authentication, whethere succeed or not */
@@ -6359,6 +6364,7 @@ cm_csr_connect_done_ind(struct wlan_objmgr_vdev *vdev,
 	struct wlan_mlme_psoc_ext_obj *mlme_obj;
 	struct dual_sta_policy *dual_sta_policy;
 	bool enable_mcc_adaptive_sch = false;
+	struct qdf_mac_addr bc_mac = QDF_MAC_ADDR_BCAST_INIT;
 
 	/*
 	 * This API is to update legacy struct and should be removed once
@@ -6437,7 +6443,8 @@ cm_csr_connect_done_ind(struct wlan_objmgr_vdev *vdev,
 		install_key_rsp.length = sizeof(install_key_rsp);
 		install_key_rsp.status_code = eSIR_SME_SUCCESS;
 		install_key_rsp.sessionId = vdev_id;
-		qdf_copy_macaddr(&install_key_rsp.peer_macaddr, &rsp->bssid);
+		/* use BC mac to enable OBSS scan */
+		qdf_copy_macaddr(&install_key_rsp.peer_macaddr, &bc_mac);
 		csr_roam_chk_lnk_set_ctx_rsp(mac_ctx,
 					     (tSirSmeRsp *)&install_key_rsp);
 	}