From: Roland Dreier <rolandd@cisco.com>
To: linux-kernel@vger.kernel.org, openib-general@openib.org
Subject: [git patch review 1/5] IPoIB: Make sure path is fully initialized before using it
Date: Sat, 21 Jan 2006 22:03:10 +0000 [thread overview]
Message-ID: <1137880990999-28a2de7670074e8b@cisco.com> (raw)
The SA path record query completion can initialize path->pathrec.dlid
before IPoIB's callback runs and initializes path->ah, so we must test
ah rather than dlid.
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
---
drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
47f7a0714b67b904a3a36e2f2d85904e8064219b
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c b/drivers/infiniband/ulp/ipoib/ipoib_main.c
index fd3f5c8..c3b5f79 100644
--- a/drivers/infiniband/ulp/ipoib/ipoib_main.c
+++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c
@@ -505,7 +505,7 @@ static void neigh_add_path(struct sk_buf
list_add_tail(&neigh->list, &path->neigh_list);
- if (path->pathrec.dlid) {
+ if (path->ah) {
kref_get(&path->ah->ref);
neigh->ah = path->ah;
@@ -591,7 +591,7 @@ static void unicast_arp_send(struct sk_b
return;
}
- if (path->pathrec.dlid) {
+ if (path->ah) {
ipoib_dbg(priv, "Send unicast ARP to %04x\n",
be16_to_cpu(path->pathrec.dlid));
--
1.1.3
next reply other threads:[~2006-01-21 22:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-21 22:03 Roland Dreier [this message]
2006-01-21 22:03 ` [git patch review 2/5] IB/uverbs: Flush scheduled work before unloading module Roland Dreier
2006-01-21 22:03 ` [git patch review 3/5] IB/sa_query: " Roland Dreier
2006-01-21 22:03 ` [git patch review 4/5] IPoIB: Lock accesses to multicast packet queues Roland Dreier
2006-01-21 22:03 ` [git patch review 5/5] IB/mthca: Use correct GID in MADs sent on port 2 Roland Dreier
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=1137880990999-28a2de7670074e8b@cisco.com \
--to=rolandd@cisco.com \
--cc=linux-kernel@vger.kernel.org \
--cc=openib-general@openib.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
all inboxes | Powered by JetHome®