diff mbox series

staging: wilc1000: flush the workqueue before deinit the host ifc

Message ID 20190722175604.19650-1-adham.abozaeid@microchip.com (mailing list archive)
State Not Applicable
Delegated to: Johannes Berg
Headers show
Series staging: wilc1000: flush the workqueue before deinit the host ifc | expand

Commit Message

Adham Abozaeid July 22, 2019, 5:56 p.m. UTC
From: Adham Abozaeid <adham.abozaeid@microchip.com>

Before deinitializing the host interface, the workqueue should be flushed
to handle any pending deferred work

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
---
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 63c38562ad1a..b0a6045327cc 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -2544,6 +2544,7 @@  void wilc_deinit_host_int(struct net_device *net)
 
 	vif->wilc->p2p_listen_state = false;
 
+	flush_workqueue(vif->wilc->hif_workqueue);
 	mutex_destroy(&priv->scan_req_lock);
 	ret = wilc_deinit(vif);