diff options
author | Arnaud Pouliquen <arnaud.pouliquen@st.com> | 2019-04-05 11:19:11 +0200 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-04-08 13:37:55 +0700 |
commit | 17d3069ccf06970e2db3f7cbf4335f207524279e (patch) | |
tree | d6e549dcf058b7cdd5c4fecc2c9e658296851928 /sound/soc | |
parent | 54f8844e3f6cf898450a6c85f70fa997f0aa72b9 (diff) |
ASoC: stm32: fix sai driver name initialisation
This patch fixes the sai driver structure overwriting which results in
a cpu dai name equal NULL.
Fixes: 3e086ed ("ASoC: stm32: add SAI driver")
Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@st.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/stm/stm32_sai_sub.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/stm/stm32_sai_sub.c b/sound/soc/stm/stm32_sai_sub.c index 55d802f51c15..83d8a7ac56f4 100644 --- a/sound/soc/stm/stm32_sai_sub.c +++ b/sound/soc/stm/stm32_sai_sub.c @@ -1419,7 +1419,6 @@ static int stm32_sai_sub_dais_init(struct platform_device *pdev, if (!sai->cpu_dai_drv) return -ENOMEM; - sai->cpu_dai_drv->name = dev_name(&pdev->dev); if (STM_SAI_IS_PLAYBACK(sai)) { memcpy(sai->cpu_dai_drv, &stm32_sai_playback_dai, sizeof(stm32_sai_playback_dai)); @@ -1429,6 +1428,7 @@ static int stm32_sai_sub_dais_init(struct platform_device *pdev, sizeof(stm32_sai_capture_dai)); sai->cpu_dai_drv->capture.stream_name = sai->cpu_dai_drv->name; } + sai->cpu_dai_drv->name = dev_name(&pdev->dev); return 0; } |