qcacld-3.0: Dont process uevent request when the modules are closed
When the SSR is triggered after the modules are closed, uevent notifier is trying to get the pdev which is alredy destroyed. Reject the uevent notification if the modules are already closed. Change-Id: I8074838b18b1e36dd67afa90125f9fbe06d32c34 CRs-Fixed: 2219843
This commit is contained in:

committed by
nshrivas

parent
e7b11b8721
commit
5923cc98c8
@@ -1490,6 +1490,17 @@ static void wlan_hdd_handle_the_pld_uevent(struct pld_uevent_data *uevent)
|
|||||||
if (cds_is_driver_loading())
|
if (cds_is_driver_loading())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD);
|
||||||
|
if (!hdd_ctx) {
|
||||||
|
hdd_err("hdd_ctx is NULL return");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hdd_ctx->driver_status == DRIVER_MODULES_CLOSED) {
|
||||||
|
hdd_info("Driver modules are already closed!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
switch (uevent->uevent) {
|
switch (uevent->uevent) {
|
||||||
case PLD_RECOVERY:
|
case PLD_RECOVERY:
|
||||||
cds_set_target_ready(false);
|
cds_set_target_ready(false);
|
||||||
@@ -1498,10 +1509,7 @@ static void wlan_hdd_handle_the_pld_uevent(struct pld_uevent_data *uevent)
|
|||||||
case PLD_FW_DOWN:
|
case PLD_FW_DOWN:
|
||||||
qdf_complete_wait_events();
|
qdf_complete_wait_events();
|
||||||
cds_set_target_ready(false);
|
cds_set_target_ready(false);
|
||||||
hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD);
|
wlan_cfg80211_cleanup_scan_queue(hdd_ctx->hdd_pdev, NULL);
|
||||||
if (hdd_ctx != NULL)
|
|
||||||
wlan_cfg80211_cleanup_scan_queue(
|
|
||||||
hdd_ctx->hdd_pdev, NULL);
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
@@ -1521,8 +1529,8 @@ static void wlan_hdd_pld_uevent(struct device *dev,
|
|||||||
hdd_enter();
|
hdd_enter();
|
||||||
hdd_info("pld event %d", uevent->uevent);
|
hdd_info("pld event %d", uevent->uevent);
|
||||||
|
|
||||||
mutex_lock(&hdd_init_deinit_lock);
|
|
||||||
wlan_hdd_set_the_pld_uevent(uevent);
|
wlan_hdd_set_the_pld_uevent(uevent);
|
||||||
|
mutex_lock(&hdd_init_deinit_lock);
|
||||||
wlan_hdd_handle_the_pld_uevent(uevent);
|
wlan_hdd_handle_the_pld_uevent(uevent);
|
||||||
mutex_unlock(&hdd_init_deinit_lock);
|
mutex_unlock(&hdd_init_deinit_lock);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user