On the following machines, my HDMI sound doesn't work: 1> Raspberry Pi 2 with Raspbian (Debian Jessie based GNU-Linux) tested with the following monitors: a) Sharp Big Screen TV b) ViewSonic 1080p 24" computer monitor with built in speakers.
2> Computer Tower with Asus motherboard and Intel Core i5 CPU 750 connected to the above [b)] ViewSonic 1080p 24" computer monitor with built in speakers. This machine Dual Boots OS between Ubuntu 13.10 and Kubuntu 15.10. On both Ubuntu 13.10 and Kubuntu 15.10 I go into the settings of the monitor and select HDMI, and on the computer's sound settings, I select HDMI. Nothing works on either system despite checking, tinkering, googling for answers, and more tinkering.
But, I do have ONE MACHINE with HDMI SOUND WORKING CORRECTLY: It's connected to the above [b)] ViewSonic 1080p 24" computer monitor with built in speakers. That is an intel Next Unit of Computing (NUC) equipped with a 2013? era (I think second gen) core i3 connected to a Viewsonic 1080p monitor with built in speakers, running with Kubuntu 14.04 LTS.
I think the problem must be a bug rather than a monitor issue or configuration setting on the desktop, and I'm imagining that it to be widespread. Could it be that only Linux kernel can't resolve HDMI sound on the Raspberry Pi 2, or on my Tower with the ASUS motherboard?
Here's some additional hardware information on the above listed Computer Tower that dual boots between Ubuntu 13.10 and Kubuntu 15.10 where the HDMI sound isn't working:
lspci
00:00.0 Host bridge: Intel Corporation Core Processor DMI (rev 11)
00:03.0 PCI bridge: Intel Corporation Core Processor PCI Express Root Port 1 (rev 11)
...
00:1b.0 Audio device: Intel Corporation 5 Series/3400 Series Chipset High Definition Audio (rev 05)
00:1c.0 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 1 (rev 05)
00:1c.4 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 5 (rev 05)
00:1c.5 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 6 (rev 05)
00:1c.6 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 7 (rev 05)
00:1c.7 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 8 (rev 05)
...
01:00.0 VGA compatible controller: NVIDIA Corporation GT218 [GeForce 210] (rev a2)
01:00.1 Audio device: NVIDIA Corporation High Definition Audio Controller (rev a1)
and
lshw
...
*-pci
description: Host bridge
product: Core Processor DMI
vendor: Intel Corporation
physical id: 100
bus info: pci@0000:00:00.0
version: 11
width: 32 bits
clock: 33MHz
*-pci:0
description: PCI bridge
product: Core Processor PCI Express Root Port 1
vendor: Intel Corporation
physical id: 3
bus info: pci@0000:00:03.0
version: 11
width: 32 bits
clock: 33MHz
capabilities: pci normal_decode bus_master cap_list
configuration: driver=pcieport
resources: irq:16 ioport:b000(size=4096) memory:fa000000-fbbfffff ioport:ce000000(size=301989888)
*-display
description: VGA compatible controller
product: GT218 [GeForce 210]
vendor: NVIDIA Corporation
physical id: 0
bus info: pci@0000:01:00.0
version: a2
width: 64 bits
clock: 33MHz
capabilities: vga_controller bus_master cap_list rom
configuration: driver=nouveau latency=0
resources: irq:16 memory:fa000000-faffffff memory:d0000000-dfffffff memory:ce000000-cfffffff ioport:bc00(size=128) memory:fbb00000-fbb7ffff
*-multimedia
description: Audio device
product: High Definition Audio Controller
vendor: NVIDIA Corporation
physical id: 0.1
bus info: pci@0000:01:00.1
version: a1
width: 32 bits
clock: 33MHz
capabilities: bus_master cap_list
configuration: driver=snd_hda_intel latency=0
resources: irq:17 memory:fbbfc000-fbbfffff
...
*-multimedia
description: Audio device
product: 5 Series/3400 Series Chipset High Definition Audio
vendor: Intel Corporation
physical id: 1b
bus info: pci@0000:00:1b.0
version: 05
width: 64 bits
clock: 33MHz
capabilities: bus_master cap_list
configuration: driver=snd_hda_intel latency=0
resources: irq:46 memory:f9ff8000-f9ffbfff
I'm imagining the problem to be widespread because it affects two machines Raspberry Pi 2 and my older core i5 Computer Tower. I've tested them with two monitors, the computer monitor and big screen tv. And I've tested them with three operating systems between the two: Raspbian (based on Debian-Jessie GNU-Linux). AND I've got one machine where the HDMI sound does work, my Intel NUC core i3 that's connected to the above computer monitor).
--EDIT-- Is it possible that some HDMI video cards do not support sound over their HDMI?