⚠ This page is served via a proxy. Original site: https://github.com
This service does not collect credentials or authentication data.
Skip to content

Conversation

@bardliao
Copy link
Collaborator

@bardliao bardliao commented Feb 6, 2026

The parameters may be changed by the machine driver based on the actual hardware configuration. We need to use the acpi mach from the machine driver.

@@ -2530,8 +2531,12 @@ int snd_sof_load_topology(struct snd_soc_component *scomp, const char *file)
*/
bool no_fallback = strstr(file, "dummy");

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what issue does this fix?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use the SOC_SDW_PCH_DMIC quirk to indicate that the PCH DMIC is used. We will set mach_params->dmic_num = DMIC_DEFAULT_CHANNELS; to the mach_params from dev_get_platdata(card->dev) when the quirk is set. But the mach_params of the sof_sdw_get_tplg_files() function is from sdev->pdata. In other words, the mach_params->dmic_num of sof_pdata->machine remains 0 and it will cause the unsupported number of dmics: 0 issue.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will the dmic_num override still going to be working?

But in other words we have two places whit dmic_num and they are used in a 'random' way around the code?

ujfalusi
ujfalusi previously approved these changes Feb 10, 2026
Copy link
Collaborator

@ujfalusi ujfalusi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we want it to be backported to stable kernels? Fixes tag?

/* Try to use function topologies if possible */
if (!sof_pdata->disable_function_topology && !disable_function_topology &&
sof_pdata->machine && sof_pdata->machine->get_function_tplg_files) {
struct snd_soc_acpi_mach *card_mach = dev_get_platdata(scomp->card->dev);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This never going to be NULL, right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question @ujfalusi I don't think it will be NULL, but it is not guarantee that it is with the snd_soc_acpi_mach struct. I will move the change to sof_sdw_get_tplg_files() which is specific to Intel SDW machines.

@@ -2530,8 +2531,12 @@ int snd_sof_load_topology(struct snd_soc_component *scomp, const char *file)
*/
bool no_fallback = strstr(file, "dummy");

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will the dmic_num override still going to be working?

But in other words we have two places whit dmic_num and they are used in a 'random' way around the code?

@bardliao
Copy link
Collaborator Author

do we want it to be backported to stable kernels? Fixes tag?

Yes, I will add it.

The parameters may be changed by the of_sdw achine driver based on the
machine driver quirk. We need to use the acpi mach from the machine
driver.

Fixes: 2fbeff3 ("ASoC: Intel: add sof_sdw_get_tplg_files ops")
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants