Host DMA needs it's own timeout as its not bound to any synchronous data transfer timings.
Signed-off-by: Liam Girdwood liam.r.girdwood@linux.intel.com --- src/audio/host.c | 2 +- src/ipc/intel-ipc.c | 2 +- src/platform/baytrail/include/platform/platform.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/audio/host.c b/src/audio/host.c index c1c7485..944edfe 100644 --- a/src/audio/host.c +++ b/src/audio/host.c @@ -451,7 +451,7 @@ static int host_preload(struct comp_dev *dev) wait_init(&hd->complete);
/* do DMA transfer */ - hd->complete.timeout = PLATFORM_DMA_TIMEOUT; + hd->complete.timeout = PLATFORM_HOST_DMA_TIMEOUT; dma_set_config(hd->dma, hd->chan, &hd->config); dma_start(hd->dma, hd->chan);
diff --git a/src/ipc/intel-ipc.c b/src/ipc/intel-ipc.c index f1e06e9..d122b30 100644 --- a/src/ipc/intel-ipc.c +++ b/src/ipc/intel-ipc.c @@ -140,7 +140,7 @@ static int get_page_descriptors(struct intel_ipc_data *iipc, dma_start(dma, chan);
/* wait for DMA to complete */ - iipc->complete.timeout = PLATFORM_IPC_DMA_TIMEOUT; + iipc->complete.timeout = PLATFORM_HOST_DMA_TIMEOUT; ret = wait_for_completion_timeout(&iipc->complete);
/* compressed page tables now in buffer at _ipc->page_table */ diff --git a/src/platform/baytrail/include/platform/platform.h b/src/platform/baytrail/include/platform/platform.h index 493afd8..d083479 100644 --- a/src/platform/baytrail/include/platform/platform.h +++ b/src/platform/baytrail/include/platform/platform.h @@ -67,8 +67,8 @@ struct reef; /* DMA channel drain timeout in microseconds - TODO: caclulate based on topology */ #define PLATFORM_DMA_TIMEOUT 1333
-/* IPC page data copy timeout */ -#define PLATFORM_IPC_DMA_TIMEOUT 2000 +/* DMA host transfer timeouts in microseconds */ +#define PLATFORM_HOST_DMA_TIMEOUT 50
/* WorkQ window size in microseconds */ #define PLATFORM_WORKQ_WINDOW 2000