summaryrefslogtreecommitdiffstats
path: root/include/sound/dmaengine_pcm.h
diff options
context:
space:
mode:
authorShengjiu Wang <shengjiu.wang@nxp.com>2019-09-27 03:46:11 +0200
committerMark Brown <broonie@kernel.org>2019-10-01 13:18:25 +0200
commite957204e732bc2916a241dc61dd7dd14e9a98350 (patch)
tree41d1daf1182778a9d3cc23522c264af3e240996b /include/sound/dmaengine_pcm.h
parentASoC: fsl_asrc: update supported sample format (diff)
downloadlinux-e957204e732bc2916a241dc61dd7dd14e9a98350.tar.xz
linux-e957204e732bc2916a241dc61dd7dd14e9a98350.zip
ASoC: pcm_dmaengine: Extract snd_dmaengine_pcm_refine_runtime_hwparams
When set the runtime hardware parameters, we may need to query the capability of DMA to complete the parameters. This patch is to Extract this operation from dmaengine_pcm_set_runtime_hwparams function to a separate function snd_dmaengine_pcm_refine_runtime_hwparams, that other components which need this feature can call this function. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Reviewed-by: Nicolin Chen <nicoleotsuka@gmail.com> Link: https://lore.kernel.org/r/d728f65194e9978cbec4132b522d4fed420d704a.1569493933.git.shengjiu.wang@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'include/sound/dmaengine_pcm.h')
-rw-r--r--include/sound/dmaengine_pcm.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/sound/dmaengine_pcm.h b/include/sound/dmaengine_pcm.h
index c679f6116580..b65220685920 100644
--- a/include/sound/dmaengine_pcm.h
+++ b/include/sound/dmaengine_pcm.h
@@ -83,6 +83,11 @@ void snd_dmaengine_pcm_set_config_from_dai_data(
const struct snd_dmaengine_dai_dma_data *dma_data,
struct dma_slave_config *config);
+int snd_dmaengine_pcm_refine_runtime_hwparams(
+ struct snd_pcm_substream *substream,
+ struct snd_dmaengine_dai_dma_data *dma_data,
+ struct snd_pcm_hardware *hw,
+ struct dma_chan *chan);
/*
* Try to request the DMA channel using compat_request_channel or