public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
From: Sagi Grimberg <sagig@dev.mellanox.co.il>
To: Or Gerlitz <gerlitz.or@gmail.com>,
	Steve Wise <swise@opengridcomputing.com>
Cc: Doug Ledford <dledford@redhat.com>, Roi Dayan <roid@mellanox.com>,
	"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	Sagi Grimberg <sagig@mellanox.com>,
	Mike Marciniszyn <infinipath@intel.com>,
	target-devel@vger.kernel.org, Eli Cohen <eli@mellanox.com>,
	Or Gerlitz <ogerlitz@mellanox.com>
Subject: Re: [PATCH V3 4/4] RDMA/isert: Support iWARP transport
Date: Thu, 2 Jul 2015 09:28:46 +0300	[thread overview]
Message-ID: <5594DA1E.7040604@dev.mellanox.co.il> (raw)
In-Reply-To: <CAJ3xEMhehOBvmFBFNwZEda3Wc3UyyyK8iH6HrYfVbD0=8MUa-A@mail.gmail.com>

On 7/2/2015 12:03 AM, Or Gerlitz wrote:
> On Wed, Jul 1, 2015 at 11:53 PM, Steve Wise <swise@opengridcomputing.com> wrote:
>>> From: Or Gerlitz [mailto:gerlitz.or@gmail.com]
>
>> Yes, the MR is a local MR, but it is used for REMOTE access for iWARP, but not IB.  It think the reason is that in iWARP there is no distinction between local and remote keys.  For iwarp you get 1 key called a Steering Tag or STAG that is used both locally and advertised to the peer (if to be used for REMOTE IO).  Further, that STAG is sent to the peer in the RDMA READ REQUEST and the peer iWARP stack uses it to generate READ RESPONSE messages with the advertised STAG as the READ DESTINATION.  And thus these STAGs require REMOTE_WRITE access flags.  In IB, I believe the "key" sent in the READ REQUEST is not the MR lkey or rkey at all, but a one-shot transaction key, valid for that READ operation only, and the local IB stack uses this key to map to the destination MR/lkey when processing
  the RDMA READ RESPONSE.  This difference in the protocols is what drives the access flag difference.
>
>
> Since in IB/RoCE the key sent on the wire isn't actually something
> that can be used as rkey by the peer, we can safely do the extra
> access flags Oring always and not worry which transport is used.
>
>
>> Regardless, I'm not sure what you propose I do differently?  The code in this patch does OR the needed access flag if the device is iWARP when creating the DMA_MR.
>
> So always OR and don't branch

Or has a good point.
The DMA mkey in target mode is discrete and not sent to any peer.

Sagi.

  reply	other threads:[~2015-07-02  6:28 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-01 16:30 [PATCH V3 0/4] iSER support for iWARP Steve Wise
2015-07-01 16:30 ` [PATCH V3 1/4] mlx4, mlx5, mthca: Expose max_sge_rd correctly Steve Wise
2015-07-01 16:30 ` [PATCH V3 3/4] RDMA/iser: limit sg tablesize to device fastreg max depth Steve Wise
     [not found]   ` <20150701163052.6501.27775.stgit-T4OLL4TyM9aNDNWfRnPdfg@public.gmane.org>
2015-07-01 17:07     ` Sagi Grimberg
     [not found]       ` <55941E6F.5080208-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
2015-07-01 18:11         ` Steve Wise
2015-07-01 20:27     ` Or Gerlitz
2015-07-01 20:41       ` Steve Wise
     [not found] ` <20150701162936.6501.45512.stgit-T4OLL4TyM9aNDNWfRnPdfg@public.gmane.org>
2015-07-01 16:30   ` [PATCH V3 2/4] ipath,qib: Expose max_sge_rd correctly Steve Wise
2015-07-01 16:30   ` [PATCH V3 4/4] RDMA/isert: Support iWARP transport Steve Wise
     [not found]     ` <20150701163058.6501.39171.stgit-T4OLL4TyM9aNDNWfRnPdfg@public.gmane.org>
2015-07-01 17:16       ` Sagi Grimberg
2015-07-01 20:33     ` Or Gerlitz
2015-07-01 20:53       ` Steve Wise
2015-07-01 21:03         ` Or Gerlitz
2015-07-02  6:28           ` Sagi Grimberg [this message]
     [not found]             ` <5594DA1E.7040604-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
2015-07-02 13:17               ` Steve Wise
2015-07-02 16:39               ` Jason Gunthorpe
     [not found]                 ` <20150702163937.GB4642-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2015-07-04 10:51                   ` Sagi Grimberg

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=5594DA1E.7040604@dev.mellanox.co.il \
    --to=sagig@dev.mellanox.co.il \
    --cc=dledford@redhat.com \
    --cc=eli@mellanox.com \
    --cc=gerlitz.or@gmail.com \
    --cc=infinipath@intel.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=ogerlitz@mellanox.com \
    --cc=roid@mellanox.com \
    --cc=sagig@mellanox.com \
    --cc=swise@opengridcomputing.com \
    --cc=target-devel@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