linux-nvme.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: jgunthorpe@obsidianresearch.com (Jason Gunthorpe)
Subject: [PATCH RFC] nvme-rdma: support devices with queue size < 32
Date: Wed, 29 Mar 2017 07:29:18 -0600	[thread overview]
Message-ID: <20170329132918.GA32072@obsidianresearch.com> (raw)
In-Reply-To: <8dc0414f-be90-ee30-0f66-8cee26c4c2aa@grimberg.me>

On Tue, Mar 28, 2017@02:30:14PM +0300, Sagi Grimberg wrote:
> I'm not sure what buffering is needed from the device at all in this
> case, the device is simply expected to avoid signaling completions.
> 
> Mellanox folks, any idea where is this limitation coming from?
> Do we need a device capability for it?

Fundamentally you must drive SQ flow control via CQ completions. For
instance a ULP cannot disable all CQ notifications and keep
stuffing things into the SQ.

An alternative way to state this: A ULP cannot use activity on the
RQ to infer that there is space in the SQ. Only CQ completions can be
used to prove there is more available SQ space. Do not post to the SQ
until a CQ has been polled proving available space.

Ultimately you need a minimum of one CQ notification for every SQ
depth post and the ULP must not post to the SQ once it fills until
it sees the CQ notification. That usually drives the rule of thumb to
notify every 1/2 depth, however any SQWE posting failures indicate a
ULP bug..

There are a bunch of varied reasons for this, and it was discussed to
death for NFS. NFS's bugs and wonkyness in this area went away when
Chuck did strict accounting SQ capicty driven by the CQ...

Jason

  parent reply	other threads:[~2017-03-29 13:29 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-23  9:04 [PATCH RFC] nvme-rdma: support devices with queue size < 32 Marta Rybczynska
2017-03-23  9:24 ` Marta Rybczynska
2017-03-23 14:00 ` Christoph Hellwig
2017-03-23 14:36   ` Marta Rybczynska
2017-03-28 11:09     ` Sagi Grimberg
2017-03-28 11:20       ` Marta Rybczynska
2017-03-28 11:30         ` Sagi Grimberg
2017-03-29  9:36           ` Marta Rybczynska
2017-03-29 13:29           ` Jason Gunthorpe [this message]
2017-03-29 15:47             ` Sagi Grimberg
2017-03-29 16:27               ` Jason Gunthorpe
2017-03-29 16:39                 ` Sagi Grimberg
2017-03-29 16:44                   ` Doug Ledford
2017-03-29 16:47                     ` Doug Ledford
2017-03-29 16:59                       ` Sagi Grimberg
2017-03-29 22:19                         ` Jason Gunthorpe
2017-03-30 14:23                         ` Marta Rybczynska
2017-04-06 12:29                           ` Marta Rybczynska
2017-04-06 13:02                             ` Leon Romanovsky
2017-04-07 13:31                               ` Marta Rybczynska
2017-04-09 12:31                                 ` Sagi Grimberg
2017-04-10 11:29                                   ` Marta Rybczynska

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=20170329132918.GA32072@obsidianresearch.com \
    --to=jgunthorpe@obsidianresearch.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).