summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnand Gadiyar <gadiyar@ti.com>2010-07-08 16:34:55 +0530
committerStephen Rothwell <sfr@canb.auug.org.au>2010-07-12 11:40:10 +1000
commitb9e0f0e917461425ea17308ecc3d7d02961b2b30 (patch)
treed8b8d5f8fb00f1bed3c7c252c00cb65057004a38
parent68d5bfebafcc699dce814e8f671bd6478e360664 (diff)
USB: musb: do not override DMA mode in channel program
There is no reason for the DMA channel program to override the DMA mode passed down by its caller. Use the passed parameter directly, and let the caller handle the decision on which mode is to be used. Signed-off-by: Anand Gadiyar <gadiyar@ti.com> Acked-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Ajay Kumar Gupta <ajay.gupta@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/usb/musb/musbhsdma.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/usb/musb/musbhsdma.c b/drivers/usb/musb/musbhsdma.c
index dc66e4376d49..6dc107f25245 100644
--- a/drivers/usb/musb/musbhsdma.c
+++ b/drivers/usb/musb/musbhsdma.c
@@ -173,10 +173,7 @@ static int dma_channel_program(struct dma_channel *channel,
musb_channel->max_packet_sz = packet_sz;
channel->status = MUSB_DMA_STATUS_BUSY;
- if ((mode == 1) && (len >= packet_sz))
- configure_channel(channel, packet_sz, 1, dma_addr, len);
- else
- configure_channel(channel, packet_sz, 0, dma_addr, len);
+ configure_channel(channel, packet_sz, mode, dma_addr, len);
return true;
}