From: Lennert Buytenhek Date: Mon, 30 Nov 2009 17:13:34 +0000 (+0100) Subject: mwl8k: don't forget to call pci_disable_device() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3db95e50c8813d8ed04a1ec7cd7b77dba7c81c80;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git mwl8k: don't forget to call pci_disable_device() Don't forget to call pci_disable_device() if pci_request_regions() fails during probe. Signed-off-by: Lennert Buytenhek Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/mwl8k.c b/drivers/net/wireless/mwl8k.c index e59a92618807..76a6071aac8a 100644 --- a/drivers/net/wireless/mwl8k.c +++ b/drivers/net/wireless/mwl8k.c @@ -3378,7 +3378,7 @@ static int __devinit mwl8k_probe(struct pci_dev *pdev, if (rc) { printk(KERN_ERR "%s: Cannot obtain PCI resources\n", MWL8K_NAME); - return rc; + goto err_disable_device; } pci_set_master(pdev); @@ -3609,6 +3609,8 @@ err_iounmap: err_free_reg: pci_release_regions(pdev); + +err_disable_device: pci_disable_device(pdev); return rc;