diff options
author | Naveen M <naveen.m@intel.com> | 2017-05-15 11:12:15 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2017-05-24 20:27:47 +0300 |
commit | 54746dabf770eb268d302f2f770d6dacea24f08a (patch) | |
tree | 422328eebb17e255b1e79fc61235b9997492f924 /sound/soc/intel/common/sst-acpi.h | |
parent | 7827d66946ad3af734ed46d1d68c23fa6974595c (diff) | |
download | linux-54746dabf770eb268d302f2f770d6dacea24f08a.tar.xz |
ASoC: Improve machine driver selection based on quirk data
Use quirk function to select the correct machine driver
by checking all codecs instead of only one based on quirk data.
Signed-off-by: Naveen M <naveen.m@intel.com>
Signed-off-by: Harsha Priya <harshapriya.n@intel.com>
Acked-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/common/sst-acpi.h')
-rw-r--r-- | sound/soc/intel/common/sst-acpi.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/sound/soc/intel/common/sst-acpi.h b/sound/soc/intel/common/sst-acpi.h index 3649d3b08c9e..afe9b87b8bd5 100644 --- a/sound/soc/intel/common/sst-acpi.h +++ b/sound/soc/intel/common/sst-acpi.h @@ -58,5 +58,25 @@ struct sst_acpi_mach { /* board name */ const char *board; struct sst_acpi_mach * (*machine_quirk)(void *arg); + const void *quirk_data; void *pdata; }; + +#define SST_ACPI_MAX_CODECS 3 + +/** + * struct sst_codecs: Structure to hold secondary codec information apart from + * the matched one, this data will be passed to the quirk function to match + * with the ACPI detected devices + * + * @num_codecs: number of secondary codecs used in the platform + * @codecs: holds the codec IDs + * + */ +struct sst_codecs { + int num_codecs; + u8 codecs[SST_ACPI_MAX_CODECS][ACPI_ID_LEN]; +}; + +/* check all codecs */ +struct sst_acpi_mach *sst_acpi_codec_list(void *arg); |