From: Daniel Mack Date: Mon, 26 May 2014 12:52:37 +0000 (+0200) Subject: usb: musb: fix bit mask for CSR in musb_h_tx_flush_fifo() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=2ccc6d30a0abf3e1a38f264e279428b846712e0f;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git usb: musb: fix bit mask for CSR in musb_h_tx_flush_fifo() The datasheet says that MUSB_TXCSR_FLUSHFIFO is only valid when MUSB_TXCSR_TXPKTRDY is set as well. With this patch applied, the warning in this function does no longer kick in when an USB soundcard is unplugged while the stream is active. Signed-off-by: Daniel Mack Signed-off-by: Felipe Balbi --- diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c index 0745839d7cd8..3381fa56db29 100644 --- a/drivers/usb/musb/musb_host.c +++ b/drivers/usb/musb/musb_host.c @@ -120,7 +120,7 @@ static void musb_h_tx_flush_fifo(struct musb_hw_ep *ep) if (csr != lastcsr) dev_dbg(musb->controller, "Host TX FIFONOTEMPTY csr: %02x\n", csr); lastcsr = csr; - csr |= MUSB_TXCSR_FLUSHFIFO; + csr |= MUSB_TXCSR_FLUSHFIFO | MUSB_TXCSR_TXPKTRDY; musb_writew(epio, MUSB_TXCSR, csr); csr = musb_readw(epio, MUSB_TXCSR); if (WARN(retries-- < 1,