Lines Matching refs:sdev
82 struct snd_sof_dev *sdev = widget_to_sdev(w); in sdw_params_free() local
84 if (sdev->pdata->ipc_type == SOF_IPC_TYPE_4) { in sdw_params_free()
135 static int hda_sdw_acpi_scan(struct snd_sof_dev *sdev) in hda_sdw_acpi_scan() argument
137 u32 interface_mask = hda_get_interface_mask(sdev); in hda_sdw_acpi_scan()
145 handle = ACPI_HANDLE(sdev->dev); in hda_sdw_acpi_scan()
148 hdev = sdev->pdata->hw_pdata; in hda_sdw_acpi_scan()
157 static int hda_sdw_probe(struct snd_sof_dev *sdev) in hda_sdw_probe() argument
164 hdev = sdev->pdata->hw_pdata; in hda_sdw_probe()
168 chip = get_chip_info(sdev->pdata); in hda_sdw_probe()
170 res.mmio_base = sdev->bar[HDA_DSP_BAR]; in hda_sdw_probe()
181 res.eml_lock = hdac_bus_eml_get_mutex(sof_to_bus(sdev), true, in hda_sdw_probe()
186 res.mmio_base = sdev->bar[HDA_DSP_HDA_BAR]; in hda_sdw_probe()
196 res.irq = sdev->ipc_irq; in hda_sdw_probe()
198 res.parent = sdev->dev; in hda_sdw_probe()
200 res.dev = sdev->dev; in hda_sdw_probe()
202 res.hbus = sof_to_bus(sdev); in hda_sdw_probe()
216 dev_err(sdev->dev, "error: SoundWire probe failed\n"); in hda_sdw_probe()
226 int hda_sdw_startup(struct snd_sof_dev *sdev) in hda_sdw_startup() argument
229 struct snd_sof_pdata *pdata = sdev->pdata; in hda_sdw_startup()
232 hdev = sdev->pdata->hw_pdata; in hda_sdw_startup()
240 ret = hda_sdw_check_lcount(sdev); in hda_sdw_startup()
248 static int hda_sdw_exit(struct snd_sof_dev *sdev) in hda_sdw_exit() argument
252 hdev = sdev->pdata->hw_pdata; in hda_sdw_exit()
258 hda_sdw_int_enable(sdev, false); in hda_sdw_exit()
263 bool hda_common_check_sdw_irq(struct snd_sof_dev *sdev) in hda_common_check_sdw_irq() argument
269 hdev = sdev->pdata->hw_pdata; in hda_common_check_sdw_irq()
275 irq_status = snd_sof_dsp_read(sdev, HDA_DSP_BAR, HDA_DSP_REG_ADSPIS2); in hda_common_check_sdw_irq()
290 static bool hda_dsp_check_sdw_irq(struct snd_sof_dev *sdev) in hda_dsp_check_sdw_irq() argument
292 u32 interface_mask = hda_get_interface_mask(sdev); in hda_dsp_check_sdw_irq()
298 chip = get_chip_info(sdev->pdata); in hda_dsp_check_sdw_irq()
300 return chip->check_sdw_irq(sdev); in hda_dsp_check_sdw_irq()
310 bool hda_sdw_check_wakeen_irq_common(struct snd_sof_dev *sdev) in hda_sdw_check_wakeen_irq_common() argument
314 hdev = sdev->pdata->hw_pdata; in hda_sdw_check_wakeen_irq_common()
316 snd_sof_dsp_read(sdev, HDA_DSP_BAR, in hda_sdw_check_wakeen_irq_common()
324 static bool hda_sdw_check_wakeen_irq(struct snd_sof_dev *sdev) in hda_sdw_check_wakeen_irq() argument
326 u32 interface_mask = hda_get_interface_mask(sdev); in hda_sdw_check_wakeen_irq()
332 chip = get_chip_info(sdev->pdata); in hda_sdw_check_wakeen_irq()
334 return chip->check_sdw_wakeen_irq(sdev); in hda_sdw_check_wakeen_irq()
339 void hda_sdw_process_wakeen_common(struct snd_sof_dev *sdev) in hda_sdw_process_wakeen_common() argument
341 u32 interface_mask = hda_get_interface_mask(sdev); in hda_sdw_process_wakeen_common()
347 hdev = sdev->pdata->hw_pdata; in hda_sdw_process_wakeen_common()
355 static bool hda_dsp_sdw_check_mic_privacy_irq(struct snd_sof_dev *sdev) in hda_dsp_sdw_check_mic_privacy_irq() argument
359 chip = get_chip_info(sdev->pdata); in hda_dsp_sdw_check_mic_privacy_irq()
361 return chip->check_mic_privacy_irq(sdev, true, in hda_dsp_sdw_check_mic_privacy_irq()
367 static void hda_dsp_sdw_process_mic_privacy(struct snd_sof_dev *sdev) in hda_dsp_sdw_process_mic_privacy() argument
371 chip = get_chip_info(sdev->pdata); in hda_dsp_sdw_process_mic_privacy()
373 chip->process_mic_privacy(sdev, true, AZX_REG_ML_LEPTR_ID_SDW); in hda_dsp_sdw_process_mic_privacy()
377 static inline int hda_sdw_acpi_scan(struct snd_sof_dev *sdev) in hda_sdw_acpi_scan() argument
382 static inline int hda_sdw_probe(struct snd_sof_dev *sdev) in hda_sdw_probe() argument
387 static inline int hda_sdw_exit(struct snd_sof_dev *sdev) in hda_sdw_exit() argument
392 static inline bool hda_dsp_check_sdw_irq(struct snd_sof_dev *sdev) in hda_dsp_check_sdw_irq() argument
402 static inline bool hda_sdw_check_wakeen_irq(struct snd_sof_dev *sdev) in hda_sdw_check_wakeen_irq() argument
407 static inline bool hda_dsp_sdw_check_mic_privacy_irq(struct snd_sof_dev *sdev) in hda_dsp_sdw_check_mic_privacy_irq() argument
412 static inline void hda_dsp_sdw_process_mic_privacy(struct snd_sof_dev *sdev) { } in hda_dsp_sdw_process_mic_privacy() argument
417 int hda_dsp_pre_fw_run(struct snd_sof_dev *sdev) in hda_dsp_pre_fw_run() argument
420 return hda_dsp_ctrl_clock_power_gating(sdev, false); in hda_dsp_pre_fw_run()
424 int hda_dsp_post_fw_run(struct snd_sof_dev *sdev) in hda_dsp_post_fw_run() argument
428 if (sdev->first_boot) { in hda_dsp_post_fw_run()
429 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in hda_dsp_post_fw_run()
431 ret = hda_sdw_startup(sdev); in hda_dsp_post_fw_run()
433 dev_err(sdev->dev, in hda_dsp_post_fw_run()
440 (sdev->fw_ready.flags & SOF_IPC_INFO_D3_PERSISTENT || in hda_dsp_post_fw_run()
441 sdev->pdata->ipc_type == SOF_IPC_TYPE_4)) { in hda_dsp_post_fw_run()
444 0644, sdev->debugfs_root, in hda_dsp_post_fw_run()
449 hda_sdw_int_enable(sdev, true); in hda_dsp_post_fw_run()
452 return hda_dsp_ctrl_clock_power_gating(sdev, true); in hda_dsp_post_fw_run()
484 static int hda_init(struct snd_sof_dev *sdev) in hda_init() argument
488 struct pci_dev *pci = to_pci_dev(sdev->dev); in hda_init()
491 hbus = sof_to_hbus(sdev); in hda_init()
492 bus = sof_to_bus(sdev); in hda_init()
495 sof_hda_bus_init(sdev, &pci->dev); in hda_init()
518 sdev->bar[HDA_DSP_HDA_BAR] = bus->remap_addr; in hda_init()
521 ret = hda_codec_i915_init(sdev); in hda_init()
523 dev_err_probe(sdev->dev, ret, "init of i915 and HDMI codec failed\n"); in hda_init()
528 ret = hda_dsp_ctrl_get_caps(sdev); in hda_init()
530 dev_err(sdev->dev, "error: get caps error\n"); in hda_init()
531 hda_codec_i915_exit(sdev); in hda_init()
536 iounmap(sof_to_bus(sdev)->remap_addr); in hda_init()
541 static int check_dmic_num(struct snd_sof_dev *sdev) in check_dmic_num() argument
543 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in check_dmic_num()
549 dmic_num = intel_nhlt_get_dmic_geo(sdev->dev, nhlt); in check_dmic_num()
551 dev_info(sdev->dev, "DMICs detected in NHLT tables: %d\n", dmic_num); in check_dmic_num()
555 dev_dbg(sdev->dev, in check_dmic_num()
562 dev_dbg(sdev->dev, "invalid dmic_number %d\n", dmic_num); in check_dmic_num()
569 static int check_nhlt_ssp_mask(struct snd_sof_dev *sdev, u8 device_type) in check_nhlt_ssp_mask() argument
571 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in check_nhlt_ssp_mask()
582 dev_info(sdev->dev, "NHLT device %s(%d) detected, ssp_mask %#x\n", in check_nhlt_ssp_mask()
590 static int check_nhlt_ssp_mclk_mask(struct snd_sof_dev *sdev, int ssp_num) in check_nhlt_ssp_mclk_mask() argument
592 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in check_nhlt_ssp_mclk_mask()
602 static int hda_init_caps(struct snd_sof_dev *sdev) in hda_init_caps() argument
604 u32 interface_mask = hda_get_interface_mask(sdev); in hda_init_caps()
605 struct hdac_bus *bus = sof_to_bus(sdev); in hda_init_caps()
606 struct snd_sof_pdata *pdata = sdev->pdata; in hda_init_caps()
613 dev_dbg(sdev->dev, "PP capability, will probe DSP later.\n"); in hda_init_caps()
616 ret = hda_dsp_ctrl_init_chip(sdev); in hda_init_caps()
630 ret = hda_sdw_acpi_scan(sdev); in hda_init_caps()
632 dev_dbg(sdev->dev, "skipping SoundWire, not detected with ACPI scan\n"); in hda_init_caps()
638 dev_dbg(sdev->dev, "skipping SoundWire, no links enabled\n"); in hda_init_caps()
649 ret = hda_sdw_probe(sdev); in hda_init_caps()
651 dev_err(sdev->dev, "error: SoundWire probe error\n"); in hda_init_caps()
658 hda_codec_probe_bus(sdev); in hda_init_caps()
661 hda_codec_i915_display_power(sdev, false); in hda_init_caps()
670 struct snd_sof_dev *sdev = context; in hda_dsp_interrupt_handler() local
676 if (snd_sof_dsp_read(sdev, HDA_DSP_HDA_BAR, SOF_HDA_INTSTS) & in hda_dsp_interrupt_handler()
680 snd_sof_dsp_update_bits(sdev, HDA_DSP_HDA_BAR, in hda_dsp_interrupt_handler()
693 struct snd_sof_dev *sdev = context; in hda_dsp_interrupt_thread() local
694 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in hda_dsp_interrupt_thread()
697 if (hda_dsp_check_stream_irq(sdev)) { in hda_dsp_interrupt_thread()
698 trace_sof_intel_hda_irq(sdev, "stream"); in hda_dsp_interrupt_thread()
699 hda_dsp_stream_threaded_handler(irq, sdev); in hda_dsp_interrupt_thread()
702 if (hda_check_ipc_irq(sdev)) { in hda_dsp_interrupt_thread()
703 trace_sof_intel_hda_irq(sdev, "ipc"); in hda_dsp_interrupt_thread()
704 sof_ops(sdev)->irq_thread(irq, sdev); in hda_dsp_interrupt_thread()
707 if (hda_dsp_check_sdw_irq(sdev)) { in hda_dsp_interrupt_thread()
708 trace_sof_intel_hda_irq(sdev, "sdw"); in hda_dsp_interrupt_thread()
712 if (hda_dsp_sdw_check_mic_privacy_irq(sdev)) { in hda_dsp_interrupt_thread()
713 trace_sof_intel_hda_irq(sdev, "mic privacy"); in hda_dsp_interrupt_thread()
714 hda_dsp_sdw_process_mic_privacy(sdev); in hda_dsp_interrupt_thread()
718 if (hda_sdw_check_wakeen_irq(sdev)) { in hda_dsp_interrupt_thread()
719 trace_sof_intel_hda_irq(sdev, "wakeen"); in hda_dsp_interrupt_thread()
720 hda_sdw_process_wakeen(sdev); in hda_dsp_interrupt_thread()
723 hda_codec_check_for_state_change(sdev); in hda_dsp_interrupt_thread()
726 snd_sof_dsp_update_bits(sdev, HDA_DSP_HDA_BAR, in hda_dsp_interrupt_thread()
734 int hda_dsp_probe_early(struct snd_sof_dev *sdev) in hda_dsp_probe_early() argument
736 struct pci_dev *pci = to_pci_dev(sdev->dev); in hda_dsp_probe_early()
741 if (!sdev->dspless_mode_selected) { in hda_dsp_probe_early()
750 dev_err(sdev->dev, "the DSP is not enabled on this platform, aborting probe\n"); in hda_dsp_probe_early()
753 dev_err(sdev->dev, "unknown PCI class/subclass/prog-if 0x%06x found, aborting probe\n", in hda_dsp_probe_early()
757 dev_info_once(sdev->dev, "DSP detected with PCI class/subclass/prog-if 0x%06x\n", in hda_dsp_probe_early()
761 chip = get_chip_info(sdev->pdata); in hda_dsp_probe_early()
763 dev_err(sdev->dev, "error: no such device supported, chip id:%x\n", in hda_dsp_probe_early()
769 sdev->num_cores = chip->cores_num; in hda_dsp_probe_early()
771 hdev = devm_kzalloc(sdev->dev, sizeof(*hdev), GFP_KERNEL); in hda_dsp_probe_early()
774 sdev->pdata->hw_pdata = hdev; in hda_dsp_probe_early()
776 ret = hda_init(sdev); in hda_dsp_probe_early()
783 int hda_dsp_probe(struct snd_sof_dev *sdev) in hda_dsp_probe() argument
785 struct pci_dev *pci = to_pci_dev(sdev->dev); in hda_dsp_probe()
786 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in hda_dsp_probe()
790 hdev->dmic_dev = platform_device_register_data(sdev->dev, "dmic-codec", in hda_dsp_probe()
794 dev_err(sdev->dev, "error: failed to create DMIC device\n"); in hda_dsp_probe()
805 hdev->no_ipc_position = sof_ops(sdev)->pcm_pointer ? 1 : 0; in hda_dsp_probe()
808 if (sdev->dspless_mode_selected) in hda_dsp_probe()
811 if (sdev->dspless_mode_selected) in hda_dsp_probe()
815 sdev->bar[HDA_DSP_BAR] = pci_ioremap_bar(pci, HDA_DSP_BAR); in hda_dsp_probe()
816 if (!sdev->bar[HDA_DSP_BAR]) { in hda_dsp_probe()
817 dev_err(sdev->dev, "error: ioremap error\n"); in hda_dsp_probe()
822 sdev->mmio_bar = HDA_DSP_BAR; in hda_dsp_probe()
823 sdev->mailbox_bar = HDA_DSP_BAR; in hda_dsp_probe()
828 dev_dbg(sdev->dev, "DMA mask is 32 bit\n"); in hda_dsp_probe()
834 ret = hda_dsp_stream_init(sdev); in hda_dsp_probe()
836 dev_err(sdev->dev, "error: failed to init streams\n"); in hda_dsp_probe()
851 dev_info(sdev->dev, "use msi interrupt mode\n"); in hda_dsp_probe()
852 sdev->ipc_irq = pci_irq_vector(pci, 0); in hda_dsp_probe()
854 sdev->msi_enabled = true; in hda_dsp_probe()
857 if (!sdev->msi_enabled) { in hda_dsp_probe()
858 dev_info(sdev->dev, "use legacy interrupt mode\n"); in hda_dsp_probe()
863 sdev->ipc_irq = pci->irq; in hda_dsp_probe()
866 dev_dbg(sdev->dev, "using IPC IRQ %d\n", sdev->ipc_irq); in hda_dsp_probe()
867 ret = request_threaded_irq(sdev->ipc_irq, hda_dsp_interrupt_handler, in hda_dsp_probe()
869 IRQF_SHARED, "AudioDSP", sdev); in hda_dsp_probe()
871 dev_err(sdev->dev, "error: failed to register IPC IRQ %d\n", in hda_dsp_probe()
872 sdev->ipc_irq); in hda_dsp_probe()
883 snd_sof_pci_update_bits(sdev, PCI_TCSEL, 0x07, 0); in hda_dsp_probe()
886 ret = hda_init_caps(sdev); in hda_dsp_probe()
890 if (!sdev->dspless_mode_selected) { in hda_dsp_probe()
892 hda_dsp_ctrl_ppcap_enable(sdev, true); in hda_dsp_probe()
893 hda_dsp_ctrl_ppcap_int_enable(sdev, true); in hda_dsp_probe()
896 sdev->dsp_box.offset = HDA_DSP_MBOX_UPLINK_OFFSET; in hda_dsp_probe()
901 chip = get_chip_info(sdev->pdata); in hda_dsp_probe()
903 ret = hda_sdw_startup(sdev); in hda_dsp_probe()
905 dev_err(sdev->dev, "could not startup SoundWire links\n"); in hda_dsp_probe()
912 hdev->nhlt = intel_nhlt_init(sdev->dev); in hda_dsp_probe()
917 if (!sdev->dspless_mode_selected) { in hda_dsp_probe()
918 hda_dsp_ctrl_ppcap_int_enable(sdev, false); in hda_dsp_probe()
919 hda_dsp_ctrl_ppcap_enable(sdev, false); in hda_dsp_probe()
922 free_irq(sdev->ipc_irq, sdev); in hda_dsp_probe()
924 if (sdev->msi_enabled) in hda_dsp_probe()
927 hda_dsp_stream_free(sdev); in hda_dsp_probe()
929 if (!sdev->dspless_mode_selected) in hda_dsp_probe()
930 iounmap(sdev->bar[HDA_DSP_BAR]); in hda_dsp_probe()
938 void hda_dsp_remove(struct snd_sof_dev *sdev) in hda_dsp_remove() argument
940 struct sof_intel_hda_dev *hda = sdev->pdata->hw_pdata; in hda_dsp_remove()
942 struct pci_dev *pci = to_pci_dev(sdev->dev); in hda_dsp_remove()
948 if (!sdev->dspless_mode_selected) in hda_dsp_remove()
952 hda_codec_device_remove(sdev); in hda_dsp_remove()
954 hda_sdw_exit(sdev); in hda_dsp_remove()
959 if (!sdev->dspless_mode_selected) { in hda_dsp_remove()
961 hda_dsp_ctrl_ppcap_int_enable(sdev, false); in hda_dsp_remove()
965 snd_sof_dsp_update_bits(sdev, HDA_DSP_HDA_BAR, SOF_HDA_INTCTL, in hda_dsp_remove()
968 if (sdev->dspless_mode_selected) in hda_dsp_remove()
977 chip->power_down_dsp(sdev); in hda_dsp_remove()
980 hda_dsp_ctrl_ppcap_enable(sdev, false); in hda_dsp_remove()
989 free_irq(sdev->ipc_irq, sdev); in hda_dsp_remove()
990 if (sdev->msi_enabled) in hda_dsp_remove()
993 hda_dsp_stream_free(sdev); in hda_dsp_remove()
995 hda_bus_ml_free(sof_to_bus(sdev)); in hda_dsp_remove()
997 if (!sdev->dspless_mode_selected) in hda_dsp_remove()
998 iounmap(sdev->bar[HDA_DSP_BAR]); in hda_dsp_remove()
1002 void hda_dsp_remove_late(struct snd_sof_dev *sdev) in hda_dsp_remove_late() argument
1004 iounmap(sof_to_bus(sdev)->remap_addr); in hda_dsp_remove_late()
1005 sof_hda_bus_exit(sdev); in hda_dsp_remove_late()
1006 hda_codec_i915_exit(sdev); in hda_dsp_remove_late()
1009 int hda_power_down_dsp(struct snd_sof_dev *sdev) in hda_power_down_dsp() argument
1011 struct sof_intel_hda_dev *hda = sdev->pdata->hw_pdata; in hda_power_down_dsp()
1014 return hda_dsp_core_reset_power_down(sdev, chip->host_managed_cores_mask); in hda_power_down_dsp()
1019 static void hda_generic_machine_select(struct snd_sof_dev *sdev, in hda_generic_machine_select() argument
1022 struct hdac_bus *bus = sof_to_bus(sdev); in hda_generic_machine_select()
1025 struct snd_sof_pdata *pdata = sdev->pdata; in hda_generic_machine_select()
1056 hda_mach = devm_kmemdup_array(sdev->dev, in hda_generic_machine_select()
1080 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_generic_machine_select()
1102 struct sof_intel_hda_dev *hdev = sdev->pdata->hw_pdata; in hda_generic_machine_select()
1118 static void hda_generic_machine_select(struct snd_sof_dev *sdev, in hda_generic_machine_select() argument
1126 static struct snd_soc_acpi_mach *hda_sdw_machine_select(struct snd_sof_dev *sdev) in hda_sdw_machine_select() argument
1128 struct snd_sof_pdata *pdata = sdev->pdata; in hda_sdw_machine_select()
1140 dev_info(sdev->dev, "SoundWire links not enabled\n"); in hda_sdw_machine_select()
1145 dev_dbg(sdev->dev, "SoundWire context not allocated\n"); in hda_sdw_machine_select()
1150 dev_warn(sdev->dev, "No SoundWire peripheral detected in ACPI tables\n"); in hda_sdw_machine_select()
1184 if (!snd_soc_acpi_sdw_link_slaves_found(sdev->dev, link, in hda_sdw_machine_select()
1196 mach->mach_params.platform = dev_name(sdev->dev); in hda_sdw_machine_select()
1201 dev_info(sdev->dev, "No SoundWire machine driver found for the ACPI-reported configuration:\n"); in hda_sdw_machine_select()
1204 dev_info(sdev->dev, "link %d mfg_id 0x%04x part_id 0x%04x version %#x\n", in hda_sdw_machine_select()
1213 static struct snd_soc_acpi_mach *hda_sdw_machine_select(struct snd_sof_dev *sdev) in hda_sdw_machine_select() argument
1220 struct snd_sof_dev *sdev) in hda_set_mach_params() argument
1222 struct snd_sof_pdata *pdata = sdev->pdata; in hda_set_mach_params()
1227 mach_params->platform = dev_name(sdev->dev); in hda_set_mach_params()
1270 struct snd_soc_acpi_mach *hda_machine_select(struct snd_sof_dev *sdev) in hda_machine_select() argument
1272 u32 interface_mask = hda_get_interface_mask(sdev); in hda_machine_select()
1273 struct snd_sof_pdata *sof_pdata = sdev->pdata; in hda_machine_select()
1275 struct hdac_bus *bus = sof_to_bus(sdev); in hda_machine_select()
1297 mach = hda_sdw_machine_select(sdev); in hda_machine_select()
1306 hda_generic_machine_select(sdev, &mach); in hda_machine_select()
1308 dev_warn(sdev->dev, "warning: No matching ASoC machine driver found\n"); in hda_machine_select()
1313 mach->mach_params.bt_link_mask = check_nhlt_ssp_mask(sdev, NHLT_DEVICE_BT); in hda_machine_select()
1315 dev_info(sdev->dev, "BT link detected in NHLT tables: %#x\n", in hda_machine_select()
1320 dev_dbg(sdev->dev, "overriding BT link detected in NHLT tables %#x by kernel param %#x\n", in hda_machine_select()
1326 dev_warn(sdev->dev, "invalid BT link mask %#x found, reset the mask\n", in hda_machine_select()
1359 dev_err(sdev->dev, "Invalid tplg quirk mask 0x%x\n", in hda_machine_select()
1365 mach->mach_params.dmic_num = check_dmic_num(sdev); in hda_machine_select()
1373 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_machine_select()
1391 mach->mach_params.i2s_link_mask = check_nhlt_ssp_mask(sdev, NHLT_DEVICE_I2S); in hda_machine_select()
1396 const struct sof_intel_dsp_desc *chip = get_chip_info(sdev->pdata); in hda_machine_select()
1402 dev_warn(sdev->dev, "More than one SSP exposed by NHLT, choosing MSB\n"); in hda_machine_select()
1408 dev_err(sdev->dev, "Invalid SSP %d, max on this platform is %d\n", in hda_machine_select()
1413 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_machine_select()
1423 mclk_mask = check_nhlt_ssp_mclk_mask(sdev, ssp_num); in hda_machine_select()
1426 dev_err(sdev->dev, "Invalid MCLK configuration\n"); in hda_machine_select()
1430 dev_dbg(sdev->dev, "MCLK mask %#x found in NHLT\n", mclk_mask); in hda_machine_select()
1433 dev_info(sdev->dev, "Overriding topology with MCLK mask %#x from NHLT\n", mclk_mask); in hda_machine_select()
1434 sdev->mclk_id_override = true; in hda_machine_select()
1435 sdev->mclk_id_quirk = (mclk_mask & BIT(0)) ? 0 : 1; in hda_machine_select()
1439 amp_type = snd_soc_acpi_intel_detect_amp_type(sdev->dev); in hda_machine_select()
1440 codec_type = snd_soc_acpi_intel_detect_codec_type(sdev->dev); in hda_machine_select()
1447 dev_err(sdev->dev, "no tplg suffix found, amp %d\n", in hda_machine_select()
1452 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_machine_select()
1468 dev_err(sdev->dev, "no tplg suffix found, codec %d\n", in hda_machine_select()
1473 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_machine_select()
1484 tplg_filename = devm_kasprintf(sdev->dev, GFP_KERNEL, in hda_machine_select()
1496 … dev_info(sdev->dev, "Overriding topology with MCLK %d from kernel_parameter\n", mclk_id_override); in hda_machine_select()
1497 sdev->mclk_id_override = true; in hda_machine_select()
1498 sdev->mclk_id_quirk = mclk_id_override; in hda_machine_select()
1519 int hda_register_clients(struct snd_sof_dev *sdev) in hda_register_clients() argument
1521 return hda_probes_register(sdev); in hda_register_clients()
1524 void hda_unregister_clients(struct snd_sof_dev *sdev) in hda_unregister_clients() argument
1526 hda_probes_unregister(sdev); in hda_unregister_clients()