Skip to content

Commit 643a2cc

Browse files
committed
ALSA: hda: hdmi - Keep old slot assignment behavior for Intel platforms
The commit 609f548 ("ALSA: hda: hdmi - preserve non-MST PCM routing for Intel platforms") tried to restore the old behavior wrt assignment of the PCM slot for Intel platforms, but this didn't do it right. As found in the later discussion, a positive pipe id on Intel platforms can be passed for single monitor attachment case. This patch reverts the previous attempt and applies a simpler workaround instead. Actually, for Intel platforms, we can handle as if per_pin->dev_id=0, assign the primary slot at the first try. This assures the compatible behavior with the previous versions regarding the slot assignment. Fixes: 609f548 ("ALSA: hda: hdmi - preserve non-MST PCM routing for Intel platforms") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
1 parent e38e486 commit 643a2cc

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

sound/pci/hda/patch_hdmi.c

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1348,21 +1348,18 @@ static int hdmi_find_pcm_slot(struct hdmi_spec *spec,
13481348
* with the legacy static per_pin-pcm assignment that existed in the
13491349
* days before DP-MST.
13501350
*
1351+
* Intel DP-MST prefers this legacy behavior for compatibility, too.
1352+
*
13511353
* per_pin of m!=0 prefers to get pcm=(num_nids + (m - 1)).
13521354
*/
13531355

1354-
if (per_pin->dev_id == 0) {
1356+
if (per_pin->dev_id == 0 || spec->intel_hsw_fixup) {
13551357
if (!test_bit(per_pin->pin_nid_idx, &spec->pcm_bitmap))
13561358
return per_pin->pin_nid_idx;
13571359
} else {
13581360
i = spec->num_nids + (per_pin->dev_id - 1);
13591361
if (i < spec->pcm_used && !(test_bit(i, &spec->pcm_bitmap)))
13601362
return i;
1361-
1362-
/* keep legacy assignment for dev_id>0 on Intel platforms */
1363-
if (spec->intel_hsw_fixup)
1364-
if (!test_bit(per_pin->pin_nid_idx, &spec->pcm_bitmap))
1365-
return per_pin->pin_nid_idx;
13661363
}
13671364

13681365
/* have a second try; check the area over num_nids */

0 commit comments

Comments
 (0)