Lines Matching +full:da7219 +full:- +full:dai +full:- +full:wclk

1 // SPDX-License-Identifier: GPL-2.0+
3 // Machine driver for AMD ACP Audio engine using DA7219 & MAX98357 codec.
11 #include <sound/soc-dapm.h>
56 struct snd_soc_card *card = rtd->card; in acp3x_5682_init()
58 struct snd_soc_component *component = codec_dai->component; in acp3x_5682_init()
60 dev_info(rtd->dev, "codec dai name = %s\n", codec_dai->name); in acp3x_5682_init()
62 /* set rt5682 dai fmt */ in acp3x_5682_init()
67 dev_err(rtd->card->dev, in acp3x_5682_init()
68 "Failed to set rt5682 dai fmt: %d\n", ret); in acp3x_5682_init()
76 dev_err(rtd->dev, "can't set rt5682 PLL: %d\n", ret); in acp3x_5682_init()
84 dev_err(rtd->dev, in acp3x_5682_init()
92 dev_err(rtd->dev, in acp3x_5682_init()
97 rt5682_dai_wclk = clk_get(component->dev, "rt5682-dai-wclk"); in acp3x_5682_init()
98 rt5682_dai_bclk = clk_get(component->dev, "rt5682-dai-bclk"); in acp3x_5682_init()
108 dev_err(card->dev, "HP jack creation failed %d\n", ret); in acp3x_5682_init()
119 dev_err(rtd->dev, "Headset Jack call-back failed: %d\n", ret); in acp3x_5682_init()
136 dev_err(rtd->dev, "can't enable wclk %d\n", ret); in rt5682_clk_enable()
154 if (strcmp(codec_dai->name, "rt1015-aif")) in acp3x_1015_hw_params()
196 struct snd_pcm_runtime *runtime = substream->runtime; in acp3x_5682_startup()
198 struct snd_soc_card *card = rtd->card; in acp3x_5682_startup()
201 machine->play_i2s_instance = I2S_SP_INSTANCE; in acp3x_5682_startup()
202 machine->cap_i2s_instance = I2S_SP_INSTANCE; in acp3x_5682_startup()
204 runtime->hw.channels_max = DUAL_CHANNEL; in acp3x_5682_startup()
214 struct snd_pcm_runtime *runtime = substream->runtime; in acp3x_max_startup()
216 struct snd_soc_card *card = rtd->card; in acp3x_max_startup()
219 machine->play_i2s_instance = I2S_BT_INSTANCE; in acp3x_max_startup()
221 runtime->hw.channels_max = DUAL_CHANNEL; in acp3x_max_startup()
232 struct snd_soc_card *card = rtd->card; in acp3x_ec_dmic0_startup()
236 machine->cap_i2s_instance = I2S_BT_INSTANCE; in acp3x_ec_dmic0_startup()
247 ucontrol->value.integer.value[0] = dmic_switch; in dmic_get()
255 dmic_switch = ucontrol->value.integer.value[0]; in dmic_set()
288 DAILINK_COMP_ARRAY(COMP_CODEC("i2c-10EC5682:00", "rt5682-aif1")));
294 DAILINK_COMP_ARRAY(COMP_CODEC("i2c-10EC1015:00", "rt1015-aif"),
295 COMP_CODEC("i2c-10EC1015:01", "rt1015-aif")));
304 .dlc = COMP_CODEC_CONF("i2c-10EC1015:00"),
308 .dlc = COMP_CODEC_CONF("i2c-10EC1015:01"),
315 .name = "acp3x-5682-play",
326 .name = "acp3x-max98357-play",
338 .name = "acp3x-ec-dmic0-capture",
478 match = acpi_match_device(dev->driver->acpi_match_table, dev); in soc_is_rltk_max()
481 return (void *)match->driver_data; in soc_is_rltk_max()
504 struct device *dev = &pdev->dev; in acp3x_probe()
508 return -ENODEV; in acp3x_probe()
510 machine = devm_kzalloc(&pdev->dev, sizeof(*machine), GFP_KERNEL); in acp3x_probe()
512 return -ENOMEM; in acp3x_probe()
514 card_spk_dai_link_present(card->dai_link, card->name); in acp3x_probe()
515 card->dev = &pdev->dev; in acp3x_probe()
519 dmic_sel = devm_gpiod_get(&pdev->dev, "dmic", GPIOD_OUT_LOW); in acp3x_probe()
521 dev_err(&pdev->dev, "DMIC gpio failed err=%ld\n", in acp3x_probe()
526 ret = devm_snd_soc_register_card(&pdev->dev, card); in acp3x_probe()
528 return dev_err_probe(&pdev->dev, ret, in acp3x_probe()
530 card->name); in acp3x_probe()
545 .name = "acp3x-alc5682-max98357",