All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Christoph Lameter <cl@linux.com>
Cc: Leon Romanovsky <leon@kernel.org>, <linux-rdma@vger.kernel.org>
Subject: Re: [PATCH] Fix: Remove racy Subnet Manager sendonly join checks
Date: Thu, 28 Jan 2021 10:44:35 -0400	[thread overview]
Message-ID: <20210128144435.GG4247@nvidia.com> (raw)
In-Reply-To: <alpine.DEB.2.22.394.2101281433270.10563@www.lameter.com>

On Thu, Jan 28, 2021 at 02:34:45PM +0000, Christoph Lameter wrote:
> On Thu, 28 Jan 2021, Jason Gunthorpe wrote:
> 
> > I need patches to be sent in a way that shows in patchworks to be
> > applied:
> >
> > https://patchwork.kernel.org/project/linux-rdma/list/
> 
> 
> I see it in patchworks:
> 
> https://patchwork.kernel.org/project/linux-rdma/patch/alpine.DEB.2.22.394.2101251126090.344695@www.lameter.com/

It is not in the right format in patchwork, I get this mess when
applying it:

commit 9215f573b2ce9233b6d99d7b9b45bbcf3b2d9d90 (HEAD -> k.o/for-next)
Author: Christoph Lameter <cl@linux.com>
Date:   Mon Jan 25 11:28:57 2021 +0000

    Fix: Remove racy Subnet Manager sendonly join checks
    
    On Sun, 24 Jan 2021, Leon Romanovsky wrote:
    
    > > Since all SMs out there have had support for sendonly join for years now
    > > we could just remove the check entirely. If there is an old grizzly SM out
    > > there then it would not process that join request and would return an
    > > error.
    >
    > I have no idea if it possible, if yes, this will be the best solution.
    
    Ok hier ist ein neuer Patch:
    
    From: Christoph Lameter <cl@linux.com>
    Subject: [PATCH] Fix: Remove racy Subnet Manager sendonly join checks
    
    When a system receives a REREG event from the SM, then the SM information in
    the kernel is marked as invalid and a request is sent to the SM to update
    the information. The SM information is invalid in that time period.
    
    However, receiving a REREG also occurs simultaneously in user space
    applications that are now trying to rejoin the multicast groups. Some of those
    may be sendonly multicast groups which are then failing.
    
    If the SM information is invalid then ib_sa_sendonly_fullmem_support()
    returns false. That is wrong because it just means that we do not know
    yet if the potentially new SM supports sendonly joins.
    
    Sendonly join was introduced in 2015 and all the Subnet managers have
    supported it ever since. So there is no point in checking if a subnet
    manager supports it.
    
    Should an old opensm get a request for a sendonly join then the request
    will fail. The code that is removed here accomodated that situation
    and fell back to a full join.
    
    Falling back to a full join is problematic in itself. The reason to
    use the sendonly join was to reduce the traffic on the Infiniband
    fabric otherwise one could have just stayed with the regular join.
    So this patch may cause users of very old opensms to discover that
    lots of traffic needlessly crosses their IB fabrics.
    
    Signed-off-by: Christoph Lameter <cl@linux.com>
    
    Link: https://lore.kernel.org/r/alpine.DEB.2.22.394.2101251126090.344695@www.lameter.com
    Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>

> > > Index: linux/drivers/infiniband/core/cma.c
> > > ===================================================================
> > > +++ linux/drivers/infiniband/core/cma.c	2021-01-25 09:39:29.191032891 +0000
> > > @@ -4542,17 +4542,6 @@ static int cma_join_ib_multicast(struct
> >
> > Also if patches aren't generated with 'git diff' then I won't fix any
> > minor conflicts :(
> 
> Well it was quilt ...... Do I need to put it into a git tree somewhere?

If you are doing this a lot get a quilt that can generate git diff
format output.

https://lists.gnu.org/archive/html/quilt-dev/2015-06/msg00002.html

Jason


  reply	other threads:[~2021-01-28 14:47 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-25 11:28 [PATCH] Fix: Remove racy Subnet Manager sendonly join checks Christoph Lameter
2021-01-25 11:44 ` Leon Romanovsky
2021-01-28 14:03 ` Jason Gunthorpe
2021-01-28 14:21   ` Leon Romanovsky
2021-01-28 14:34   ` Christoph Lameter
2021-01-28 14:44     ` Jason Gunthorpe [this message]
2021-01-28 14:58       ` Christoph Lameter
2021-01-28 18:11         ` Jason Gunthorpe
     [not found] <alpine.DEB.2.22.394.2101281845160.13303@www.lameter.com>
2021-02-09 19:15 ` Jason Gunthorpe
2021-02-10  9:31   ` Christoph Lameter
2021-02-10 13:03     ` Jason Gunthorpe
2021-02-10 18:51       ` Christoph Lameter
2021-02-12 22:16     ` Dennis Dalessandro
2021-02-12 22:13   ` Dennis Dalessandro

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=20210128144435.GG4247@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=cl@linux.com \
    --cc=leon@kernel.org \
    --cc=linux-rdma@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 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.