From: Yevgeny Petrilin <yevgenyp@mellanox.co.il>
To: <davem@davemloft.net>
Cc: <netdev@vger.kernel.org>, <yevgenyp@mellanox.co.il>
Subject: [PATCH net-next 4/5] mlx4: not using spin_lock_irq when getting vf by resource.
Date: Mon, 19 Dec 2011 16:03:05 +0200 [thread overview]
Message-ID: <4EEF4419.100@mellanox.co.il> (raw)
From: Yevgeny Petrilin <yevgenyp@mellanox.co.il>
The function is always called from irq context, changing the call
to spin_lock().
Signed-off-by: Yevgeny Petrilin <yevgenyp@mellanox.co.il>
---
.../net/ethernet/mellanox/mlx4/resource_tracker.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
index bdd61c3..b41762d 100644
--- a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
+++ b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
@@ -339,14 +339,14 @@ int mlx4_get_slave_from_resource_id(struct mlx4_dev *dev,
if (type == RES_QP)
id &= 0x7fffff;
- spin_lock_irq(mlx4_tlock(dev));
+ spin_lock(mlx4_tlock(dev));
r = find_res(dev, id, type);
if (r) {
*slave = r->owner;
err = 0;
}
- spin_unlock_irq(mlx4_tlock(dev));
+ spin_unlock(mlx4_tlock(dev));
return err;
}
--
1.7.7
reply other threads:[~2011-12-19 16:17 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=4EEF4419.100@mellanox.co.il \
--to=yevgenyp@mellanox.co.il \
--cc=davem@davemloft.net \
--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