From: Dan Carpenter <error27@gmail.com>
To: Rasesh Mody <rmody@brocade.com>
Cc: Debashis Dutt <ddutt@brocade.com>,
"open list:BROCADE BNA 10 GI..." <netdev@vger.kernel.org>,
kernel-janitors@vger.kernel.org
Subject: [patch -next] bna: unlock on error path in pnad_pci_probe()
Date: Wed, 24 Aug 2011 14:29:22 +0300 [thread overview]
Message-ID: <20110824112922.GC5975@shale.localdomain> (raw)
We introduced a new lock here, so there was error path which needs
an unlock now.
Signed-off-by: Dan Carpenter <error27@gmail.com>
diff --git a/drivers/net/ethernet/brocade/bna/bnad.c b/drivers/net/ethernet/brocade/bna/bnad.c
index bdfda07..6ad4b47 100644
--- a/drivers/net/ethernet/brocade/bna/bnad.c
+++ b/drivers/net/ethernet/brocade/bna/bnad.c
@@ -3167,7 +3167,7 @@ bnad_pci_probe(struct pci_dev *pdev,
*/
err = bnad_pci_init(bnad, pdev, &using_dac);
if (err)
- goto free_netdev;
+ goto unlock_mutex;
/*
* Initialize bnad structure
@@ -3296,9 +3296,9 @@ drv_uninit:
bnad_uninit(bnad);
pci_uninit:
bnad_pci_uninit(pdev);
+unlock_mutex:
mutex_unlock(&bnad->conf_mutex);
bnad_lock_uninit(bnad);
-free_netdev:
free_netdev(netdev);
return err;
}
next reply other threads:[~2011-08-24 11:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-24 11:29 Dan Carpenter [this message]
2011-08-24 17:25 ` [patch -next] bna: unlock on error path in pnad_pci_probe() Rasesh Mody
2011-08-26 16:51 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110824112922.GC5975@shale.localdomain \
--to=error27@gmail.com \
--cc=ddutt@brocade.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=rmody@brocade.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox