Title: [7685] trunk/arch/blackfin/kernel/bfin_dma_5xx.c: [#5610] DMA Channel 14 failed to suspend in mem in bf527 with lcd module
- Revision
- 7685
- Author
- hennerich
- Date
- 2009-10-20 09:38:04 -0400 (Tue, 20 Oct 2009)
Log Message
[#5610] DMA Channel 14 failed to suspend in mem in bf527 with lcd module
installed
During PM state suspend mem transitions - the Blackfin BOOTROM utilizes
MEMDMA1 - but doesn't clear MDMA_S1_CONFIG, MDMA_D1_CONFIG afterwards -
so the blackfin_dma_suspend() check for DMAEN will fail the second time.
Fixed by clearing all DMA Channel Config registers after resume from
suspend mem.
Modified Paths
Diff
Modified: trunk/arch/blackfin/kernel/bfin_dma_5xx.c (7684 => 7685)
--- trunk/arch/blackfin/kernel/bfin_dma_5xx.c 2009-10-20 12:31:09 UTC (rev 7684)
+++ trunk/arch/blackfin/kernel/bfin_dma_5xx.c 2009-10-20 13:38:04 UTC (rev 7685)
@@ -214,8 +214,13 @@
void blackfin_dma_resume(void)
{
int i;
- for (i = 0; i < MAX_DMA_SUSPEND_CHANNELS; ++i)
- dma_ch[i].regs->peripheral_map = dma_ch[i].saved_peripheral_map;
+
+ for (i = 0; i < MAX_DMA_CHANNELS; ++i) {
+ dma_ch[i].regs->cfg = 0;
+
+ if (i < MAX_DMA_SUSPEND_CHANNELS)
+ dma_ch[i].regs->peripheral_map = dma_ch[i].saved_peripheral_map;
+ }
}
#endif
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits