Lines Matching +full:designware +full:- +full:i2s
1 // SPDX-License-Identifier: MIT
5 //Copyright 2017-2021 Advanced Micro Devices, Inc.
11 #include <sound/soc-dapm.h>
56 struct snd_soc_card *card = rtd->card; in cz_da7219_init()
58 struct snd_soc_component *component = codec_dai->component; in cz_da7219_init()
60 dev_info(rtd->dev, "codec dai name = %s\n", codec_dai->name); in cz_da7219_init()
65 dev_err(rtd->dev, "can't set codec sysclk: %d\n", ret); in cz_da7219_init()
72 dev_err(rtd->dev, "can't set codec pll: %d\n", ret); in cz_da7219_init()
76 da7219_dai_wclk = devm_clk_get(component->dev, "da7219-dai-wclk"); in cz_da7219_init()
80 da7219_dai_bclk = devm_clk_get(component->dev, "da7219-dai-bclk"); in cz_da7219_init()
92 dev_err(card->dev, "HP jack creation failed %d\n", ret); in cz_da7219_init()
121 dev_err(rtd->dev, "can't enable master clock %d\n", ret); in da7219_clk_enable()
136 struct snd_soc_card *card = rtd->card; in cz_rt5682_init()
138 struct snd_soc_component *component = codec_dai->component; in cz_rt5682_init()
140 dev_info(codec_dai->dev, "codec dai name = %s\n", codec_dai->name); in cz_rt5682_init()
146 dev_err(codec_dai->dev, in cz_rt5682_init()
154 dev_err(codec_dai->dev, "can't set rt5682 PLL: %d\n", ret); in cz_rt5682_init()
158 rt5682_dai_wclk = devm_clk_get(component->dev, "rt5682-dai-wclk"); in cz_rt5682_init()
162 rt5682_dai_bclk = devm_clk_get(component->dev, "rt5682-dai-bclk"); in cz_rt5682_init()
174 dev_err(card->dev, "HP jack creation failed %d\n", ret); in cz_rt5682_init()
185 dev_err(rtd->dev, "Headset Jack call-back failed: %d\n", ret); in cz_rt5682_init()
204 dev_err(rtd->dev, "Error setting wclk rate: %d\n", ret); in rt5682_clk_enable()
209 dev_err(rtd->dev, "Error setting bclk rate: %d\n", ret); in rt5682_clk_enable()
214 dev_err(rtd->dev, "can't enable wclk %d\n", ret); in rt5682_clk_enable()
247 struct snd_pcm_runtime *runtime = substream->runtime; in cz_da7219_play_startup()
249 struct snd_soc_card *card = rtd->card; in cz_da7219_play_startup()
256 runtime->hw.channels_max = DUAL_CHANNEL; in cz_da7219_play_startup()
262 machine->play_i2s_instance = I2S_SP_INSTANCE; in cz_da7219_play_startup()
268 struct snd_pcm_runtime *runtime = substream->runtime; in cz_da7219_cap_startup()
270 struct snd_soc_card *card = rtd->card; in cz_da7219_cap_startup()
277 runtime->hw.channels_max = DUAL_CHANNEL; in cz_da7219_cap_startup()
283 machine->cap_i2s_instance = I2S_SP_INSTANCE; in cz_da7219_cap_startup()
284 machine->capture_channel = CAP_CHANNEL1; in cz_da7219_cap_startup()
290 struct snd_pcm_runtime *runtime = substream->runtime; in cz_max_startup()
292 struct snd_soc_card *card = rtd->card; in cz_max_startup()
299 runtime->hw.channels_max = DUAL_CHANNEL; in cz_max_startup()
305 machine->play_i2s_instance = I2S_BT_INSTANCE; in cz_max_startup()
311 struct snd_pcm_runtime *runtime = substream->runtime; in cz_dmic0_startup()
313 struct snd_soc_card *card = rtd->card; in cz_dmic0_startup()
320 runtime->hw.channels_max = DUAL_CHANNEL; in cz_dmic0_startup()
326 machine->cap_i2s_instance = I2S_BT_INSTANCE; in cz_dmic0_startup()
332 struct snd_pcm_runtime *runtime = substream->runtime; in cz_dmic1_startup()
334 struct snd_soc_card *card = rtd->card; in cz_dmic1_startup()
341 runtime->hw.channels_max = DUAL_CHANNEL; in cz_dmic1_startup()
347 machine->cap_i2s_instance = I2S_SP_INSTANCE; in cz_dmic1_startup()
348 machine->capture_channel = CAP_CHANNEL0; in cz_dmic1_startup()
359 struct snd_pcm_runtime *runtime = substream->runtime; in cz_rt5682_play_startup()
361 struct snd_soc_card *card = rtd->card; in cz_rt5682_play_startup()
368 runtime->hw.channels_max = DUAL_CHANNEL; in cz_rt5682_play_startup()
374 machine->play_i2s_instance = I2S_SP_INSTANCE; in cz_rt5682_play_startup()
380 struct snd_pcm_runtime *runtime = substream->runtime; in cz_rt5682_cap_startup()
382 struct snd_soc_card *card = rtd->card; in cz_rt5682_cap_startup()
389 runtime->hw.channels_max = DUAL_CHANNEL; in cz_rt5682_cap_startup()
395 machine->cap_i2s_instance = I2S_SP_INSTANCE; in cz_rt5682_cap_startup()
396 machine->capture_channel = CAP_CHANNEL1; in cz_rt5682_cap_startup()
402 struct snd_pcm_runtime *runtime = substream->runtime; in cz_rt5682_max_startup()
404 struct snd_soc_card *card = rtd->card; in cz_rt5682_max_startup()
411 runtime->hw.channels_max = DUAL_CHANNEL; in cz_rt5682_max_startup()
417 machine->play_i2s_instance = I2S_BT_INSTANCE; in cz_rt5682_max_startup()
423 struct snd_pcm_runtime *runtime = substream->runtime; in cz_rt5682_dmic0_startup()
425 struct snd_soc_card *card = rtd->card; in cz_rt5682_dmic0_startup()
432 runtime->hw.channels_max = DUAL_CHANNEL; in cz_rt5682_dmic0_startup()
438 machine->cap_i2s_instance = I2S_BT_INSTANCE; in cz_rt5682_dmic0_startup()
444 struct snd_pcm_runtime *runtime = substream->runtime; in cz_rt5682_dmic1_startup()
446 struct snd_soc_card *card = rtd->card; in cz_rt5682_dmic1_startup()
453 runtime->hw.channels_max = DUAL_CHANNEL; in cz_rt5682_dmic1_startup()
459 machine->cap_i2s_instance = I2S_SP_INSTANCE; in cz_rt5682_dmic1_startup()
460 machine->capture_channel = CAP_CHANNEL0; in cz_rt5682_dmic1_startup()
520 DAILINK_COMP_ARRAY(COMP_CPU("designware-i2s.1.auto")));
522 DAILINK_COMP_ARRAY(COMP_CPU("designware-i2s.2.auto")));
524 DAILINK_COMP_ARRAY(COMP_CPU("designware-i2s.3.auto")));
527 DAILINK_COMP_ARRAY(COMP_CODEC("i2c-DLGS7219:00", "da7219-hifi")));
529 DAILINK_COMP_ARRAY(COMP_CODEC("i2c-10EC5682:00", "rt5682-aif1")));
533 DAILINK_COMP_ARRAY(COMP_CODEC("ADAU7002:00", "adau7002-hifi")));
540 .name = "amd-da7219-play",
551 .name = "amd-da7219-cap",
561 .name = "amd-max98357-play",
596 .name = "amd-rt5682-play",
607 .name = "amd-rt5682-cap",
617 .name = "amd-max98357-play",
711 match = acpi_match_device(dev->driver->acpi_match_table, dev); in acp_soc_is_rltk_max()
714 return (void *)match->driver_data; in acp_soc_is_rltk_max()
718 REGULATOR_SUPPLY("VDD", "i2c-DLGS7219:00"),
719 REGULATOR_SUPPLY("VDDMIC", "i2c-DLGS7219:00"),
720 REGULATOR_SUPPLY("VDDIO", "i2c-DLGS7219:00"),
740 .name = "reg-fixed-1.8V",
754 struct device *dev = &pdev->dev; in cz_probe()
758 return -ENODEV; in cz_probe()
759 if (!strcmp(card->name, "acpd7219m98357")) { in cz_probe()
760 acp_da7219_cfg.dev = &pdev->dev; in cz_probe()
761 rdev = devm_regulator_register(&pdev->dev, &acp_da7219_desc, in cz_probe()
764 dev_err(&pdev->dev, "Failed to register regulator: %d\n", in cz_probe()
766 return -EINVAL; in cz_probe()
770 machine = devm_kzalloc(&pdev->dev, sizeof(struct acp_platform_info), in cz_probe()
773 return -ENOMEM; in cz_probe()
774 card->dev = &pdev->dev; in cz_probe()
777 ret = devm_snd_soc_register_card(&pdev->dev, card); in cz_probe()
779 return dev_err_probe(&pdev->dev, ret, in cz_probe()
781 card->name); in cz_probe()
783 acp_bt_uart_enable = !device_property_read_bool(&pdev->dev, in cz_probe()
784 "bt-pad-enable"); in cz_probe()
799 .name = "cz-da7219-max98357a",