diff mbox

conf: HdmiLpeAudio: add support for 3 devices

Message ID 20170816160848.19297-1-pierre-louis.bossart@linux.intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Pierre-Louis Bossart Aug. 16, 2017, 4:08 p.m. UTC
The LPE Audio mode on BYT/CHT supports up to 3 devices, and also supports
IEC61937 passthrough. Add missing alsa-lib configurations so that
apps can use the usual -D'hdmi:CARD=X,DEV=Y,AES0=0x[4|6]' syntax, e.g.

aplay -D'hdmi:CARD=0,DEV=2,AES0=0x6' -c2 -r48000 -fs16_le
ac3_surround_test.spdif

Tested on Zotac PI330 with Onkyo receiver

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 src/conf/cards/HdmiLpeAudio.conf | 77 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)

Comments

Takashi Iwai Aug. 16, 2017, 4:11 p.m. UTC | #1
On Wed, 16 Aug 2017 18:08:48 +0200,
Pierre-Louis Bossart wrote:
> 
> The LPE Audio mode on BYT/CHT supports up to 3 devices, and also supports
> IEC61937 passthrough. Add missing alsa-lib configurations so that
> apps can use the usual -D'hdmi:CARD=X,DEV=Y,AES0=0x[4|6]' syntax, e.g.
> 
> aplay -D'hdmi:CARD=0,DEV=2,AES0=0x6' -c2 -r48000 -fs16_le
> ac3_surround_test.spdif
> 
> Tested on Zotac PI330 with Onkyo receiver
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

Applied, thanks.


Takashi
diff mbox

Patch

diff --git a/src/conf/cards/HdmiLpeAudio.conf b/src/conf/cards/HdmiLpeAudio.conf
index dae71fa..9fa30da 100644
--- a/src/conf/cards/HdmiLpeAudio.conf
+++ b/src/conf/cards/HdmiLpeAudio.conf
@@ -56,6 +56,83 @@  HdmiLpeAudio.pcm.hdmi.0 {
 			{
 				interface PCM
 				name "IEC958 Playback Default"
+				device 0
+				lock true
+				preserve true
+				value [ $AES0 $AES1 $AES2 $AES3 ]
+			}
+		]
+	}
+}
+
+HdmiLpeAudio.pcm.hdmi.1 {
+	@args [ CARD AES0 AES1 AES2 AES3 ]
+	@args.CARD {
+		type string
+	}
+	@args.AES0 {
+		type integer
+	}
+	@args.AES1 {
+		type integer
+	}
+	@args.AES2 {
+		type integer
+	}
+	@args.AES3 {
+		type integer
+	}
+	type hooks
+	slave.pcm {
+		type hw
+		card $CARD
+		device 1
+	}
+	hooks.0 {
+		type ctl_elems
+		hook_args [
+			{
+				interface PCM
+				name "IEC958 Playback Default"
+				device 1
+				lock true
+				preserve true
+				value [ $AES0 $AES1 $AES2 $AES3 ]
+			}
+		]
+	}
+}
+
+HdmiLpeAudio.pcm.hdmi.2 {
+	@args [ CARD AES0 AES1 AES2 AES3 ]
+	@args.CARD {
+		type string
+	}
+	@args.AES0 {
+		type integer
+	}
+	@args.AES1 {
+		type integer
+	}
+	@args.AES2 {
+		type integer
+	}
+	@args.AES3 {
+		type integer
+	}
+	type hooks
+	slave.pcm {
+		type hw
+		card $CARD
+		device 2
+	}
+	hooks.0 {
+		type ctl_elems
+		hook_args [
+			{
+				interface PCM
+				name "IEC958 Playback Default"
+				device 2
 				lock true
 				preserve true
 				value [ $AES0 $AES1 $AES2 $AES3 ]