Repository navigation
Conversation
When dai_num is 1, we can assume that the endpoint is always present and there is no need to check whether the endpoint is present in the SDCA DisCo table. Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
There was a problem hiding this comment.
🟢 Approval recommended
The narrow condition implements the stated behavior without changing multi-DAI validation.
No open issues 🎉
What changed in this PR
Updates Intel SOF endpoint discovery to assume single-DAI codec endpoints are present.
Changes:
- Skips SDCA DisCo endpoint checks for single-DAI codecs.
- Preserves endpoint validation for multi-DAI codecs.
| File | Description |
|---|---|
| sound/soc/sof/intel/hda.c | Limits endpoint presence checks to multi-DAI codecs. |
Review effort: Balanced
|
Is this just an optimisation or working around something? It feels like this should work fine without this patch. I could imagine situations where one could end up with a codec with no endpoints, vendors like to have bios disables for features like mics. If you had a mic only codec I could see a bios disable getting implemented in a way that left the codec in the ACPI but removed the mic function from the SDCA. Yes it would be a bit weird but I could definitely imagine it happening. |
|
@charleskeepax It is mainly for the TAS2783 |
|
I am not aware of anything this will break that currently exists so probably fine for now. But would be nice to update the commit message to reference that TI thing and note the similar behaviour in asoc_sdw_parse_sdw_endpoints(), will be useful if we do hit problems in the future to be able to see why this change was made. |
| /* Check if the endpoint is present by the SDCA DisCo table */ | ||
| if (!is_endpoint_present(sdw_device, codec_info_list[i].dais[j].dai_type)) | ||
| if (codec_info_list[i].dai_num > 1 && | ||
| !is_endpoint_present(sdw_device, codec_info_list[i].dais[j].dai_type)) |
There was a problem hiding this comment.
why we cannot assume the same for let's say dai_num == 3, or 7?
When dai_num is 1, we can assume that the endpoint is always present and there is no need to check whether the endpoint is present in the SDCA DisCo table.