From ff2733c0eb630657c05640f12c0dc6a457dc50b9 Mon Sep 17 00:00:00 2001 From: Sudheer Papothi Date: Fri, 17 May 2019 01:49:27 +0530 Subject: [PATCH] ASoC: Kona: Avoid static route between cpu and codec dai Currently ASoC core creates a static route b/w playback/capture widgets of cpu and codec dai if they are part of the same dai-link. However this will cause codec path to get powered up first followed by the backend dai start during device switch use-case where the front-end is not closed, leading to audio playback failure if either bit-width or sample rate is different. Set the dynamic bit of backend dai dailink to update the backend parameters before codec path setup. Change-Id: Ic80755a5672849f527d5d696d31174a62997aca2 Signed-off-by: Sudheer Papothi --- asoc/kona.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/asoc/kona.c b/asoc/kona.c index 50a25b17ff..ce0c56d1f8 100644 --- a/asoc/kona.c +++ b/asoc/kona.c @@ -5068,6 +5068,7 @@ static struct snd_soc_dai_link msm_common_be_dai_links[] = { .platform_name = "msm-pcm-routing", .codec_name = "msm-stub-codec.1", .codec_dai_name = "msm-stub-rx", + .dynamic_be = 1, .no_pcm = 1, .dpcm_playback = 1, .id = MSM_BACKEND_DAI_USB_RX, @@ -5534,6 +5535,7 @@ static struct snd_soc_dai_link msm_rx_tx_cdc_dma_be_dai_links[] = { .platform_name = "msm-pcm-routing", .codec_name = "bolero_codec", .codec_dai_name = "rx_macro_rx1", + .dynamic_be = 1, .no_pcm = 1, .dpcm_playback = 1, .id = MSM_BACKEND_DAI_RX_CDC_DMA_RX_0, @@ -5549,6 +5551,7 @@ static struct snd_soc_dai_link msm_rx_tx_cdc_dma_be_dai_links[] = { .platform_name = "msm-pcm-routing", .codec_name = "bolero_codec", .codec_dai_name = "rx_macro_rx2", + .dynamic_be = 1, .no_pcm = 1, .dpcm_playback = 1, .id = MSM_BACKEND_DAI_RX_CDC_DMA_RX_1, @@ -5564,6 +5567,7 @@ static struct snd_soc_dai_link msm_rx_tx_cdc_dma_be_dai_links[] = { .platform_name = "msm-pcm-routing", .codec_name = "bolero_codec", .codec_dai_name = "rx_macro_rx3", + .dynamic_be = 1, .no_pcm = 1, .dpcm_playback = 1, .id = MSM_BACKEND_DAI_RX_CDC_DMA_RX_2, @@ -5579,6 +5583,7 @@ static struct snd_soc_dai_link msm_rx_tx_cdc_dma_be_dai_links[] = { .platform_name = "msm-pcm-routing", .codec_name = "bolero_codec", .codec_dai_name = "rx_macro_rx4", + .dynamic_be = 1, .no_pcm = 1, .dpcm_playback = 1, .id = MSM_BACKEND_DAI_RX_CDC_DMA_RX_3,