From: Roland Dreier <rdreier@cisco.com>
To: torvalds@linux-foundation.org
Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
general@lists.openfabrics.org
Subject: [PATCH] IB/mlx4: Actually return L_Key and R_Key for fast register MRs
Date: Wed, 27 Aug 2008 14:29:57 -0700 [thread overview]
Message-ID: <adasksqf8oa.fsf@cisco.com> (raw)
From: Vladimir Sokolovsky <vlad@mellanox.co.il>
Initialize the L_Key and R_Key for memory regions returned from
mlx4_ib_alloc_fast_reg_mr(). Otherwise callers just get garbage for
the memory keys and can't do anything useful with these MRs.
Signed-off-by: Vladimir Sokolovsky <vlad@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
---
Hi Linus,
Please apply this for 2.6.27. This fixes a new feature we merged during
the window but weren't able to test fully because device firmware wasn't
ready at the time.
I'm just sending this as a patch rather than a git pull request since I
think applying one patch from email is, if anything, easier than pulling
a git tree. If you'd rather get singleton patches via git in the future
just let me know.
Thanks,
Roland
drivers/infiniband/hw/mlx4/mr.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/infiniband/hw/mlx4/mr.c b/drivers/infiniband/hw/mlx4/mr.c
index a4cdb46..87f5c5a 100644
--- a/drivers/infiniband/hw/mlx4/mr.c
+++ b/drivers/infiniband/hw/mlx4/mr.c
@@ -204,6 +204,8 @@ struct ib_mr *mlx4_ib_alloc_fast_reg_mr(struct ib_pd *pd,
if (err)
goto err_mr;
+ mr->ibmr.rkey = mr->ibmr.lkey = mr->mmr.key;
+
return &mr->ibmr;
err_mr:
--
1.5.6.3
reply other threads:[~2008-08-27 21:30 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=adasksqf8oa.fsf@cisco.com \
--to=rdreier@cisco.com \
--cc=akpm@linux-foundation.org \
--cc=general@lists.openfabrics.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.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