diff options
Diffstat (limited to 'arch/arm/plat-omap/dma.c')
-rw-r--r-- | arch/arm/plat-omap/dma.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c index 0eb676d7e807..b53125f41293 100644 --- a/arch/arm/plat-omap/dma.c +++ b/arch/arm/plat-omap/dma.c | |||
@@ -978,6 +978,14 @@ void omap_stop_dma(int lch) | |||
978 | { | 978 | { |
979 | u32 l; | 979 | u32 l; |
980 | 980 | ||
981 | /* Disable all interrupts on the channel */ | ||
982 | if (cpu_class_is_omap1()) | ||
983 | dma_write(0, CICR(lch)); | ||
984 | |||
985 | l = dma_read(CCR(lch)); | ||
986 | l &= ~OMAP_DMA_CCR_EN; | ||
987 | dma_write(l, CCR(lch)); | ||
988 | |||
981 | if (!omap_dma_in_1510_mode() && dma_chan[lch].next_lch != -1) { | 989 | if (!omap_dma_in_1510_mode() && dma_chan[lch].next_lch != -1) { |
982 | int next_lch, cur_lch = lch; | 990 | int next_lch, cur_lch = lch; |
983 | char dma_chan_link_map[OMAP_DMA4_LOGICAL_DMA_CH_COUNT]; | 991 | char dma_chan_link_map[OMAP_DMA4_LOGICAL_DMA_CH_COUNT]; |
@@ -995,18 +1003,8 @@ void omap_stop_dma(int lch) | |||
995 | next_lch = dma_chan[cur_lch].next_lch; | 1003 | next_lch = dma_chan[cur_lch].next_lch; |
996 | cur_lch = next_lch; | 1004 | cur_lch = next_lch; |
997 | } while (next_lch != -1); | 1005 | } while (next_lch != -1); |
998 | |||
999 | return; | ||
1000 | } | 1006 | } |
1001 | 1007 | ||
1002 | /* Disable all interrupts on the channel */ | ||
1003 | if (cpu_class_is_omap1()) | ||
1004 | dma_write(0, CICR(lch)); | ||
1005 | |||
1006 | l = dma_read(CCR(lch)); | ||
1007 | l &= ~OMAP_DMA_CCR_EN; | ||
1008 | dma_write(l, CCR(lch)); | ||
1009 | |||
1010 | dma_chan[lch].flags &= ~OMAP_DMA_ACTIVE; | 1008 | dma_chan[lch].flags &= ~OMAP_DMA_ACTIVE; |
1011 | } | 1009 | } |
1012 | EXPORT_SYMBOL(omap_stop_dma); | 1010 | EXPORT_SYMBOL(omap_stop_dma); |