From: Vladimir Kondratiev Date: Mon, 28 Jan 2013 16:31:05 +0000 (+0200) Subject: wil6210: Reorder reset preparation sequence X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e08b5906ccf323e2ad7b0448329b7cbcfda4c94e;p=linux-beck.git wil6210: Reorder reset preparation sequence Disable interrupts first to prevent spurious WMI events arrival Signed-off-by: Vladimir Kondratiev Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/ath/wil6210/main.c b/drivers/net/wireless/ath/wil6210/main.c index 4c1533088fe5..aa598f37899b 100644 --- a/drivers/net/wireless/ath/wil6210/main.c +++ b/drivers/net/wireless/ath/wil6210/main.c @@ -250,13 +250,13 @@ int wil_reset(struct wil6210_priv *wil) cancel_work_sync(&wil->disconnect_worker); wil6210_disconnect(wil, NULL); + wil6210_disable_irq(wil); + wil->status = 0; + wmi_event_flush(wil); - flush_workqueue(wil->wmi_wq); flush_workqueue(wil->wmi_wq_conn); - - wil6210_disable_irq(wil); - wil->status = 0; + flush_workqueue(wil->wmi_wq); /* TODO: put MAC in reset */ wil_target_reset(wil);