staging: ks7010: fix missing destroy_workqueue() on error in ks7010_sdio_probe

Add the missing destroy_workqueue() before return from
ks7010_sdio_probe in the error handling case.

Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Link: https://lore.kernel.org/r/20201028091552.136445-1-miaoqinglang@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Qinglang Miao 2020-10-28 17:15:52 +08:00 committed by Greg Kroah-Hartman
parent 16b37e7ba6
commit d1e7550ad0

View File

@ -1029,10 +1029,12 @@ static int ks7010_sdio_probe(struct sdio_func *func,
ret = register_netdev(priv->net_dev);
if (ret)
goto err_free_netdev;
goto err_destroy_wq;
return 0;
err_destroy_wq:
destroy_workqueue(priv->wq);
err_free_netdev:
free_netdev(netdev);
err_release_irq: