From ad0f62a411aeb5066d64985214634b073920800b Mon Sep 17 00:00:00 2001 From: Alex Bee Date: Sun, 31 Oct 2021 10:36:42 +0100 Subject: [PATCH] Rockchip: rework alsa card configs Also drop no longer needed HDMI.conf and I2S.conf --- .../filesystem/usr/share/alsa/cards/HDMI.conf | 34 ------------------- .../filesystem/usr/share/alsa/cards/I2S.conf | 12 ------- .../usr/share/alsa/cards/SPDIF.conf | 2 +- .../usr/share/alsa/cards/simple-card.conf | 20 ++++------- 4 files changed, 8 insertions(+), 60 deletions(-) delete mode 100644 projects/Rockchip/filesystem/usr/share/alsa/cards/HDMI.conf delete mode 100644 projects/Rockchip/filesystem/usr/share/alsa/cards/I2S.conf diff --git a/projects/Rockchip/filesystem/usr/share/alsa/cards/HDMI.conf b/projects/Rockchip/filesystem/usr/share/alsa/cards/HDMI.conf deleted file mode 100644 index a79abf8d3e..0000000000 --- a/projects/Rockchip/filesystem/usr/share/alsa/cards/HDMI.conf +++ /dev/null @@ -1,34 +0,0 @@ -# -# Configuration for HDMI -# - - - -HDMI.pcm.hdmi.0 { - @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 0 - } - hooks.0 { - type ctl_elems - hook_args [ - { - interface MIXER - name "IEC958 Playback Default" - lock true - preserve true - optional true - value [ $AES0 $AES1 $AES2 $AES3 ] - } - ] - } - hint.device 0 -} diff --git a/projects/Rockchip/filesystem/usr/share/alsa/cards/I2S.conf b/projects/Rockchip/filesystem/usr/share/alsa/cards/I2S.conf deleted file mode 100644 index 0a21710eaa..0000000000 --- a/projects/Rockchip/filesystem/usr/share/alsa/cards/I2S.conf +++ /dev/null @@ -1,12 +0,0 @@ -# -# Configuration for I2S -# - - - -I2S.pcm.front.0 { - @args [ CARD ] - @args.CARD { type string } - type hw - card $CARD -} diff --git a/projects/Rockchip/filesystem/usr/share/alsa/cards/SPDIF.conf b/projects/Rockchip/filesystem/usr/share/alsa/cards/SPDIF.conf index 1618b55161..39c1c4e8ef 100644 --- a/projects/Rockchip/filesystem/usr/share/alsa/cards/SPDIF.conf +++ b/projects/Rockchip/filesystem/usr/share/alsa/cards/SPDIF.conf @@ -21,7 +21,7 @@ SPDIF.pcm.iec958.0 { type ctl_elems hook_args [ { - interface MIXER + interface PCM name "IEC958 Playback Default" lock true preserve true diff --git a/projects/Rockchip/filesystem/usr/share/alsa/cards/simple-card.conf b/projects/Rockchip/filesystem/usr/share/alsa/cards/simple-card.conf index 93b41e95c6..f7b81c0316 100644 --- a/projects/Rockchip/filesystem/usr/share/alsa/cards/simple-card.conf +++ b/projects/Rockchip/filesystem/usr/share/alsa/cards/simple-card.conf @@ -4,6 +4,9 @@ +simple-card.pcm.hdmi."hdmi-sound" "cards.simple-card.pcm.hdmi.HDMI" +simple-card.pcm.hdmi."rockchip_tinker-codec" "cards.simple-card.pcm.hdmi.HDMI" + simple-card.pcm.hdmi."HDMI" { @args [ CARD DEVICE AES0 AES1 AES2 AES3 ] @args.CARD { type string } @@ -22,7 +25,7 @@ simple-card.pcm.hdmi."HDMI" { type ctl_elems hook_args [ { - interface MIXER + interface PCM name "IEC958 Playback Default" lock true preserve true @@ -41,7 +44,6 @@ simple-card.pcm.hdmi.0 { @args.AES1 { type integer } @args.AES2 { type integer } @args.AES3 { type integer } - @func refer name { @func concat @@ -62,7 +64,6 @@ simple-card.pcm.hdmi.0 { device 999 hint.device 999 } - } # @@ -89,7 +90,7 @@ simple-card.pcm.iec958."SPDIF" { type ctl_elems hook_args [ { - interface MIXER + interface PCM name "IEC958 Playback Default" lock true preserve true @@ -165,6 +166,8 @@ simple-card.pcm.iec958.1 { +simple-card.pcm.front."I2S" "cards.simple-card.pcm.front.Analog" + simple-card.pcm.front."Analog" { @args [ CARD DEVICE ] @args.CARD { type string } @@ -174,15 +177,6 @@ simple-card.pcm.front."Analog" { hint.device $DEVICE } -simple-card.pcm.front."I2S" { - @args [ CARD ] - @args.CARD { type string } - @args.DEVICE { type integer } - type hw - card $CARD - hint.device $DEVICE -} - simple-card.pcm.front.0 { @args [ CARD ] @args.CARD { type string }