Преглед на файлове

cnss2: Skip HW re-enable if HW is already probed at boot

Peripheral control service can send notification to enable WLAN HW
even if HW is already enabled at boot. Thus skip wlan device pci
re-enumeration if PCI probe is already complete.

Change-Id: I5687b9ee74afe9331e11ec1fc5f1cf20f94117c8
CRs-fixed: 3224613
Manikandan Mohan преди 2 години
родител
ревизия
fc97f926b0
променени са 1 файла, в които са добавени 3 реда и са изтрити 0 реда
  1. 3 0
      cnss2/main.c

+ 3 - 0
cnss2/main.c

@@ -3979,6 +3979,9 @@ int cnss_wlan_hw_enable(void)
 	struct cnss_plat_data *plat_priv = cnss_get_plat_priv(NULL);
 	int ret = 0;
 
+	if (test_bit(CNSS_PCI_PROBE_DONE, &plat_priv->driver_state))
+		return 0;
+
 	clear_bit(CNSS_WLAN_HW_DISABLED, &plat_priv->driver_state);
 
 	ret = cnss_wlan_device_init(plat_priv);