Browse Source

staging: gdm72xx: cancel work when driver unloads

cancel the work function at driver unload stage and remove
the function from the queue

Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Devendra Naga 12 years ago
parent
commit
c0352cb71d
1 changed files with 1 additions and 0 deletions
  1. 1 0
      drivers/staging/gdm72xx/gdm_sdio.c

+ 1 - 0
drivers/staging/gdm72xx/gdm_sdio.c

@@ -689,6 +689,7 @@ static void sdio_wimax_remove(struct sdio_func *func)
 	struct phy_dev *phy_dev = sdio_get_drvdata(func);
 	struct sdiowm_dev *sdev = phy_dev->priv_dev;
 
+	cancel_work_sync(&sdev->ws);
 	if (phy_dev->netdev)
 		unregister_wimax_device(phy_dev);
 	sdio_claim_host(func);