]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
fix NULL pointer with MUSB and DMA on ISO ep
authorHunyue Yau <hyau@mvista.com>
Thu, 1 Nov 2007 22:40:49 +0000 (15:40 -0700)
committerTony Lindgren <tony@atomide.com>
Thu, 15 Nov 2007 20:51:18 +0000 (12:51 -0800)
For the case of an isochonous endpoint, musb_write_fifo may be
called with a NULL buffer from musb_host_tx if DMA is enabled.
Remove DMA check and always supply a valid buffer as long as
the URB contains a valid buffer.

Signed-off-by: Hunyue Yau <hyau@mvista.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
drivers/usb/musb/musb_host.c

index d8ea84d3de37509ffb13922841f2140ab4521a01..6638dced1f954b0a2126567267479e90097a30cf 100644 (file)
@@ -1268,7 +1268,7 @@ void musb_host_tx(struct musb *musb, u8 epnum)
                        d->actual_length = qh->segsize;
                        if (++qh->iso_idx >= urb->number_of_packets) {
                                done = true;
-                       } else if (!dma) {
+                       } else {
                                d++;
                                buf = urb->transfer_buffer + d->offset;
                                wLength = d->length;