Lines Matching +full:aif1 +full:- +full:pins

1 // SPDX-License-Identifier: GPL-2.0-only
3 * Intel Broxton-P I2S Machine Driver
5 * Copyright (C) 2014-2016, Intel Corporation. All rights reserved.
16 #include <sound/soc-acpi.h>
23 /* Headset jack detection DAPM pins */
81 /* HP jack connectors - unknown if we have jack detect */
91 {"HDMI1", NULL, "hif5-0 Output"},
92 {"HDMI2", NULL, "hif6-0 Output"},
93 {"HDMI2", NULL, "hif7-0 Output"},
96 { "AIF1 Playback", NULL, "ssp5 Tx"},
101 { "ssp5 Rx", NULL, "AIF1 Capture" },
119 /* HP jack connectors - unknown if we have jack detect */
129 {"HDMI1", NULL, "hif5-0 Output"},
130 {"HDMI2", NULL, "hif6-0 Output"},
131 {"HDMI2", NULL, "hif7-0 Output"},
134 { "AIF1 Playback", NULL, "ssp2 Tx"},
139 { "ssp2 Rx", NULL, "AIF1 Capture" },
158 struct snd_soc_component *component = asoc_rtd_to_cpu(rtd, 0)->component; in broxton_rt298_fe_init()
168 struct snd_soc_component *component = asoc_rtd_to_codec(rtd, 0)->component; in broxton_rt298_codec_init()
171 ret = snd_soc_card_jack_new_pins(rtd->card, "Headset", in broxton_rt298_codec_init()
181 snd_soc_dapm_ignore_suspend(&rtd->card->dapm, "SoC DMIC"); in broxton_rt298_codec_init()
188 struct bxt_rt286_private *ctx = snd_soc_card_get_drvdata(rtd->card); in broxton_hdmi_init()
192 pcm = devm_kzalloc(rtd->card->dev, sizeof(*pcm), GFP_KERNEL); in broxton_hdmi_init()
194 return -ENOMEM; in broxton_hdmi_init()
196 pcm->device = BXT_DPCM_AUDIO_HDMI1_PB + dai->id; in broxton_hdmi_init()
197 pcm->codec_dai = dai; in broxton_hdmi_init()
199 list_add_tail(&pcm->head, &ctx->hdmi_pcm_list); in broxton_hdmi_init()
214 rate->min = rate->max = 48000; in broxton_ssp5_fixup()
215 chan->min = chan->max = 2; in broxton_ssp5_fixup()
234 dev_err(rtd->dev, "can't set codec sysclk configuration\n"); in broxton_rt298_hw_params()
260 chan->min = chan->max = 4; in broxton_dmic_fixup()
277 struct snd_pcm_runtime *runtime = substream->runtime; in broxton_dmic_startup()
279 runtime->hw.channels_max = 4; in broxton_dmic_startup()
283 return snd_pcm_hw_constraint_list(substream->runtime, 0, in broxton_dmic_startup()
303 struct snd_pcm_runtime *runtime = substream->runtime; in bxt_fe_startup()
309 * 16-bit audio in bxt_fe_startup()
312 runtime->hw.channels_max = 2; in bxt_fe_startup()
316 runtime->hw.formats = SNDRV_PCM_FMTBIT_S16_LE; in bxt_fe_startup()
352 DAILINK_COMP_ARRAY(COMP_CODEC("i2c-INT343A:00",
353 "rt298-aif1")));
359 DAILINK_COMP_ARRAY(COMP_CODEC("dmic-codec",
360 "dmic-hifi")));
369 "intel-hdmi-hifi1")));
375 "intel-hdmi-hifi2")));
381 "intel-hdmi-hifi3")));
386 /* broxton digital audio interface glue - connects codec <--> CPU */
465 /* SSP5 - Codec */
466 .name = "SSP5-Codec",
532 if (list_empty(&ctx->hdmi_pcm_list)) in bxt_card_late_probe()
533 return -EINVAL; in bxt_card_late_probe()
535 if (ctx->common_hdmi_codec_drv) { in bxt_card_late_probe()
536 pcm = list_first_entry(&ctx->hdmi_pcm_list, struct bxt_hdmi_pcm, in bxt_card_late_probe()
538 component = pcm->codec_dai->component; in bxt_card_late_probe()
542 list_for_each_entry(pcm, &ctx->hdmi_pcm_list, head) { in bxt_card_late_probe()
543 component = pcm->codec_dai->component; in bxt_card_late_probe()
545 "HDMI/DP, pcm=%d Jack", pcm->device); in bxt_card_late_probe()
552 err = hdac_hdmi_jack_init(pcm->codec_dai, pcm->device, in bxt_card_late_probe()
560 return hdac_hdmi_jack_port_init(component, &card->dapm); in bxt_card_late_probe()
566 .name = "broxton-rt298",
582 .name = "geminilake-rt298",
600 (struct snd_soc_card *)pdev->id_entry->driver_data; in broxton_audio_probe()
607 if (!strncmp(card->dai_link[i].codecs->name, "i2c-INT343A:00", in broxton_audio_probe()
609 if (!strncmp(card->name, "broxton-rt298", in broxton_audio_probe()
611 card->dai_link[i].name = "SSP5-Codec"; in broxton_audio_probe()
612 card->dai_link[i].cpus->dai_name = "SSP5 Pin"; in broxton_audio_probe()
613 } else if (!strncmp(card->name, "geminilake-rt298", in broxton_audio_probe()
615 card->dai_link[i].name = "SSP2-Codec"; in broxton_audio_probe()
616 card->dai_link[i].cpus->dai_name = "SSP2 Pin"; in broxton_audio_probe()
621 ctx = devm_kzalloc(&pdev->dev, sizeof(*ctx), GFP_KERNEL); in broxton_audio_probe()
623 return -ENOMEM; in broxton_audio_probe()
625 INIT_LIST_HEAD(&ctx->hdmi_pcm_list); in broxton_audio_probe()
627 card->dev = &pdev->dev; in broxton_audio_probe()
631 mach = pdev->dev.platform_data; in broxton_audio_probe()
632 platform_name = mach->mach_params.platform; in broxton_audio_probe()
639 ctx->common_hdmi_codec_drv = mach->mach_params.common_hdmi_codec_drv; in broxton_audio_probe()
641 return devm_snd_soc_register_card(&pdev->dev, card); in broxton_audio_probe()