[Sound-open-firmware] [RFC PATCH v2 5/5] APL/CNL: Initialize DMA trace data structure and definition on APL/CNL.
yan.wang at linux.intel.com
yan.wang at linux.intel.com
Wed Mar 14 07:51:15 CET 2018
From: Yan Wang <yan.wang at linux.intel.com>
Add dma_trace_init_complete() calling on APL/CNL platform.
And use DMA_HOST_IN_DMAC as PLATFORM_TRACE_DMAC for DMA trace copying.
Signed-off-by: Yan Wang <yan.wang at linux.intel.com>
---
src/platform/apollolake/include/platform/platform.h | 2 +-
src/platform/apollolake/platform.c | 3 +++
src/platform/cannonlake/include/platform/platform.h | 2 +-
src/platform/cannonlake/platform.c | 3 +++
4 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/src/platform/apollolake/include/platform/platform.h b/src/platform/apollolake/include/platform/platform.h
index 8a84308..fd2eba6 100644
--- a/src/platform/apollolake/include/platform/platform.h
+++ b/src/platform/apollolake/include/platform/platform.h
@@ -98,7 +98,7 @@ struct reef;
#define DMA_TRACE_RESCHEDULE_TIME 5000
/* DMAC used for trace DMA */
-#define PLATFORM_TRACE_DMAC DMA_ID_DMAC0
+#define PLATFORM_TRACE_DMAC DMA_HOST_IN_DMAC
/* DSP should be idle in this time frame */
#define PLATFORM_IDLE_TIME 750000
diff --git a/src/platform/apollolake/platform.c b/src/platform/apollolake/platform.c
index 9574970..84f8e71 100644
--- a/src/platform/apollolake/platform.c
+++ b/src/platform/apollolake/platform.c
@@ -262,5 +262,8 @@ int platform_init(struct reef *reef)
dai_probe(ssp);
}
+ /* Initialize DMA for Trace*/
+ dma_trace_init_complete(reef->dmat);
+
return 0;
}
diff --git a/src/platform/cannonlake/include/platform/platform.h b/src/platform/cannonlake/include/platform/platform.h
index 06a5599..feeeb6c 100644
--- a/src/platform/cannonlake/include/platform/platform.h
+++ b/src/platform/cannonlake/include/platform/platform.h
@@ -102,7 +102,7 @@ struct reef;
#define DMA_TRACE_RESCHEDULE_TIME 5000
/* DMAC used for trace DMA */
-#define PLATFORM_TRACE_DMAC DMA_ID_DMAC0
+#define PLATFORM_TRACE_DMAC DMA_HOST_IN_DMAC
/* DSP should be idle in this time frame */
#define PLATFORM_IDLE_TIME 750000
diff --git a/src/platform/cannonlake/platform.c b/src/platform/cannonlake/platform.c
index c9449ed..8bf2d7a 100644
--- a/src/platform/cannonlake/platform.c
+++ b/src/platform/cannonlake/platform.c
@@ -283,5 +283,8 @@ int platform_init(struct reef *reef)
dai_probe(ssp);
}
+ /* Initialize DMA for Trace*/
+ dma_trace_init_complete(reef->dmat);
+
return 0;
}
--
2.14.3
More information about the Sound-open-firmware
mailing list