From 398ba21624ac17e4ef0d6313b73aecaa9168c3ff Mon Sep 17 00:00:00 2001 From: Isaac Date: Tue, 6 Aug 2024 22:41:11 -0500 Subject: [PATCH] fix(Ally X): prefer HDMI audio when docked (#1467) Create rule for HDMI and new folder structure for wireplumber for Ally X. --- .../wireplumber.conf.d/51-preferHDMI.conf | 15 ++++++++ .../wireplumber.conf.d/alsa-card0.conf | 18 +++++++++ .../wireplumber.conf.d/alsa-card1.conf | 37 +++++++++++++++++++ 3 files changed, 70 insertions(+) create mode 100644 system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/51-preferHDMI.conf create mode 100644 system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card0.conf create mode 100644 system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card1.conf diff --git a/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/51-preferHDMI.conf b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/51-preferHDMI.conf new file mode 100644 index 00000000..aeb3e6a0 --- /dev/null +++ b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/51-preferHDMI.conf @@ -0,0 +1,15 @@ +monitor.alsa.rules = [ + { + matches = [ + { + node.name = "alsa_output.pci-0000_64_00.1.hdmi-stereo" + } + ] + actions = { + update-props = { + priority.driver = 1100 + priority.session = 1100 + } + } + } +] \ No newline at end of file diff --git a/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card0.conf b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card0.conf new file mode 100644 index 00000000..bcc2c4d3 --- /dev/null +++ b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card0.conf @@ -0,0 +1,18 @@ +monitor.alsa.rules = [ + { + matches = [ + { + node.name = "alsa_output.pci-0000_64_00.6.analog-stereo" + } + ] + actions = { + update-props = { + priority.driver = 900 + priority.session = 900 + api.alsa.period-size = 256 + api.alsa.headroom = 1024 + session.suspend-timeout-seconds = 0 + } + } + } +] diff --git a/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card1.conf b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card1.conf new file mode 100644 index 00000000..ff891c05 --- /dev/null +++ b/system_files/deck/shared/usr/share/wireplumber/hardware-profiles/asustek computer inc.-rog ally x rc72la_rc72la/wireplumber.conf.d/alsa-card1.conf @@ -0,0 +1,37 @@ +monitor.alsa.rules = [ + { + matches = [ + { + node.name = "~alsa_input.*" + alsa.card_name = "acp5x" + } + { + node.name = "~alsa_input.*" + alsa.card_name = "acp6x" + } + { + node.name = "~alsa_input.*" + alsa.card_name = "sof-nau8821-max" + } + { + node.name = "~alsa_output.*" + alsa.card_name = "acp5x" + } + { + node.name = "~alsa_output.*" + alsa.card_name = "acp6x" + } + { + node.name = "~alsa_output.*" + alsa.card_name = "sof-nau8821-max" + } + ] + actions = { + update-props = { + session.suspend-timeout-seconds = 0 + api.alsa.headroom = 1024 + } + } + } +] +