]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - arch/mips/txx9/generic/setup_tx4927.c
MIPS: TXx9: Add DMAC support
[net-next-2.6.git] / arch / mips / txx9 / generic / setup_tx4927.c
index 1093549df1a8f07a78d80ac58842402a432791a1..6b681cd7f8fb6c74204b668f5babd26f156f2294 100644 (file)
@@ -22,6 +22,7 @@
 #include <asm/txx9tmr.h>
 #include <asm/txx9pio.h>
 #include <asm/txx9/generic.h>
+#include <asm/txx9/dmac.h>
 #include <asm/txx9/tx4927.h>
 
 static void __init tx4927_wdr_init(void)
@@ -253,6 +254,17 @@ void __init tx4927_mtd_init(int ch)
        txx9_physmap_flash_init(ch, start, size, &pdata);
 }
 
+void __init tx4927_dmac_init(int memcpy_chan)
+{
+       struct txx9dmac_platform_data plat_data = {
+               .memcpy_chan = memcpy_chan,
+               .have_64bit_regs = true,
+       };
+
+       txx9_dmac_init(0, TX4927_DMA_REG & 0xfffffffffULL,
+                      TXX9_IRQ_BASE + TX4927_IR_DMA(0), &plat_data);
+}
+
 static void __init tx4927_stop_unused_modules(void)
 {
        __u64 pcfg, rst = 0, ckd = 0;