mwifiex: uninit wakeup info in the error handling
We inited wakeup info at the beginning of mwifiex_add_card, so we need
to uninit it in the error handling.
It's much the same as what we did in:
36908c4
mwifiex: uninit wakeup info when removing device
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
Reviewed-by: Brian Norris <briannorris@chromium.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
parent
f46a5b0156
commit
f101d9649c
|
@ -667,8 +667,11 @@ done:
|
||||||
release_firmware(adapter->firmware);
|
release_firmware(adapter->firmware);
|
||||||
adapter->firmware = NULL;
|
adapter->firmware = NULL;
|
||||||
}
|
}
|
||||||
if (init_failed)
|
if (init_failed) {
|
||||||
|
if (adapter->irq_wakeup >= 0)
|
||||||
|
device_init_wakeup(adapter->dev, false);
|
||||||
mwifiex_free_adapter(adapter);
|
mwifiex_free_adapter(adapter);
|
||||||
|
}
|
||||||
/* Tell all current and future waiters we're finished */
|
/* Tell all current and future waiters we're finished */
|
||||||
complete_all(fw_done);
|
complete_all(fw_done);
|
||||||
|
|
||||||
|
@ -1668,6 +1671,8 @@ err_registerdev:
|
||||||
mwifiex_free_cmd_buffers(adapter);
|
mwifiex_free_cmd_buffers(adapter);
|
||||||
}
|
}
|
||||||
err_kmalloc:
|
err_kmalloc:
|
||||||
|
if (adapter->irq_wakeup >= 0)
|
||||||
|
device_init_wakeup(adapter->dev, false);
|
||||||
mwifiex_free_adapter(adapter);
|
mwifiex_free_adapter(adapter);
|
||||||
|
|
||||||
err_init_sw:
|
err_init_sw:
|
||||||
|
|
Loading…
Reference in New Issue