From: Jason Gunthorpe <jgg-uk2M96/98Pc@public.gmane.org>
To: Steve Wise <swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
Cc: dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [rdma-rc] iw_cxgb4: only insert drain cqes if wq is flushed
Date: Mon, 11 Dec 2017 15:46:04 -0700 [thread overview]
Message-ID: <20171211224604.GA14716@ziepe.ca> (raw)
In-Reply-To: <20171206200809.AF14C87CA-4JwuKsrtP3INXE9Dec0ohg@public.gmane.org>
On Mon, Nov 27, 2017 at 01:16:32PM -0800, Steve Wise wrote:
> Only insert our special drain CQEs to support ib_drain_sq/rq() after
> the wq is flushed. Otherwise, existing but not yet polled CQEs can be
> returned out of order to the user application. This can happen when the
> QP has exited RTS but not yet flushed the QP, which can happen during
> a normal close (vs abortive close).
>
> In addition never count the drain CQEs when determining how many CQEs
> need to be synthesized during the flush operation. This latter issue
> should never happen if the QP is properly flushed before inserting the
> drain CQE, but I wanted to avoid corrupting the CQ state. So we handle
> it and log a warning once.
>
> Fixes: 4fe7c2962e11 ("iw_cxgb4: refactor sq/rq drain logic")
> Signed-off-by: Steve Wise <swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
> Cc: stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> drivers/infiniband/hw/cxgb4/cq.c | 5 +++++
> drivers/infiniband/hw/cxgb4/qp.c | 14 ++++++++++++--
> 2 files changed, 17 insertions(+), 2 deletions(-)
Thanks applied to -rc
Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2017-12-11 22:46 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-27 21:16 [PATCH rdma-rc] iw_cxgb4: only insert drain cqes if wq is flushed Steve Wise
[not found] ` <20171206200809.AF14C87CA-4JwuKsrtP3INXE9Dec0ohg@public.gmane.org>
2017-12-11 22:46 ` Jason Gunthorpe [this message]
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=20171211224604.GA14716@ziepe.ca \
--to=jgg-uk2m96/98pc@public.gmane.org \
--cc=dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.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 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).