mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 22:40:54 -04:00
cnss2: Assert for recovery if there is already a recovery going on
Assert right away if driver has detected one recovery is already in progress when tries to schedule another recovery. Also when schedule recovery, there is no need to update status to WLAN driver if it is already done when RDDM notification event arrives. Change-Id: I067e51d8d4a8d7ffd600ab0ec41f54785f001f9a Signed-off-by: Yue Ma <yuem@codeaurora.org>
This commit is contained in:
parent
218848f9ed
commit
7f0d8b7957
1 changed files with 3 additions and 1 deletions
|
|
@ -1062,6 +1062,7 @@ static int cnss_driver_recovery_hdlr(struct cnss_plat_data *plat_priv,
|
|||
|
||||
if (test_bit(CNSS_DRIVER_RECOVERY, &plat_priv->driver_state)) {
|
||||
cnss_pr_err("Recovery is already in progress\n");
|
||||
CNSS_ASSERT(0);
|
||||
ret = -EINVAL;
|
||||
goto out;
|
||||
}
|
||||
|
|
@ -1114,7 +1115,8 @@ void cnss_schedule_recovery(struct device *dev,
|
|||
struct cnss_recovery_data *data;
|
||||
int gfp = GFP_KERNEL;
|
||||
|
||||
cnss_bus_update_status(plat_priv, CNSS_FW_DOWN);
|
||||
if (!test_bit(CNSS_DEV_ERR_NOTIFY, &plat_priv->driver_state))
|
||||
cnss_bus_update_status(plat_priv, CNSS_FW_DOWN);
|
||||
|
||||
if (test_bit(CNSS_DRIVER_UNLOADING, &plat_priv->driver_state) ||
|
||||
test_bit(CNSS_DRIVER_IDLE_SHUTDOWN, &plat_priv->driver_state)) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue