ソースを参照

qcacmn: Fix return values of Spectral target APIs

Return type of "target_if_is_spectral_active" and
"target_if_is_spectral_enabled" is bool. Wrong return values
are send for this APIs in case of errors.

CRs-Fixed: 2845250
Change-Id: I2344676a1ada51e041bb5f7acac8aa22847bee5c
Edayilliam Jayadev 4 年 前
コミット
445c0a42c3
1 ファイル変更6 行追加6 行削除
  1. 6 6
      target_if/spectral/target_if_spectral.c

+ 6 - 6
target_if/spectral/target_if_spectral.c

@@ -4876,19 +4876,19 @@ target_if_is_spectral_active(struct wlan_objmgr_pdev *pdev,
 
 	if (!spectral) {
 		spectral_err("SPECTRAL : Module doesn't exist");
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	p_sops = GET_TARGET_IF_SPECTRAL_OPS(spectral);
 
 	if (!p_sops) {
 		spectral_err("p_sops is null");
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	if (smode >= SPECTRAL_SCAN_MODE_MAX) {
 		spectral_err("Invalid Spectral mode %u", smode);
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	return p_sops->is_spectral_active(spectral, smode);
@@ -4914,19 +4914,19 @@ target_if_is_spectral_enabled(struct wlan_objmgr_pdev *pdev,
 
 	if (!spectral) {
 		spectral_err("SPECTRAL : Module doesn't exist");
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	p_sops = GET_TARGET_IF_SPECTRAL_OPS(spectral);
 
 	if (!p_sops) {
 		spectral_err("p_sops is null");
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	if (smode >= SPECTRAL_SCAN_MODE_MAX) {
 		spectral_err("Invalid Spectral mode %u", smode);
-		return QDF_STATUS_E_FAILURE;
+		return false;
 	}
 
 	return p_sops->is_spectral_enabled(spectral, smode);