@@ -172,9 +172,10 @@ static int acp_asoc_probe(struct platform_device *pdev)
goto out;
}
if (!strcmp(pdev->name, "acp-pdm-mach"))
- acp_card_drvdata->platform = *((int *)dev->platform_data);
+ acp_card_drvdata->acp_rev = *((int *)dev->platform_data);
+ else
+ acp_card_drvdata->acp_rev = mach->mach_params.subsystem_rev;
- acp_card_drvdata->acp_rev = mach->mach_params.subsystem_rev;
dmi_id = dmi_first_match(acp_quirk_table);
if (dmi_id && dmi_id->driver_data)
acp_card_drvdata->tdm_mode = dmi_id->driver_data;
@@ -114,7 +114,7 @@ int acp_machine_select(struct acp_dev_data *adata)
int size, platform;
if (adata->flag == FLAG_AMD_LEGACY_ONLY_DMIC) {
- platform = adata->platform;
+ platform = adata->acp_rev;
adata->mach_dev = platform_device_register_data(adata->dev, "acp-pdm-mach",
PLATFORM_DEVID_NONE, &platform,
sizeof(platform));
Pass acp pci revision id as platform data to machine driver instead of 'platform' variable when ACP PDM configuration is selected. 'acp_rev' should be retrieved from mach params revision id for other configuration. Modify the conditional check for the same. Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> --- sound/soc/amd/acp/acp-legacy-mach.c | 5 +++-- sound/soc/amd/acp/acp-platform.c | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-)