hda.h (7d88b9608142f95ccdd3dfb190da4a5faddb1cc7) | hda.h (3dc0d709177828a22dfc9d0072e3ac937ef90d06) |
---|---|
1/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */ 2/* 3 * This file is provided under a dual BSD/GPLv2 license. When using or 4 * redistributing this file, you may do so under either license. 5 * 6 * Copyright(c) 2017 Intel Corporation. All rights reserved. 7 * 8 * Author: Liam Girdwood <liam.r.girdwood@linux.intel.com> 9 */ 10 11#ifndef __SOF_INTEL_HDA_H 12#define __SOF_INTEL_HDA_H 13 14#include <linux/soundwire/sdw.h> 15#include <linux/soundwire/sdw_intel.h> 16#include <sound/compress_driver.h> 17#include <sound/hda_codec.h> 18#include <sound/hdaudio_ext.h> | 1/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */ 2/* 3 * This file is provided under a dual BSD/GPLv2 license. When using or 4 * redistributing this file, you may do so under either license. 5 * 6 * Copyright(c) 2017 Intel Corporation. All rights reserved. 7 * 8 * Author: Liam Girdwood <liam.r.girdwood@linux.intel.com> 9 */ 10 11#ifndef __SOF_INTEL_HDA_H 12#define __SOF_INTEL_HDA_H 13 14#include <linux/soundwire/sdw.h> 15#include <linux/soundwire/sdw_intel.h> 16#include <sound/compress_driver.h> 17#include <sound/hda_codec.h> 18#include <sound/hdaudio_ext.h> |
19#include "../sof-client-probes.h" |
|
19#include "shim.h" 20 21/* PCI registers */ 22#define PCI_TCSEL 0x44 23#define PCI_PGCTL PCI_TCSEL 24#define PCI_CGCTL 0x48 25 26/* PCI_PGCTL bits */ --- 319 unchanged lines hidden (view full) --- 346 347/* BDL */ 348#define HDA_DSP_BDL_SIZE 4096 349#define HDA_DSP_MAX_BDL_ENTRIES \ 350 (HDA_DSP_BDL_SIZE / sizeof(struct sof_intel_dsp_bdl)) 351 352/* Number of DAIs */ 353#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA) | 20#include "shim.h" 21 22/* PCI registers */ 23#define PCI_TCSEL 0x44 24#define PCI_PGCTL PCI_TCSEL 25#define PCI_CGCTL 0x48 26 27/* PCI_PGCTL bits */ --- 319 unchanged lines hidden (view full) --- 347 348/* BDL */ 349#define HDA_DSP_BDL_SIZE 4096 350#define HDA_DSP_MAX_BDL_ENTRIES \ 351 (HDA_DSP_BDL_SIZE / sizeof(struct sof_intel_dsp_bdl)) 352 353/* Number of DAIs */ 354#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA) |
354 355#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_PROBES) 356#define SOF_SKL_NUM_DAIS 16 357#else | |
358#define SOF_SKL_NUM_DAIS 15 | 355#define SOF_SKL_NUM_DAIS 15 |
359#endif 360 | |
361#else 362#define SOF_SKL_NUM_DAIS 8 363#endif 364 365/* Intel HD Audio SRAM Window 0*/ 366#define HDA_ADSP_SRAM0_BASE_SKL 0x8000 367 368/* Firmware status window */ --- 201 unchanged lines hidden (view full) --- 570 571int hda_ipc_msg_data(struct snd_sof_dev *sdev, 572 struct snd_pcm_substream *substream, 573 void *p, size_t sz); 574int hda_ipc_pcm_params(struct snd_sof_dev *sdev, 575 struct snd_pcm_substream *substream, 576 const struct sof_ipc_pcm_params_reply *reply); 577 | 356#else 357#define SOF_SKL_NUM_DAIS 8 358#endif 359 360/* Intel HD Audio SRAM Window 0*/ 361#define HDA_ADSP_SRAM0_BASE_SKL 0x8000 362 363/* Firmware status window */ --- 201 unchanged lines hidden (view full) --- 565 566int hda_ipc_msg_data(struct snd_sof_dev *sdev, 567 struct snd_pcm_substream *substream, 568 void *p, size_t sz); 569int hda_ipc_pcm_params(struct snd_sof_dev *sdev, 570 struct snd_pcm_substream *substream, 571 const struct sof_ipc_pcm_params_reply *reply); 572 |
578#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_PROBES) | |
579/* | 573/* |
580 * Probe Compress Operations. 581 */ 582int hda_probe_compr_assign(struct snd_sof_dev *sdev, 583 struct snd_compr_stream *cstream, 584 struct snd_soc_dai *dai); 585int hda_probe_compr_free(struct snd_sof_dev *sdev, 586 struct snd_compr_stream *cstream, 587 struct snd_soc_dai *dai); 588int hda_probe_compr_set_params(struct snd_sof_dev *sdev, 589 struct snd_compr_stream *cstream, 590 struct snd_compr_params *params, 591 struct snd_soc_dai *dai); 592int hda_probe_compr_trigger(struct snd_sof_dev *sdev, 593 struct snd_compr_stream *cstream, int cmd, 594 struct snd_soc_dai *dai); 595int hda_probe_compr_pointer(struct snd_sof_dev *sdev, 596 struct snd_compr_stream *cstream, 597 struct snd_compr_tstamp *tstamp, 598 struct snd_soc_dai *dai); 599#endif 600 601/* | |
602 * DSP IPC Operations. 603 */ 604int hda_dsp_ipc_send_msg(struct snd_sof_dev *sdev, 605 struct snd_sof_ipc_msg *msg); 606void hda_dsp_ipc_get_reply(struct snd_sof_dev *sdev); 607int hda_dsp_ipc_get_mailbox_offset(struct snd_sof_dev *sdev); 608int hda_dsp_ipc_get_window_offset(struct snd_sof_dev *sdev, u32 id); 609 --- 114 unchanged lines hidden (view full) --- 724extern const struct sof_intel_dsp_desc skl_chip_info; 725extern const struct sof_intel_dsp_desc icl_chip_info; 726extern const struct sof_intel_dsp_desc tgl_chip_info; 727extern const struct sof_intel_dsp_desc tglh_chip_info; 728extern const struct sof_intel_dsp_desc ehl_chip_info; 729extern const struct sof_intel_dsp_desc jsl_chip_info; 730extern const struct sof_intel_dsp_desc adls_chip_info; 731 | 574 * DSP IPC Operations. 575 */ 576int hda_dsp_ipc_send_msg(struct snd_sof_dev *sdev, 577 struct snd_sof_ipc_msg *msg); 578void hda_dsp_ipc_get_reply(struct snd_sof_dev *sdev); 579int hda_dsp_ipc_get_mailbox_offset(struct snd_sof_dev *sdev); 580int hda_dsp_ipc_get_window_offset(struct snd_sof_dev *sdev, u32 id); 581 --- 114 unchanged lines hidden (view full) --- 696extern const struct sof_intel_dsp_desc skl_chip_info; 697extern const struct sof_intel_dsp_desc icl_chip_info; 698extern const struct sof_intel_dsp_desc tgl_chip_info; 699extern const struct sof_intel_dsp_desc tglh_chip_info; 700extern const struct sof_intel_dsp_desc ehl_chip_info; 701extern const struct sof_intel_dsp_desc jsl_chip_info; 702extern const struct sof_intel_dsp_desc adls_chip_info; 703 |
704/* Probes support */ 705#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_PROBES) 706int hda_probes_register(struct snd_sof_dev *sdev); 707void hda_probes_unregister(struct snd_sof_dev *sdev); 708#else 709static inline int hda_probes_register(struct snd_sof_dev *sdev) 710{ 711 return 0; 712} 713 714static inline void hda_probes_unregister(struct snd_sof_dev *sdev) 715{ 716} 717#endif /* CONFIG_SND_SOC_SOF_HDA_PROBES */ 718 719/* SOF client registration for HDA platforms */ 720int hda_register_clients(struct snd_sof_dev *sdev); 721void hda_unregister_clients(struct snd_sof_dev *sdev); 722 |
|
732/* machine driver select */ 733struct snd_soc_acpi_mach *hda_machine_select(struct snd_sof_dev *sdev); 734void hda_set_mach_params(struct snd_soc_acpi_mach *mach, 735 struct snd_sof_dev *sdev); 736 737/* PCI driver selection and probe */ 738int hda_pci_intel_probe(struct pci_dev *pci, const struct pci_device_id *pci_id); 739 --- 12 unchanged lines hidden --- | 723/* machine driver select */ 724struct snd_soc_acpi_mach *hda_machine_select(struct snd_sof_dev *sdev); 725void hda_set_mach_params(struct snd_soc_acpi_mach *mach, 726 struct snd_sof_dev *sdev); 727 728/* PCI driver selection and probe */ 729int hda_pci_intel_probe(struct pci_dev *pci, const struct pci_device_id *pci_id); 730 --- 12 unchanged lines hidden --- |