All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Chuck Lever III <chuck.lever@oracle.com>
Cc: Tom Talpey <tom@talpey.com>, Chuck Lever <cel@kernel.org>,
	Bernard Metzler <BMT@zurich.ibm.com>,
	linux-rdma <linux-rdma@vger.kernel.org>,
	Zhu Yanjun <yanjun.zhu@linux.dev>
Subject: Re: [PATCH v5 4/4] RDMA/cma: Avoid GID lookups on iWARP devices
Date: Mon, 3 Jul 2023 18:07:24 -0300	[thread overview]
Message-ID: <ZKM4jM6Ve5PUhHFk@nvidia.com> (raw)
In-Reply-To: <7F4E0CAA-A06B-4F43-B019-4E471B10DDE7@oracle.com>

On Sat, Jul 01, 2023 at 04:27:23PM +0000, Chuck Lever III wrote:
> 
> 
> > On Jul 1, 2023, at 12:24 PM, Tom Talpey <tom@talpey.com> wrote:
> > 
> > On 6/29/2023 11:16 AM, Chuck Lever wrote:
> >> From: Chuck Lever <chuck.lever@oracle.com>
> >> We would like to enable the use of siw on top of a VPN that is
> >> constructed and managed via a tun device. That hasn't worked up
> >> until now because ARPHRD_NONE devices (such as tun devices) have
> >> no GID for the RDMA/core to look up.
> >> But it turns out that the egress device has already been picked for
> >> us -- no GID is necessary. addr_handler() just has to do the right
> >> thing with it.
> >> Suggested-by: Jason Gunthorpe <jgg@nvidia.com>
> >> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
> >> ---
> >>  drivers/infiniband/core/cma.c |   15 +++++++++++++++
> >>  1 file changed, 15 insertions(+)
> >> diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c
> >> index 889b3e4ea980..07bb5ac4019d 100644
> >> --- a/drivers/infiniband/core/cma.c
> >> +++ b/drivers/infiniband/core/cma.c
> >> @@ -700,6 +700,21 @@ cma_validate_port(struct ib_device *device, u32 port,
> >>   if ((dev_type != ARPHRD_INFINIBAND) && rdma_protocol_ib(device, port))
> >>   goto out;
> >>  + /* Linux iWARP devices have but one port */
> > 
> > I don't believe this comment is correct, or necessary. In-tree drivers
> > exist for several multi-port iWARP devices, and the port bnumber passed
> > to rdma_protocol_iwarp() and rdma_get_gid_attr() will follow, no?
> 
> Then I must have misunderstood what Jason said about the reason
> for the rdma_protocol_iwarp() check. He said that we are able to
> do this kind of GID lookup because iWARP devices have only a
> single port.
> 
> Jason?

I don't know alot about iwarp - tom does iwarp really have multiported
*struct ib_device* models? This is different from multiport hw.

If it is multiport how do the gid tables work across the ports?

Jason

  reply	other threads:[~2023-07-03 21:07 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-29 15:16 [PATCH v5 0/4] Handle ARPHRD_NONE devices for siw Chuck Lever
2023-06-29 15:16 ` [PATCH v5 1/4] RDMA/siw: Fabricate a GID on tun and loopback devices Chuck Lever
2023-06-29 15:16 ` [PATCH v5 2/4] RDMA/core: Set gid_attr.ndev for iWARP devices Chuck Lever
2023-06-29 15:16 ` [PATCH v5 3/4] RDMA/cma: Deduplicate error flow in cma_validate_port() Chuck Lever
2023-06-29 15:16 ` [PATCH v5 4/4] RDMA/cma: Avoid GID lookups on iWARP devices Chuck Lever
2023-07-01 16:24   ` Tom Talpey
2023-07-01 16:27     ` Chuck Lever III
2023-07-03 21:07       ` Jason Gunthorpe [this message]
2023-07-04 14:23         ` Tom Talpey
2023-07-04 14:54           ` Chuck Lever III
2023-07-10 17:06             ` Jason Gunthorpe
2023-07-11 22:49               ` Chuck Lever III
2023-07-12 17:28                 ` Tom Talpey
2023-07-01  9:48 ` [PATCH v5 0/4] Handle ARPHRD_NONE devices for siw Zhu Yanjun

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=ZKM4jM6Ve5PUhHFk@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=BMT@zurich.ibm.com \
    --cc=cel@kernel.org \
    --cc=chuck.lever@oracle.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=tom@talpey.com \
    --cc=yanjun.zhu@linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.