diff options
-rw-r--r-- | drivers/usb/musb/musb_cppi41.c | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/drivers/usb/musb/musb_cppi41.c b/drivers/usb/musb/musb_cppi41.c index 00e272bfee39..355655f8a3fb 100644 --- a/drivers/usb/musb/musb_cppi41.c +++ b/drivers/usb/musb/musb_cppi41.c | |||
@@ -238,8 +238,27 @@ static void cppi41_dma_callback(void *private_data, | |||
238 | transferred < cppi41_channel->packet_sz) | 238 | transferred < cppi41_channel->packet_sz) |
239 | cppi41_channel->prog_len = 0; | 239 | cppi41_channel->prog_len = 0; |
240 | 240 | ||
241 | if (cppi41_channel->is_tx) | 241 | if (cppi41_channel->is_tx) { |
242 | empty = musb_is_tx_fifo_empty(hw_ep); | 242 | u8 type; |
243 | |||
244 | if (is_host_active(musb)) | ||
245 | type = hw_ep->out_qh->type; | ||
246 | else | ||
247 | type = hw_ep->ep_in.type; | ||
248 | |||
249 | if (type == USB_ENDPOINT_XFER_ISOC) | ||
250 | /* | ||
251 | * Don't use the early-TX-interrupt workaround below | ||
252 | * for Isoch transfter. Since Isoch are periodic | ||
253 | * transfer, by the time the next transfer is | ||
254 | * scheduled, the current one should be done already. | ||
255 | * | ||
256 | * This avoids audio playback underrun issue. | ||
257 | */ | ||
258 | empty = true; | ||
259 | else | ||
260 | empty = musb_is_tx_fifo_empty(hw_ep); | ||
261 | } | ||
243 | 262 | ||
244 | if (!cppi41_channel->is_tx || empty) { | 263 | if (!cppi41_channel->is_tx || empty) { |
245 | cppi41_trans_done(cppi41_channel); | 264 | cppi41_trans_done(cppi41_channel); |