Browse Source

qcacld-3.0: Block ADDROAMSCANCHANNELS if specific channels configured

User configures specific channel using SETROAMSCANCHANNELS command
and preferred channels using ADDROAMSCANCHANNELS command.

For roam scanning, "specific channels list" is preferred over
"preferred channel list". Hence if user configured specific channels
then block ADDROAMSCANCHANNLES command.

Change-Id: Ib4e2c9ed7ca1e44c0c7e287e2ac350c3d4f3540e
CRs-Fixed: 2610133
Abhishek Ambure 5 years ago
parent
commit
843ece96eb
1 changed files with 6 additions and 0 deletions
  1. 6 0
      core/sme/src/common/sme_api.c

+ 6 - 0
core/sme/src/common/sme_api.c

@@ -7462,6 +7462,12 @@ sme_update_roam_scan_freq_list(mac_handle_t mac_handle, uint8_t vdev_id,
 	}
 
 	neighbor_roam_info = &mac->roam.neighborRoamInfo[vdev_id];
+	if (neighbor_roam_info->cfgParams.specific_chan_info.numOfChannels) {
+		sme_err("Specific channel list is already configured");
+		sme_release_global_lock(&mac->sme);
+		return QDF_STATUS_E_INVAL;
+	}
+
 	if (freq_list_type == QCA_PREFERRED_SCAN_FREQ_LIST) {
 		sme_debug("Preferred frequency list: ");
 		channel_info = &neighbor_roam_info->cfgParams.pref_chan_info;