aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/pci/hda/patch_hdmi.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
index 895a0d3320b4..b83b14fa1d29 100644
--- a/sound/pci/hda/patch_hdmi.c
+++ b/sound/pci/hda/patch_hdmi.c
@@ -551,6 +551,17 @@ static int hdmi_channel_allocation(struct hdmi_eld *eld, int channels)
551 } 551 }
552 } 552 }
553 553
554 if (!ca) {
555 /* if there was no match, select the regular ALSA channel
556 * allocation with the matching number of channels */
557 for (i = 0; i < ARRAY_SIZE(channel_allocations); i++) {
558 if (channels == channel_allocations[i].channels) {
559 ca = channel_allocations[i].ca_index;
560 break;
561 }
562 }
563 }
564
554 snd_print_channel_allocation(eld->info.spk_alloc, buf, sizeof(buf)); 565 snd_print_channel_allocation(eld->info.spk_alloc, buf, sizeof(buf));
555 snd_printdd("HDMI: select CA 0x%x for %d-channel allocation: %s\n", 566 snd_printdd("HDMI: select CA 0x%x for %d-channel allocation: %s\n",
556 ca, channels, buf); 567 ca, channels, buf);