netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Shahed Shaikh <shahed.shaikh@qlogic.com>
To: <davem@davemloft.net>
Cc: <netdev@vger.kernel.org>, <Dept_NX_Linux_NIC_Driver@qlogic.com>,
	Himanshu Madhani <himanshu.madhani@qlogic.com>
Subject: [PATCH net 3/8] qlcnic: Free up memory in error path.
Date: Fri, 2 Aug 2013 23:15:56 -0400	[thread overview]
Message-ID: <1375499761-21141-4-git-send-email-shahed.shaikh@qlogic.com> (raw)
In-Reply-To: <1375499761-21141-1-git-send-email-shahed.shaikh@qlogic.com>

From: Himanshu Madhani <himanshu.madhani@qlogic.com>

Signed-off-by: Himanshu Madhani <himanshu.madhani@qlogic.com>
Signed-off-by: Shahed Shaikh <shahed.shaikh@qlogic.com>
---
 drivers/net/ethernet/qlogic/qlcnic/qlcnic_ctx.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_ctx.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_ctx.c
index 0581a48..8d401ba 100644
--- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_ctx.c
+++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_ctx.c
@@ -210,10 +210,10 @@ int qlcnic_fw_cmd_set_drv_version(struct qlcnic_adapter *adapter, u32 fw_cmd)
 	if (err) {
 		dev_info(&adapter->pdev->dev,
 			 "Failed to set driver version in firmware\n");
-		return -EIO;
+		err = -EIO;
 	}
-
-	return 0;
+	qlcnic_free_mbx_args(&cmd);
+	return err;
 }
 
 int
-- 
1.5.6

  parent reply	other threads:[~2013-08-03  3:56 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-03  3:15 [PATCH net 0/8] qlcnic: Bug fixes Shahed Shaikh
2013-08-03  3:15 ` [PATCH net 1/8] qlcnic: Fix MAC address filter issue on 82xx adapter Shahed Shaikh
2013-08-03  3:15 ` [PATCH net 2/8] qlcnic: Fix ingress MAC learning Shahed Shaikh
2013-08-03  3:15 ` Shahed Shaikh [this message]
2013-08-03  3:15 ` [PATCH net 4/8] qlcnic: Removed adapter series name from warning messages Shahed Shaikh
2013-08-03  3:15 ` [PATCH net 5/8] qlcnic: Fix external loopback test Shahed Shaikh
2013-08-03  3:15 ` [PATCH net 6/8] qlcnic: Fix link speed display for 82xx adapter Shahed Shaikh
2013-08-03  3:16 ` [PATCH net 7/8] qlcnic: Fix link speed and duplex display for 83xx adapter Shahed Shaikh
2013-08-03  3:16 ` [PATCH net 8/8] qlcnic: Fix for flash update failure on " Shahed Shaikh
2013-08-03 19:03 ` [PATCH net 0/8] qlcnic: Bug fixes 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=1375499761-21141-4-git-send-email-shahed.shaikh@qlogic.com \
    --to=shahed.shaikh@qlogic.com \
    --cc=Dept_NX_Linux_NIC_Driver@qlogic.com \
    --cc=davem@davemloft.net \
    --cc=himanshu.madhani@qlogic.com \
    --cc=netdev@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).