Jelajahi Sumber

qcacld-3.0: Check for NAN state only if NAN SM is in host

A check is added recently to avoid creating NDI if NAN is not in
enabled state. This is to avoid wastage of resources(vdev, peers,..)
in firmware.But this check is valid only for the platforms where NAN
statemachine is in host driver. This check is not valid for legacy
platforms where NAN state machine is in firmware. Bypass the same
for legacy targets.

CRs-Fixed: 3178939
Change-Id: I1475b4313d1e7ac2c05d5edd215e929f3eb6335e
Rahul Gusain 2 tahun lalu
induk
melakukan
8b3684b10a
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      os_if/nan/src/os_if_nan.c

+ 2 - 1
os_if/nan/src/os_if_nan.c

@@ -1169,7 +1169,8 @@ int os_if_nan_process_ndp_cmd(struct wlan_objmgr_psoc *psoc,
 		 * lead to issues if NDI has to be started in a
 		 * 2GHz channel and if the target is not operating in DBS mode.
 		 */
-		if (!ucfg_is_nan_disc_active(psoc)) {
+		if ((ucfg_is_nan_conc_control_supported(psoc)) &&
+		    (!ucfg_is_nan_disc_active(psoc))) {
 			osif_err("NDI creation is not allowed when NAN discovery is not running");
 			return -EOPNOTSUPP;
 		}