From: Or Gerlitz <ogerlitz@mellanox.com>
To: davem@davemloft.net
Cc: roland@kernel.org, netdev@vger.kernel.org,
Jack Morgenstein <jackm@dev.mellanox.co.il>,
Or Gerlitz <ogerlitz@mellanox.com>
Subject: [PATCH net-next 8/8] net/mlx4_core: Fixed error flow in rem_slave_eqs
Date: Mon, 14 May 2012 23:04:13 +0300 [thread overview]
Message-ID: <1337025853-26685-9-git-send-email-ogerlitz@mellanox.com> (raw)
In-Reply-To: <1337025853-26685-1-git-send-email-ogerlitz@mellanox.com>
From: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
---
.../net/ethernet/mellanox/mlx4/resource_tracker.c | 13 ++++++-------
1 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
index 626d1e3..2650f23 100644
--- a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
+++ b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
@@ -3152,14 +3152,13 @@ static void rem_slave_eqs(struct mlx4_dev *dev, int slave)
MLX4_CMD_HW2SW_EQ,
MLX4_CMD_TIME_CLASS_A,
MLX4_CMD_NATIVE);
- mlx4_dbg(dev, "rem_slave_eqs: failed"
- " to move slave %d eqs %d to"
- " SW ownership\n", slave, eqn);
+ if (err)
+ mlx4_dbg(dev, "rem_slave_eqs: failed"
+ " to move slave %d eqs %d to"
+ " SW ownership\n", slave, eqn);
mlx4_free_cmd_mailbox(dev, mailbox);
- if (!err) {
- atomic_dec(&eq->mtt->ref_count);
- state = RES_EQ_RESERVED;
- }
+ atomic_dec(&eq->mtt->ref_count);
+ state = RES_EQ_RESERVED;
break;
default:
--
1.7.1
prev parent reply other threads:[~2012-05-14 20:04 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-14 20:04 [PATCH net-next 0/8] batch of mlx4 driver fixes Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 1/8] net/mlx4: Address build warnings on set but not used variables Or Gerlitz
2012-05-15 4:07 ` David Miller
2012-05-15 5:52 ` Or Gerlitz
2012-05-15 5:59 ` David Miller
2012-05-15 6:16 ` Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 2/8] net/mlx4_core: Fix init_port mask state for slaves Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 3/8] net/mlx4_core: Change SYNC_TPT to be native (not wrapped) Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 4/8] net/mlx4_core: Remove unused *_str functions from the resource tracker Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 5/8] net/mlx4_core: Do not reset module-parameter num_vfs when fail to enable sriov Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 6/8] net/mlx4_core: Fix potential kernel Oops in res tracker during Dom0 driver unload Or Gerlitz
2012-05-14 20:04 ` [PATCH net-next 7/8] net/mlx4_core: Add XRC domains and counters to resource tracker Or Gerlitz
2012-05-14 20:04 ` Or Gerlitz [this message]
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=1337025853-26685-9-git-send-email-ogerlitz@mellanox.com \
--to=ogerlitz@mellanox.com \
--cc=davem@davemloft.net \
--cc=jackm@dev.mellanox.co.il \
--cc=netdev@vger.kernel.org \
--cc=roland@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