Commit 44861f44 authored by Dan Carpenter's avatar Dan Carpenter Committed by David S. Miller

bna: unlock on error path in pnad_pci_probe()

We introduced a new lock here, so there was error path which needs
an unlock now.
Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Acked-by: default avatarRasesh Mody <rmody@brocade.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 3756a89f
...@@ -3167,7 +3167,7 @@ bnad_pci_probe(struct pci_dev *pdev, ...@@ -3167,7 +3167,7 @@ bnad_pci_probe(struct pci_dev *pdev,
*/ */
err = bnad_pci_init(bnad, pdev, &using_dac); err = bnad_pci_init(bnad, pdev, &using_dac);
if (err) if (err)
goto free_netdev; goto unlock_mutex;
/* /*
* Initialize bnad structure * Initialize bnad structure
...@@ -3296,9 +3296,9 @@ bnad_pci_probe(struct pci_dev *pdev, ...@@ -3296,9 +3296,9 @@ bnad_pci_probe(struct pci_dev *pdev,
bnad_uninit(bnad); bnad_uninit(bnad);
pci_uninit: pci_uninit:
bnad_pci_uninit(pdev); bnad_pci_uninit(pdev);
unlock_mutex:
mutex_unlock(&bnad->conf_mutex); mutex_unlock(&bnad->conf_mutex);
bnad_lock_uninit(bnad); bnad_lock_uninit(bnad);
free_netdev:
free_netdev(netdev); free_netdev(netdev);
return err; return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment