ASoC: qcom: common: set correct directions for dailinks
Currently both FE and BE dai-links are configured bi-directional,
However the DSP BE dais are only single directional,
so set the directions as supported by the BE dais.
Fixes: c25e295cd7
(ASoC: qcom: Add support to parse common audio device nodes)
Reported-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Tested-by: John Stultz <john.stultz@linaro.org>
Reviewed-by: Vinod Koul <vkoul@kernel.org>
Link: https://lore.kernel.org/r/20200612123711.29130-2-srinivas.kandagatla@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
4a95737440
commit
a212008925
1 changed files with 12 additions and 2 deletions
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
#include <linux/module.h>
|
#include <linux/module.h>
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
|
#include "qdsp6/q6afe.h"
|
||||||
|
|
||||||
int qcom_snd_parse_of(struct snd_soc_card *card)
|
int qcom_snd_parse_of(struct snd_soc_card *card)
|
||||||
{
|
{
|
||||||
|
@ -101,6 +102,15 @@ int qcom_snd_parse_of(struct snd_soc_card *card)
|
||||||
}
|
}
|
||||||
link->no_pcm = 1;
|
link->no_pcm = 1;
|
||||||
link->ignore_pmdown_time = 1;
|
link->ignore_pmdown_time = 1;
|
||||||
|
|
||||||
|
if (q6afe_is_rx_port(link->id)) {
|
||||||
|
link->dpcm_playback = 1;
|
||||||
|
link->dpcm_capture = 0;
|
||||||
|
} else {
|
||||||
|
link->dpcm_playback = 0;
|
||||||
|
link->dpcm_capture = 1;
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
dlc = devm_kzalloc(dev, sizeof(*dlc), GFP_KERNEL);
|
dlc = devm_kzalloc(dev, sizeof(*dlc), GFP_KERNEL);
|
||||||
if (!dlc)
|
if (!dlc)
|
||||||
|
@ -113,12 +123,12 @@ int qcom_snd_parse_of(struct snd_soc_card *card)
|
||||||
link->codecs->dai_name = "snd-soc-dummy-dai";
|
link->codecs->dai_name = "snd-soc-dummy-dai";
|
||||||
link->codecs->name = "snd-soc-dummy";
|
link->codecs->name = "snd-soc-dummy";
|
||||||
link->dynamic = 1;
|
link->dynamic = 1;
|
||||||
|
link->dpcm_playback = 1;
|
||||||
|
link->dpcm_capture = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
link->ignore_suspend = 1;
|
link->ignore_suspend = 1;
|
||||||
link->nonatomic = 1;
|
link->nonatomic = 1;
|
||||||
link->dpcm_playback = 1;
|
|
||||||
link->dpcm_capture = 1;
|
|
||||||
link->stream_name = link->name;
|
link->stream_name = link->name;
|
||||||
link++;
|
link++;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue