linux-stable/include/sound/intel-dsp-config.h
Pierre-Louis Bossart b568230529
ALSA: hda: intel-dsp-config: add helper for ACPI DSP driver selection
Mirror capabilities provided for PCI devices, so that distributions
can select which ACPI driver is loaded at run-time with kernel
parameters and DMI tables instead of forcing a build-time selection.

The "legacy" option supported for HDaudio has no meaning here and will
be ignored.

The 'SST' driver based on closed-source firmware has the priority to
avoid any impact on users, and the choice to use SOF is strictly
opt-in. This may change at some point when the 'SST' driver is
deprecated on Baytrail/Cherrytrail.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Acked-by: Takashi Iwai <tiwai@suse.de>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Link: https://lore.kernel.org/r/20201112223825.39765-4-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2020-11-19 18:24:35 +00:00

41 lines
869 B
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* intel-dsp-config.h - Intel DSP config
*
* Copyright (c) 2019 Jaroslav Kysela <perex@perex.cz>
*/
#ifndef __INTEL_DSP_CONFIG_H__
#define __INTEL_DSP_CONFIG_H__
struct pci_dev;
enum {
SND_INTEL_DSP_DRIVER_ANY = 0,
SND_INTEL_DSP_DRIVER_LEGACY,
SND_INTEL_DSP_DRIVER_SST,
SND_INTEL_DSP_DRIVER_SOF,
SND_INTEL_DSP_DRIVER_LAST = SND_INTEL_DSP_DRIVER_SOF
};
#if IS_ENABLED(CONFIG_SND_INTEL_DSP_CONFIG)
int snd_intel_dsp_driver_probe(struct pci_dev *pci);
int snd_intel_acpi_dsp_driver_probe(struct device *dev, const u8 acpi_hid[ACPI_ID_LEN]);
#else
static inline int snd_intel_dsp_driver_probe(struct pci_dev *pci)
{
return SND_INTEL_DSP_DRIVER_ANY;
}
static inline
int snd_intel_acpi_dsp_driver_probe(struct device *dev, const u8 acpi_hid[ACPI_ID_LEN])
{
return SND_INTEL_DSP_DRIVER_ANY;
}
#endif
#endif