All of lore.kernel.org
 help / color / mirror / Atom feed
* FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
@ 2016-05-30 20:08 gregkh
  2016-06-01 13:54 ` Dennis Dalessandro
  2016-06-01 14:42 ` Marciniszyn, Mike
  0 siblings, 2 replies; 6+ messages in thread
From: gregkh @ 2016-05-30 20:08 UTC (permalink / raw)
  To: mike.marciniszyn, dennis.dalessandro, dledford, sebastian.sanchez; +Cc: stable


The patch below does not apply to the 4.6-stable tree.
If someone wants it applied there, or to any other stable or longterm
tree, then please email the backport, including the original git commit
id to <stable@vger.kernel.org>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

>From 7049de65c9e520886f06d6f9deceaaed5d93fb7c Mon Sep 17 00:00:00 2001
From: Mike Marciniszyn <mike.marciniszyn@intel.com>
Date: Tue, 24 May 2016 12:50:23 -0700
Subject: [PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin
 lock

Commit b9b06cb6feda
("IB/hfi1: Fix missing lock/unlock in verbs drain callback")
added a spin lock.

Unfortunately, the new lock code can be called from a base
level interrupt state, and an interrupt that can get stacked
will attempt to get the same lock.

Fix by using the flag save/restore spin lock variation.

Cc: stable@vger.kernel.org # 4.6+
Reviewed-by: Sebastian Sanchez <sebastian.sanchez@intel.com>
Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>

diff --git a/drivers/infiniband/hw/hfi1/qp.c b/drivers/infiniband/hw/hfi1/qp.c
index 14f889e3655b..1a942ffba4cb 100644
--- a/drivers/infiniband/hw/hfi1/qp.c
+++ b/drivers/infiniband/hw/hfi1/qp.c
@@ -512,6 +512,7 @@ static void iowait_wakeup(struct iowait *wait, int reason)
 static void iowait_sdma_drained(struct iowait *wait)
 {
 	struct rvt_qp *qp = iowait_to_qp(wait);
+	unsigned long flags;
 
 	/*
 	 * This happens when the send engine notes
@@ -519,12 +520,12 @@ static void iowait_sdma_drained(struct iowait *wait)
 	 * do the flush work until that QP's
 	 * sdma work has finished.
 	 */
-	spin_lock(&qp->s_lock);
+	spin_lock_irqsave(&qp->s_lock, flags);
 	if (qp->s_flags & RVT_S_WAIT_DMA) {
 		qp->s_flags &= ~RVT_S_WAIT_DMA;
 		hfi1_schedule_send(qp);
 	}
-	spin_unlock(&qp->s_lock);
+	spin_unlock_irqrestore(&qp->s_lock, flags);
 }
 
 /**


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
  2016-05-30 20:08 FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree gregkh
@ 2016-06-01 13:54 ` Dennis Dalessandro
  2016-06-01 14:42 ` Marciniszyn, Mike
  1 sibling, 0 replies; 6+ messages in thread
From: Dennis Dalessandro @ 2016-06-01 13:54 UTC (permalink / raw)
  To: gregkh; +Cc: mike.marciniszyn, dledford, sebastian.sanchez, stable

On Mon, May 30, 2016 at 01:08:17PM -0700, gregkh@linuxfoundation.org wrote:
>
>The patch below does not apply to the 4.6-stable tree.
>If someone wants it applied there, or to any other stable or longterm
>tree, then please email the backport, including the original git commit
>id to <stable@vger.kernel.org>.

Thanks Greg. Most likely the problem is the driver move from staging. We'll 
submit an updated patch with the right location for 4.6.

-Denny

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
  2016-05-30 20:08 FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree gregkh
  2016-06-01 13:54 ` Dennis Dalessandro
@ 2016-06-01 14:42 ` Marciniszyn, Mike
  2016-06-01 16:11   ` gregkh
  1 sibling, 1 reply; 6+ messages in thread
From: Marciniszyn, Mike @ 2016-06-01 14:42 UTC (permalink / raw)
  To: gregkh; +Cc: stable, Dalessandro, Dennis, dledford, Sanchez, Sebastian

> The patch below does not apply to the 4.6-stable tree.
> If someone wants it applied there, or to any other stable or longterm tree,
> then please email the backport, including the original git commit id to
> <stable@vger.kernel.org>.
> 
> thanks,
> 
> greg k-h

http://marc.info/?l=linux-rdma&m=146479189725973&w=2 has the patch for the old staging location.

Mike

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
  2016-06-01 14:42 ` Marciniszyn, Mike
@ 2016-06-01 16:11   ` gregkh
  2016-06-01 16:14     ` gregkh
  2016-06-01 16:16     ` Marciniszyn, Mike
  0 siblings, 2 replies; 6+ messages in thread
From: gregkh @ 2016-06-01 16:11 UTC (permalink / raw)
  To: Marciniszyn, Mike
  Cc: stable, Dalessandro, Dennis, dledford, Sanchez, Sebastian

On Wed, Jun 01, 2016 at 02:42:56PM +0000, Marciniszyn, Mike wrote:
> > The patch below does not apply to the 4.6-stable tree.
> > If someone wants it applied there, or to any other stable or longterm tree,
> > then please email the backport, including the original git commit id to
> > <stable@vger.kernel.org>.
> > 
> > thanks,
> > 
> > greg k-h
> 
> http://marc.info/?l=linux-rdma&m=146479189725973&w=2 has the patch for the old staging location.

Is that what should be used here?  If so, can someone forward it on to
the stable@ address?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
  2016-06-01 16:11   ` gregkh
@ 2016-06-01 16:14     ` gregkh
  2016-06-01 16:16     ` Marciniszyn, Mike
  1 sibling, 0 replies; 6+ messages in thread
From: gregkh @ 2016-06-01 16:14 UTC (permalink / raw)
  To: Marciniszyn, Mike
  Cc: stable, Dalessandro, Dennis, dledford, Sanchez, Sebastian

On Wed, Jun 01, 2016 at 09:11:02AM -0700, gregkh@linuxfoundation.org wrote:
> On Wed, Jun 01, 2016 at 02:42:56PM +0000, Marciniszyn, Mike wrote:
> > > The patch below does not apply to the 4.6-stable tree.
> > > If someone wants it applied there, or to any other stable or longterm tree,
> > > then please email the backport, including the original git commit id to
> > > <stable@vger.kernel.org>.
> > > 
> > > thanks,
> > > 
> > > greg k-h
> > 
> > http://marc.info/?l=linux-rdma&m=146479189725973&w=2 has the patch for the old staging location.
> 
> Is that what should be used here?  If so, can someone forward it on to
> the stable@ address?

Ah, nevermind, didn't realize that you had just done this and that this
was the link to the message, sorry for the noise, I'll take this one :)

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree
  2016-06-01 16:11   ` gregkh
  2016-06-01 16:14     ` gregkh
@ 2016-06-01 16:16     ` Marciniszyn, Mike
  1 sibling, 0 replies; 6+ messages in thread
From: Marciniszyn, Mike @ 2016-06-01 16:16 UTC (permalink / raw)
  To: gregkh; +Cc: stable, Dalessandro, Dennis, dledford, Sanchez, Sebastian

> 
> On Wed, Jun 01, 2016 at 02:42:56PM +0000, Marciniszyn, Mike wrote:
> > > The patch below does not apply to the 4.6-stable tree.
> > > If someone wants it applied there, or to any other stable or
> > > longterm tree, then please email the backport, including the
> > > original git commit id to <stable@vger.kernel.org>.
> > >
> > > thanks,
> > >
> > > greg k-h
> >
> > http://marc.info/?l=linux-rdma&m=146479189725973&w=2 has the patch
> for the old staging location.
> 
> Is that what should be used here?  If so, can someone forward it on to the
> stable@ address?
> 
> thanks,
> 
> greg k-h

I emailed it to stable@vger.kernel.org.   I also CC'ed linux-rdma in the same email.   The above link is from the marc linux-rdma archive.

Mike

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-06-01 16:16 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-30 20:08 FAILED: patch "[PATCH] IB/hfi1: Fix hard lockup due to not using save/restore spin" failed to apply to 4.6-stable tree gregkh
2016-06-01 13:54 ` Dennis Dalessandro
2016-06-01 14:42 ` Marciniszyn, Mike
2016-06-01 16:11   ` gregkh
2016-06-01 16:14     ` gregkh
2016-06-01 16:16     ` Marciniszyn, Mike

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.