All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Tom Talpey <tom@talpey.com>
Cc: Gal Pressman <galpress@amazon.com>,
	RDMA mailing list <linux-rdma@vger.kernel.org>
Subject: Re: ibv_req_notify_cq clarification
Date: Fri, 19 Feb 2021 10:42:02 -0400	[thread overview]
Message-ID: <20210219144202.GF2643399@ziepe.ca> (raw)
In-Reply-To: <b31d6cdc-7304-d2fc-2e56-1f30f86f5dc4@talpey.com>

On Fri, Feb 19, 2021 at 09:31:22AM -0500, Tom Talpey wrote:
> On 2/18/2021 7:45 PM, Jason Gunthorpe wrote:
> > On Thu, Feb 18, 2021 at 06:07:13PM -0500, Tom Talpey wrote:
> > > > > If the consumer doesn't provide a large-enough CQ, then it reaps the
> > > > > consequences. Same thing for WQ depth, although I am aware that some
> > > > > verbs implementations attempt to return a kind of EAGAIN when posting
> > > > > to a send WQ.
> > > > > 
> > > > > What can the provider do if the CQ is "full" anyway? Buffer the CQE
> > > > > and go into some type of polling loop attempting to redeliver? Ouch!
> > > > 
> > > > QP goes to error, CQE is discarded, IIRC.
> > > 
> > > What!? There might be many QP's all sharing the same CQ. Put them
> > > *all* into error? And for what, because the CQ is trash anyway. This
> > > sounds like optimizing the error case. Uselessly.
> > 
> > No, only the QPs that need to push a CQE and can't.
> 
> Hm. Ok, so QP's will drop unpredictably, and their outstanding WQEs
> will probably be lost as well, but I can see cases where a CQ slot
> might open up while the failed QP is flushing, and CQE's get delivered
> out of order. That might be even worse. It would seem safer to stop
> writing to the CQ altogether - all QPs.

I think the app gets an IBV_EVENT_CQ_ERR and IBV_EVENT_QP_FATAL and
has to clean it up.

> That would be a problem, but it's only true if the provider implements
> the CQ as a circular buffer. 

AFAIK there is no datastructure that allows unbounded writing from the
producer side, the only choices are to halt on overflow or corrupt on
overflow - corrupt breaks the machine, so good HW does halt.

Jason

  reply	other threads:[~2021-02-19 14:42 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-18  9:13 ibv_req_notify_cq clarification Gal Pressman
2021-02-18 12:38 ` Bernard Metzler
2021-02-18 12:47   ` Gal Pressman
2021-02-18 13:59   ` Bernard Metzler
2021-02-18 12:53 ` Jason Gunthorpe
2021-02-18 15:52   ` Gal Pressman
2021-02-18 16:23     ` Jason Gunthorpe
2021-02-18 22:22       ` Tom Talpey
2021-02-18 22:51         ` Jason Gunthorpe
2021-02-18 23:07           ` Tom Talpey
2021-02-19  0:45             ` Jason Gunthorpe
2021-02-19 14:31               ` Tom Talpey
2021-02-19 14:42                 ` Jason Gunthorpe [this message]
2021-02-21  9:25       ` Gal Pressman
2021-02-22 13:46         ` Jason Gunthorpe
2021-02-22 15:36           ` Gal Pressman
2021-02-22 15:55             ` Jason Gunthorpe
2021-02-22 19:24               ` Gal Pressman
2021-02-22 19:37                 ` Jason Gunthorpe
2021-02-23 12:18                   ` Gal Pressman
2021-02-23 12:38                     ` Jason Gunthorpe
2021-02-22 22:41                 ` Hefty, Sean
2021-02-23 12:23                   ` Gal Pressman
2021-02-23 20:48                     ` Hefty, Sean
2021-02-22 18:38             ` Hefty, Sean
2021-02-22 19:26               ` Gal Pressman
2021-02-18 18:47     ` Bernard Metzler

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=20210219144202.GF2643399@ziepe.ca \
    --to=jgg@ziepe.ca \
    --cc=galpress@amazon.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=tom@talpey.com \
    /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.