소스 검색

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);