qcacmn: Reduce logging in get 6G power type for country API

Optimize the checks in reg_get_6g_power_type_for_ctry API to
reduce logging. Logs will appear only during initial connection
and not after parsing each beacon.

Change-Id: I4c4904c4825cd822d119e4ee9b2c69e96612be31
CRs-Fixed: 3094366
This commit is contained in:
Gururaj Pandurangi 2021-12-14 21:51:36 -08:00 • committed by Vinod Kumar Pirla
commit e19169dc46

View file

@ -350,10 +350,14 @@ reg_get_6g_power_type_for_ctry(struct wlan_objmgr_psoc *psoc,
return QDF_STATUS_E_NOSUPPORT;
}
if (wlan_reg_is_etsi(sta_ctry)) {
reg_debug("STA ctry:%c%c, doesn't match with AP ctry, switch to VLP",
sta_ctry[0], sta_ctry[1]);
*pwr_type_6g = REG_VERY_LOW_POWER_AP;
if (wlan_reg_is_etsi(sta_ctry) &&
ap_pwr_type != REG_MAX_AP_TYPE) {
if (!(wlan_reg_is_us(ap_ctry) &&
ap_pwr_type == REG_INDOOR_AP)) {
reg_debug("STA ctry:%c%c, doesn't match with AP ctry, switch to VLP",
sta_ctry[0], sta_ctry[1]);
*pwr_type_6g = REG_VERY_LOW_POWER_AP;
}
}
if (wlan_reg_is_us(ap_ctry) && ap_pwr_type == REG_INDOOR_AP) {