ASoC: SOF: pcm: Set the PCM device name for HDMI#5557
Merged
ujfalusi merged 1 commit intothesofproject:topic/sof-devfrom Oct 27, 2025
Merged
ASoC: SOF: pcm: Set the PCM device name for HDMI#5557ujfalusi merged 1 commit intothesofproject:topic/sof-devfrom
ujfalusi merged 1 commit intothesofproject:topic/sof-devfrom
Conversation
bardliao
previously approved these changes
Oct 16, 2025
kv2019i
previously approved these changes
Oct 16, 2025
Collaborator
kv2019i
left a comment
There was a problem hiding this comment.
This is very useful! One improvement idea inline (for code comments).
sound/soc/sof/pcm.c
Outdated
|
|
||
| /* | ||
| * Make sure that the name is in"HDMI<SPACE>x" format as this is | ||
| * expected by user space |
Collaborator
There was a problem hiding this comment.
Maybe even add reference to alsa-lib __snd_pcm_info_eld_fixup() called in alsa-lib snd_ctl_hw_pcm_info()...?
User space (alsa-lib) uses the PCM device name to detect HDMI devices, the name is expected to be in form of 'HDMI'+<space>+number. The PCM device name is not configured in ASoC, only the PCM id is set based on the loaded topology. Detect the HDMI PCM playback devices and configure the name to help user space to handle HDMI PCMs correctly. aplay -l | grep HDMI (Audio capable monitor connected) Before the change: card 0: sofhdadsp [sof-hda-dsp], device 3: HDMI1 (*) [] card 0: sofhdadsp [sof-hda-dsp], device 4: HDMI2 (*) [] card 0: sofhdadsp [sof-hda-dsp], device 5: HDMI3 (*) [] after the change: card 0: sofhdadsp [sof-hda-dsp], device 3: HDMI1 (*) [DELL P1917S] card 0: sofhdadsp [sof-hda-dsp], device 4: HDMI2 (*) [HDMI 2] card 0: sofhdadsp [sof-hda-dsp], device 5: HDMI3 (*) [HDMI 3] Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
fa3fc0e to
f4fa815
Compare
Collaborator
Author
|
Changes since v1:
|
bardliao
approved these changes
Oct 17, 2025
kv2019i
approved these changes
Oct 20, 2025
ranj063
approved these changes
Oct 20, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
User space (alsa-lib) uses the PCM device name to detect HDMI devices, the name is expected to be in form of 'HDMI'++number. The PCM device name is not configured in ASoC, only the PCM id is set based on the loaded topology.
Detect the HDMI PCM playback devices and configure the name to help user space to handle HDMI PCMs correctly.
aplay -l | grep HDMI (Audio capable monitor connected) Before the change:
card 0: sofhdadsp [sof-hda-dsp], device 3: HDMI1 () []
card 0: sofhdadsp [sof-hda-dsp], device 4: HDMI2 () []
card 0: sofhdadsp [sof-hda-dsp], device 5: HDMI3 (*) []
after the change:
card 0: sofhdadsp [sof-hda-dsp], device 3: HDMI1 () [DELL P1917S]
card 0: sofhdadsp [sof-hda-dsp], device 4: HDMI2 () [HDMI 2]
card 0: sofhdadsp [sof-hda-dsp], device 5: HDMI3 (*) [HDMI 3]