diff options
author | Sylwester Nawrocki <s.nawrocki@samsung.com> | 2017-01-17 14:16:42 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2017-01-23 18:16:33 +0000 |
commit | b8ab0ccc0b6e517ff595f1b06fb9f578c8b4001f (patch) | |
tree | e1aef3337536b6f108cf95748d8641ba147fbc28 /sound/soc/samsung/dmaengine.c | |
parent | a5de5b74a50113564a1e0850e2da96c37c35e55d (diff) | |
download | blackbird-op-linux-b8ab0ccc0b6e517ff595f1b06fb9f578c8b4001f.tar.gz blackbird-op-linux-b8ab0ccc0b6e517ff595f1b06fb9f578c8b4001f.zip |
ASoC: Revert "samsung: Remove unneeded initialization of chan_name"
This reverts commit cdaf9af1eaeb539e32bfd6da6310b41ad6c3ba23
which breaks I2S support on the non-DT Samsung SoC platforms,
since the default "tx", "rx" DMA channel names for playback
and capture streams or custom channel names in struct
snd_dmaengine_pcm_config are supported in the ASoC dmaengine
module only for devicetree booting case.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/samsung/dmaengine.c')
-rw-r--r-- | sound/soc/samsung/dmaengine.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sound/soc/samsung/dmaengine.c b/sound/soc/samsung/dmaengine.c index cda656e4afc6..9104c98deeb7 100644 --- a/sound/soc/samsung/dmaengine.c +++ b/sound/soc/samsung/dmaengine.c @@ -37,8 +37,12 @@ int samsung_asoc_dma_platform_register(struct device *dev, dma_filter_fn filter, pcm_conf->prepare_slave_config = snd_dmaengine_pcm_prepare_slave_config; pcm_conf->compat_filter_fn = filter; - pcm_conf->chan_names[SNDRV_PCM_STREAM_PLAYBACK] = tx; - pcm_conf->chan_names[SNDRV_PCM_STREAM_CAPTURE] = rx; + if (dev->of_node) { + pcm_conf->chan_names[SNDRV_PCM_STREAM_PLAYBACK] = tx; + pcm_conf->chan_names[SNDRV_PCM_STREAM_CAPTURE] = rx; + } else { + flags |= SND_DMAENGINE_PCM_FLAG_CUSTOM_CHANNEL_NAME; + } return devm_snd_dmaengine_pcm_register(dev, pcm_conf, flags); } |