All of lore.kernel.org
 help / color / mirror / Atom feed
From: Doug Ledford <dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Steve Wise <swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH rdma-next 0/5] iw_cxgb4: handle fw reply timeouts
Date: Fri, 29 Sep 2017 11:48:54 -0400	[thread overview]
Message-ID: <1506700134.2919.23.camel@redhat.com> (raw)
In-Reply-To: <cover.1506545745.git.swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>

On Wed, 2017-09-27 at 13:55 -0700, Steve Wise wrote:
> For messages sent from the host to fw that solicit a reply from fw,
> the c4iw_wr_wait struct pointer is passed in the host->fw message,
> and
> included in the fw->host fw6_msg reply.  This allows the sender to
> wait
> until the reply is received, and the code processing the ingress
> reply
> to wake up the sender.
> 
> If c4iw_wait_for_reply() times out, however, we need to keep the
> c4iw_wr_wait object around in case the reply eventually does arrive.
> Otherwise we have touch-after-free bugs in the wake_up paths.
> 
> This series refactors the c4iw_wait_wr users and the wait API to
> handle
> this case.  The first 4 patches change the users to allocate the wait
> object vs using it locally on the stack, and the 5th patch
> implmements the
> new kref for the wait objects.
> 
> Steve Wise (5):
>   iw_cxgb4: allocate wait object for each memory object
>   iw_cxgb4: allocate wait object for each cq object
>   iw_cxgb4: allocate wait object for each qp object
>   iw_cxgb4: allocate wait object for each ep object
>   iw_cxgb4: add referencing to wait objects
> 
>  drivers/infiniband/hw/cxgb4/cm.c       |  40 +++---
>  drivers/infiniband/hw/cxgb4/cq.c       |  69 +++++-----
>  drivers/infiniband/hw/cxgb4/device.c   |  21 +++
>  drivers/infiniband/hw/cxgb4/iw_cxgb4.h |  66 ++++++++-
>  drivers/infiniband/hw/cxgb4/mem.c      | 242 ++++++++++++++++++++---
> ----------
>  drivers/infiniband/hw/cxgb4/qp.c       |  82 +++++------
>  6 files changed, 330 insertions(+), 190 deletions(-)

Thanks Steve, applied.

-- 
Doug Ledford <dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
    GPG KeyID: B826A3330E572FDD
    Key fingerprint = AE6B 1BDA 122B 23B4 265B  1274 B826 A333 0E57 2FDD

--
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

      parent reply	other threads:[~2017-09-29 15:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-27 20:55 [PATCH rdma-next 0/5] iw_cxgb4: handle fw reply timeouts Steve Wise
     [not found] ` <cover.1506545745.git.swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2017-09-26 20:07   ` [PATCH rdma-next 1/5] iw_cxgb4: allocate wait object for each memory object Steve Wise
2017-09-26 20:08   ` [PATCH rdma-next 2/5] iw_cxgb4: allocate wait object for each cq object Steve Wise
2017-09-26 20:11   ` [PATCH rdma-next 3/5] iw_cxgb4: allocate wait object for each qp object Steve Wise
2017-09-26 20:12   ` [PATCH rdma-next 4/5] iw_cxgb4: allocate wait object for each ep object Steve Wise
2017-09-26 20:13   ` [PATCH rdma-next 5/5] iw_cxgb4: add referencing to wait objects Steve Wise
2017-09-29 15:48   ` Doug Ledford [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=1506700134.2919.23.camel@redhat.com \
    --to=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 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.