Browse Source

qcacld-3.0: clear DEVICE_IFACE_OPENED before starting idle timer

Idle shutdown timer will be triggered once all interfaces are closed.
Clear interface open flag before idle timer triggered.

Change-Id: Ib4a238ccb11ca6d418788d62df44ba800928fdf1
CRs-Fixed: 3374187
Kai Liu 2 years ago
parent
commit
6d6aaec9b7
1 changed files with 3 additions and 4 deletions
  1. 3 4
      core/hdd/src/wlan_hdd_main.c

+ 3 - 4
core/hdd/src/wlan_hdd_main.c

@@ -1,6 +1,6 @@
 /*
  * Copyright (c) 2012-2021 The Linux Foundation. All rights reserved.
- * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) 2021-2023 Qualcomm Innovation Center, Inc. All rights reserved.
  *
  * Permission to use, copy, modify, and/or distribute this software for
  * any purpose with or without fee is hereby granted, provided that the
@@ -4864,12 +4864,11 @@ int hdd_stop_no_trans(struct net_device *dev)
 	/* DeInit the adapter. This ensures datapath cleanup as well */
 	hdd_deinit_adapter(hdd_ctx, adapter, true);
 
-	if (!hdd_is_any_interface_open(hdd_ctx))
-		hdd_psoc_idle_timer_start(hdd_ctx);
-
 reset_iface_opened:
 	/* Make sure the interface is marked as closed */
 	clear_bit(DEVICE_IFACE_OPENED, &adapter->event_flags);
+	if (!hdd_is_any_interface_open(hdd_ctx))
+		hdd_psoc_idle_timer_start(hdd_ctx);
 	hdd_exit();
 
 	return 0;