All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dennis Dalessandro <dennis.dalessandro@cornelisnetworks.com>
To: Christoph Lameter <cl@linux.com>, Jason Gunthorpe <jgg@nvidia.com>
Cc: linux-rdma@vger.kernel.org, Leon Romanovsky <leon@kernel.org>
Subject: Re: [PATCH] Fix: Remove racy Subnet Manager sendonly join checks
Date: Fri, 12 Feb 2021 17:16:43 -0500	[thread overview]
Message-ID: <15fa038a-8fee-05b4-4c5c-0e4c3a5d1aec@cornelisnetworks.com> (raw)
In-Reply-To: <alpine.DEB.2.22.394.2102100925200.172831@www.lameter.com>



On 2/10/2021 4:31 AM, Christoph Lameter wrote:
> On Tue, 9 Feb 2021, Jason Gunthorpe wrote:
> 
>> This one got spam filtered and didn't make it to the list:
>>
>> Received-SPF: SoftFail (hqemgatev14.nvidia.com: domain of
>>          cl@linux.com is inclined to not designate 3.19.106.255 as
>>          permitted sender) identity=mailfrom; client-ip=3.19.106.255;
>>          receiver=hqemgatev14.nvidia.com;
>>          envelope-from="cl@linux.com"; x-sender="cl@linux.com";
>>          x-conformance=spf_only; x-record-type="v=spf1"
>>
>> Also the extra From/Date/Subject ended up in the commit message
> 
> Yes the Linux Foundation guys are not willing to address this issue in any
> way. I may have to give up my linux.com email address.
> 
>> I fixed it all up, applied to for-next
> 
> Thank you.
> 
>> It looks like OPA will also suffer this race (opa_pr_query_possible),
>> maybe it is a little less likely since it will be driven by PR queries
>> not broadcast joins.
>>
>> But the same logic is likely true there, I'd be surprised if OPA
>> fabrics are not running a capable OPA SM at this point.
> 
> There is also another potentially racy check in there for OPA in regards
> to the support of path records?
> 
> static bool ib_sa_opa_pathrecord_support(struct ib_sa_client *client,
>                                           struct ib_sa_device *sa_dev,
>                                           u8 port_num)
> {
>          struct ib_sa_port *port;
>          unsigned long flags;
>          bool ret = false;
> 
>          port = &sa_dev->port[port_num - sa_dev->start_port];
>          spin_lock_irqsave(&port->classport_lock, flags);
>          if (!port->classport_info.valid)
>                  goto ret;
> 
>          if (port->classport_info.data.type == RDMA_CLASS_PORT_INFO_OPA)
>                  ret = opa_get_cpi_capmask2(&port->classport_info.data.opa)
> &
>                          OPA_CLASS_PORT_INFO_PR_SUPPORT;
> ret:
>          spin_unlock_irqrestore(&port->classport_lock, flags);
>          return ret;
> }
> 

Thanks for pointing this out. We'll look into it.

-Denny

  parent reply	other threads:[~2021-02-12 22:18 UTC|newest]

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

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=15fa038a-8fee-05b4-4c5c-0e4c3a5d1aec@cornelisnetworks.com \
    --to=dennis.dalessandro@cornelisnetworks.com \
    --cc=cl@linux.com \
    --cc=jgg@nvidia.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.