* Patch "usb: musb: dsps: implement clear_ep_rxintr() callback" has been added to the 4.4-stable tree
@ 2017-01-09 9:33 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2017-01-09 9:33 UTC (permalink / raw)
To: b-liu, gregkh; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
usb: musb: dsps: implement clear_ep_rxintr() callback
to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
usb-musb-dsps-implement-clear_ep_rxintr-callback.patch
and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From c48400baa02155a5ddad63e8554602e48782278c Mon Sep 17 00:00:00 2001
From: Bin Liu <b-liu@ti.com>
Date: Tue, 3 Jan 2017 18:13:47 -0600
Subject: usb: musb: dsps: implement clear_ep_rxintr() callback
From: Bin Liu <b-liu@ti.com>
commit c48400baa02155a5ddad63e8554602e48782278c upstream.
During dma teardown for dequque urb, if musb load is high, musb might
generate bogus rx ep interrupt even when the rx fifo is flushed. In such
case any of the follow log messages could happen.
musb_host_rx 1853: BOGUS RX2 ready, csr 0000, count 0
musb_host_rx 1936: RX3 dma busy, csr 2020
As mentioned in the current inline comment, clearing ep interrupt in the
teardown path avoids the bogus interrupt, so implement clear_ep_rxintr()
callback.
This bug seems to be existing since the initial driver for musb support,
but I only validated the fix back to v4.1, so only cc stable for v4.1+.
Signed-off-by: Bin Liu <b-liu@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/usb/musb/musb_dsps.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
--- a/drivers/usb/musb/musb_dsps.c
+++ b/drivers/usb/musb/musb_dsps.c
@@ -301,6 +301,17 @@ static void otg_timer(unsigned long _mus
spin_unlock_irqrestore(&musb->lock, flags);
}
+void dsps_musb_clear_ep_rxintr(struct musb *musb, int epnum)
+{
+ u32 epintr;
+ struct dsps_glue *glue = dev_get_drvdata(musb->controller->parent);
+ const struct dsps_musb_wrapper *wrp = glue->wrp;
+
+ /* musb->lock might already been held */
+ epintr = (1 << epnum) << wrp->rxep_shift;
+ musb_writel(musb->ctrl_base, wrp->epintr_status, epintr);
+}
+
static irqreturn_t dsps_interrupt(int irq, void *hci)
{
struct musb *musb = hci;
@@ -647,6 +658,7 @@ static struct musb_platform_ops dsps_ops
.try_idle = dsps_musb_try_idle,
.set_mode = dsps_musb_set_mode,
.recover = dsps_musb_recover,
+ .clear_ep_rxintr = dsps_musb_clear_ep_rxintr,
};
static u64 musb_dmamask = DMA_BIT_MASK(32);
Patches currently in stable-queue which might be from b-liu@ti.com are
queue-4.4/usb-musb-dsps-implement-clear_ep_rxintr-callback.patch
queue-4.4/usb-musb-core-add-clear_ep_rxintr-to-musb_platform_ops.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-01-09 9:33 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-09 9:33 Patch "usb: musb: dsps: implement clear_ep_rxintr() callback" has been added to the 4.4-stable tree gregkh
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).