Sfoglia il codice sorgente

qcacld-3.0: Disable wlan suspend for monitor mode

Wlan suspend and WOW is not supported in monitor mode, disable them.

Change-Id: I5654cb837d01f78d08ae006040cc4f16cd6b3a36
CRs-Fixed: 2500835
Jinwei Chen 5 anni fa
parent
commit
763f9d726f
1 ha cambiato i file con 8 aggiunte e 4 eliminazioni
  1. 8 4
      core/hdd/src/wlan_hdd_power.c

+ 8 - 4
core/hdd/src/wlan_hdd_power.c

@@ -1612,8 +1612,10 @@ static int __wlan_hdd_cfg80211_resume_wlan(struct wiphy *wiphy)
 		goto exit_with_code;
 	}
 
-	if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam()) {
-		hdd_err("Command not allowed in FTM mode");
+	if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam() ||
+	    QDF_GLOBAL_MONITOR_MODE == hdd_get_conparam()) {
+		hdd_err("Command not allowed in mode %d",
+			hdd_get_conparam());
 		exit_code = -EINVAL;
 		goto exit_with_code;
 	}
@@ -1717,8 +1719,10 @@ static int __wlan_hdd_cfg80211_suspend_wlan(struct wiphy *wiphy,
 
 	hdd_enter();
 
-	if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam()) {
-		hdd_err("Command not allowed in FTM mode");
+	if (QDF_GLOBAL_FTM_MODE == hdd_get_conparam() ||
+	    QDF_GLOBAL_MONITOR_MODE == hdd_get_conparam()) {
+		hdd_err("Command not allowed in mode %d",
+			hdd_get_conparam());
 		return -EINVAL;
 	}