diff options
-rw-r--r-- | sound/soc/intel/boards/kbl_da7219_max98357a.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/sound/soc/intel/boards/kbl_da7219_max98357a.c b/sound/soc/intel/boards/kbl_da7219_max98357a.c index 60e739f3d6f3..94294c27d1db 100644 --- a/sound/soc/intel/boards/kbl_da7219_max98357a.c +++ b/sound/soc/intel/boards/kbl_da7219_max98357a.c | |||
@@ -65,14 +65,6 @@ static int platform_clock_control(struct snd_soc_dapm_widget *w, | |||
65 | return -EIO; | 65 | return -EIO; |
66 | } | 66 | } |
67 | 67 | ||
68 | /* Configure sysclk for codec */ | ||
69 | ret = snd_soc_dai_set_sysclk(codec_dai, DA7219_CLKSRC_MCLK, 24576000, | ||
70 | SND_SOC_CLOCK_IN); | ||
71 | if (ret) { | ||
72 | dev_err(card->dev, "can't set codec sysclk configuration\n"); | ||
73 | return ret; | ||
74 | } | ||
75 | |||
76 | if (SND_SOC_DAPM_EVENT_OFF(event)) { | 68 | if (SND_SOC_DAPM_EVENT_OFF(event)) { |
77 | ret = snd_soc_dai_set_pll(codec_dai, 0, | 69 | ret = snd_soc_dai_set_pll(codec_dai, 0, |
78 | DA7219_SYSCLK_MCLK, 0, 0); | 70 | DA7219_SYSCLK_MCLK, 0, 0); |
@@ -169,9 +161,18 @@ static int kabylake_da7219_codec_init(struct snd_soc_pcm_runtime *rtd) | |||
169 | { | 161 | { |
170 | struct kbl_codec_private *ctx = snd_soc_card_get_drvdata(rtd->card); | 162 | struct kbl_codec_private *ctx = snd_soc_card_get_drvdata(rtd->card); |
171 | struct snd_soc_component *component = rtd->codec_dai->component; | 163 | struct snd_soc_component *component = rtd->codec_dai->component; |
164 | struct snd_soc_dai *codec_dai = rtd->codec_dai; | ||
172 | struct snd_soc_jack *jack; | 165 | struct snd_soc_jack *jack; |
173 | int ret; | 166 | int ret; |
174 | 167 | ||
168 | /* Configure sysclk for codec */ | ||
169 | ret = snd_soc_dai_set_sysclk(codec_dai, DA7219_CLKSRC_MCLK, 24576000, | ||
170 | SND_SOC_CLOCK_IN); | ||
171 | if (ret) { | ||
172 | dev_err(rtd->dev, "can't set codec sysclk configuration\n"); | ||
173 | return ret; | ||
174 | } | ||
175 | |||
175 | /* | 176 | /* |
176 | * Headset buttons map to the google Reference headset. | 177 | * Headset buttons map to the google Reference headset. |
177 | * These can be configured by userspace. | 178 | * These can be configured by userspace. |