ASoC: Intel: sof-rt5682: add driver_data to sof_rt5682 board
Move default BYT/CHT quirk to driver_data of sof_rt5682 board. This
fixes a problem that DMI quirk of Minnowboard board got overwritten in
probe function since it's a BYT board.
Fixes: c68e07970e
("ASoC: intel: sof_rt5682: Add quirk for number of HDMI DAI's")
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Signed-off-by: Brent Lu <brent.lu@intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20240426152529.38345-21-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
76fb0d3221
commit
76f33e2f93
|
@ -638,7 +638,6 @@ static int sof_audio_probe(struct platform_device *pdev)
|
|||
struct snd_soc_acpi_mach *mach = pdev->dev.platform_data;
|
||||
struct sof_card_private *ctx;
|
||||
char *card_name;
|
||||
bool is_legacy_cpu = false;
|
||||
int ret;
|
||||
|
||||
if (pdev->id_entry && pdev->id_entry->driver_data)
|
||||
|
@ -646,14 +645,6 @@ static int sof_audio_probe(struct platform_device *pdev)
|
|||
|
||||
dmi_check_system(sof_rt5682_quirk_table);
|
||||
|
||||
if (soc_intel_is_byt() || soc_intel_is_cht()) {
|
||||
is_legacy_cpu = true;
|
||||
|
||||
/* default quirk for legacy cpu */
|
||||
sof_rt5682_quirk = SOF_RT5682_MCLK_EN |
|
||||
SOF_SSP_PORT_CODEC(2);
|
||||
}
|
||||
|
||||
dev_dbg(&pdev->dev, "sof_rt5682_quirk = %lx\n", sof_rt5682_quirk);
|
||||
|
||||
/* initialize ctx with board quirk */
|
||||
|
@ -676,7 +667,7 @@ static int sof_audio_probe(struct platform_device *pdev)
|
|||
if (mach->mach_params.codec_mask & IDISP_CODEC_MASK)
|
||||
ctx->hdmi.idisp_codec = true;
|
||||
|
||||
if (is_legacy_cpu) {
|
||||
if (soc_intel_is_byt() || soc_intel_is_cht()) {
|
||||
ctx->rt5682.is_legacy_cpu = true;
|
||||
ctx->dmic_be_num = 0;
|
||||
/* HDMI is not supported by SOF on Baytrail/CherryTrail */
|
||||
|
@ -792,6 +783,8 @@ static int sof_audio_probe(struct platform_device *pdev)
|
|||
static const struct platform_device_id board_ids[] = {
|
||||
{
|
||||
.name = "sof_rt5682",
|
||||
.driver_data = (kernel_ulong_t)(SOF_RT5682_MCLK_EN |
|
||||
SOF_SSP_PORT_CODEC(2)),
|
||||
},
|
||||
{
|
||||
.name = "glk_rt5682_def",
|
||||
|
|
Loading…
Reference in New Issue