alsa-lib/alsa-ucm-conf.patch
Jaroslav Kysela 035a11419c Update to v1.2.13
Resolves: RHEL-60918

Signed-off-by: Jaroslav Kysela <jkysela@redhat.com>
2024-12-05 11:48:14 +01:00

355 lines
11 KiB
Diff

From 11b028a9a01e47fc9b48e4a566803752011902e2 Mon Sep 17 00:00:00 2001
From: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Date: Wed, 13 Nov 2024 14:48:38 +0200
Subject: [PATCH 1/8] UCM2: Intel: sof-hda-dsp: Fix handling of empty
sys_vendor
The mistake in UCM syntax caused in alsaucm start error:
ALSA lib ucm_cond.c:367:(if_eval) unknown If.Condition.Type
Fixes: 13022a97711d ("sof-hda-dsp: Fix the case where sysfs dmi
sys_vendor attribute is not set")
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/463
Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/Intel/sof-hda-dsp/HiFi-sof.conf | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
index fea8159..c755ba2 100644
--- a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
+++ b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
@@ -6,8 +6,8 @@ Define.SOFVendor "$${sys:devices/virtual/dmi/id/sys_vendor}"
If.SOFVendor {
Condition {
- Type Empty
- String "${var:SOFVendor}"
+ Type String
+ Empty "${var:SOFVendor}"
}
True.Define.SOFVendor "${sys:devices/virtual/dmi/id/board_vendor}"
}
--
2.47.0
From 6397c663d7086b87ca5cbba323ea3dcd0ecd3200 Mon Sep 17 00:00:00 2001
From: Jaroslav Kysela <perex@perex.cz>
Date: Wed, 13 Nov 2024 16:19:15 +0100
Subject: [PATCH 2/8] sof-hda-dsp: Fix the case where sysfs dmi product_name
attribute is not set
!!DMI Information
!!---------------
Manufacturer:
Product Name:
Product Version:
Firmware Version: R6G07
System SKU: Default string
Board Vendor: Default string
Board Name: Default string
BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=2292583
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/Intel/sof-hda-dsp/HiFi-sof.conf | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
index c755ba2..5fd1843 100644
--- a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
+++ b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
@@ -3,6 +3,7 @@
# File paths for controlling SOF processing
Define.SOFVendor "$${sys:devices/virtual/dmi/id/sys_vendor}"
+Define.SOFProduct "$${sys:devices/virtual/dmi/id/product_name}"
If.SOFVendor {
Condition {
@@ -12,6 +13,14 @@ If.SOFVendor {
True.Define.SOFVendor "${sys:devices/virtual/dmi/id/board_vendor}"
}
+If.SOFProduct {
+ Condition {
+ Type String
+ Empty "${var:SOFProduct}"
+ }
+ True.Define.SOFProduct "${sys:devices/virtual/dmi/id/board_name}"
+}
+
If.SOFIPCVer {
Condition {
Type ControlExists
@@ -43,7 +52,7 @@ If.SOFPath {
HeadphoneIirBlob "${var:BlobPath}/eq_iir/pass.blob"
HeadphoneFirBlob "${var:BlobPath}/eq_fir/pass.blob"
HeadphoneDrcBlob "${var:BlobPath}/drc/passthrough.blob"
- ConfPathFromDMI "${var:SOFVendor}/${sys:devices/virtual/dmi/id/product_name}.conf"
+ ConfPathFromDMI "${var:SOFVendor}/${var:SOFProduct}"
SOFProductConfig "/blobs/sof/product_configs/${var:ConfPathFromDMI}"
SOFConfFullPath "${ConfTopDir}${var:SOFProductConfig}"
SOFUserConfig "/blobs/sof/user_configs/${var:ConfPathFromDMI}"
--
2.47.0
From 70f5bff86035d454312c9d01e304a95791668ea5 Mon Sep 17 00:00:00 2001
From: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Date: Tue, 19 Nov 2024 11:51:15 +0200
Subject: [PATCH 3/8] sof-soundwire: cs42l43-spk: Correct PlaybackPCM and
routing
For speaker the correct PCM device to use is "hw:${CardId},2", the
"hw:${CardId},0" is for headset playback.
Adjust the routing as well since with :0,2 the DP6RX1/2 needs to be
selected for the speaker.
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/465
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/sof-soundwire/cs42l43-spk.conf | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/ucm2/sof-soundwire/cs42l43-spk.conf b/ucm2/sof-soundwire/cs42l43-spk.conf
index 73f1299..693c450 100644
--- a/ucm2/sof-soundwire/cs42l43-spk.conf
+++ b/ucm2/sof-soundwire/cs42l43-spk.conf
@@ -8,8 +8,8 @@ SectionDevice."Speaker" {
]
EnableSequence [
- cset "name='cs42l43 Speaker L Input 1' 'DP5RX1'"
- cset "name='cs42l43 Speaker R Input 1' 'DP5RX2'"
+ cset "name='cs42l43 Speaker L Input 1' 'DP6RX1'"
+ cset "name='cs42l43 Speaker R Input 1' 'DP6RX2'"
]
DisableSequence [
@@ -19,7 +19,7 @@ SectionDevice."Speaker" {
Value {
PlaybackPriority 100
- PlaybackPCM "hw:${CardId},0"
+ PlaybackPCM "hw:${CardId},2"
PlaybackMixerElem "cs42l43 Speaker Digital"
}
}
--
2.47.0
From 02f4fb77d10ab08a2253d77b90942b5ce9a7ed87 Mon Sep 17 00:00:00 2001
From: lbilli <lbilli@users.noreply.github.com>
Date: Thu, 14 Nov 2024 20:06:48 -0500
Subject: [PATCH 4/8] avs_nau8825: Fix JackControl name
This is the name reported by amixer events.
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/464
Signed-off-by: lbilli <lbilli@users.noreply.github.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/Intel/avs/avs_nau8825/avs_nau8825-HiFi.conf | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ucm2/Intel/avs/avs_nau8825/avs_nau8825-HiFi.conf b/ucm2/Intel/avs/avs_nau8825/avs_nau8825-HiFi.conf
index 3f3e6c9..71f7ed0 100644
--- a/ucm2/Intel/avs/avs_nau8825/avs_nau8825-HiFi.conf
+++ b/ucm2/Intel/avs/avs_nau8825/avs_nau8825-HiFi.conf
@@ -21,7 +21,7 @@ SectionDevice."Mic" {
Value {
CapturePCM "hw:${CardId},1"
CaptureCTL "Mic"
- JackControl "Headset Mic"
+ JackControl "Headset Mic Jack"
}
EnableSequence [
--
2.47.0
From 30989bd0c2aa3f9f4b6f5e393397b39678717f45 Mon Sep 17 00:00:00 2001
From: Charles Keepax <ckeepax@opensource.cirrus.com>
Date: Wed, 20 Nov 2024 10:06:06 +0000
Subject: [PATCH 5/8] sof-soundwire: cs42l43: Correct CapturePCM and routing
For headset microphone capture the correct PCM device to use is
"hw:${CardId},1", "hw:${CardId},4" is for built in microphone capture.
Adjust the routing as well since :0,1 is connected to data port 2 on the
codec.
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/466
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/sof-soundwire/cs42l43.conf | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/ucm2/sof-soundwire/cs42l43.conf b/ucm2/sof-soundwire/cs42l43.conf
index dc11840..4b4e118 100644
--- a/ucm2/sof-soundwire/cs42l43.conf
+++ b/ucm2/sof-soundwire/cs42l43.conf
@@ -28,19 +28,19 @@ SectionDevice."Headset" {
cset "name='cs42l43 ADC1 Input' 'IN1'"
cset "name='cs42l43 Decimator 1 Mode' 'ADC'"
- cset "name='cs42l43 DP1TX1 Input' 'Decimator 1'"
- cset "name='cs42l43 DP1TX2 Input' 'Decimator 1'"
+ cset "name='cs42l43 DP2TX1 Input' 'Decimator 1'"
+ cset "name='cs42l43 DP2TX2 Input' 'Decimator 1'"
]
DisableSequence [
cset "name='cs42l43 Decimator 1 Switch' 0"
- cset "name='cs42l43 DP1TX1 Input' 'None'"
- cset "name='cs42l43 DP1TX2 Input' 'None'"
+ cset "name='cs42l43 DP2TX1 Input' 'None'"
+ cset "name='cs42l43 DP2TX2 Input' 'None'"
]
Value {
CapturePriority 200
- CapturePCM "hw:${CardId},4"
+ CapturePCM "hw:${CardId},1"
CaptureMixer "default:${CardId}"
CaptureMixerElem "cs42l43 Headset Microphone"
JackControl "Headset Mic Jack"
--
2.47.0
From 62acef2efffdcb75a35f90d266bcad145b4eab35 Mon Sep 17 00:00:00 2001
From: Jaroslav Kysela <perex@perex.cz>
Date: Fri, 29 Nov 2024 14:04:00 +0100
Subject: [PATCH 6/8] sof-soundwire: whitespace cleanup
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/common/pcm/hdmi.conf | 2 +-
ucm2/sof-soundwire/sof-soundwire.conf | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/ucm2/common/pcm/hdmi.conf b/ucm2/common/pcm/hdmi.conf
index e2820dc..37338ec 100644
--- a/ucm2/common/pcm/hdmi.conf
+++ b/ucm2/common/pcm/hdmi.conf
@@ -69,7 +69,7 @@ DefineMacro.HdmiPCMSave {
}
FixedBootSequence [
- cfg-save "${var:LibDir}/${var:__Name}.conf:hdmi-pcm"
+ cfg-save "${var:LibDir}/${var:__Name}.conf:hdmi-pcm"
]
}
diff --git a/ucm2/sof-soundwire/sof-soundwire.conf b/ucm2/sof-soundwire/sof-soundwire.conf
index 34f9661..bb14ef2 100644
--- a/ucm2/sof-soundwire/sof-soundwire.conf
+++ b/ucm2/sof-soundwire/sof-soundwire.conf
@@ -157,7 +157,7 @@ If.mics-array {
Empty "${var:Mics1}"
}
False.FixedBootSequence {
- # dmic array info
+ # dmic array info
exec "-nhlt-dmic-info -o ${var:LibDir}/dmics-nhlt.json"
}
}
--
2.47.0
From 4a01327cc43a18124c0a4a5bcfb840e6ed1efe0a Mon Sep 17 00:00:00 2001
From: Jaroslav Kysela <perex@perex.cz>
Date: Wed, 4 Dec 2024 10:20:51 +0100
Subject: [PATCH 7/8] sof-hda-dsp: Add back missing .conf suffix for
product/user specific configs
Fixes: 6397c66 ("sof-hda-dsp: Fix the case where sysfs dmi product_name attribute is not set")
Closes: https://github.com/alsa-project/alsa-ucm-conf/issues/482
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/Intel/sof-hda-dsp/HiFi-sof.conf | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
index 5fd1843..3a4c445 100644
--- a/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
+++ b/ucm2/Intel/sof-hda-dsp/HiFi-sof.conf
@@ -52,7 +52,7 @@ If.SOFPath {
HeadphoneIirBlob "${var:BlobPath}/eq_iir/pass.blob"
HeadphoneFirBlob "${var:BlobPath}/eq_fir/pass.blob"
HeadphoneDrcBlob "${var:BlobPath}/drc/passthrough.blob"
- ConfPathFromDMI "${var:SOFVendor}/${var:SOFProduct}"
+ ConfPathFromDMI "${var:SOFVendor}/${var:SOFProduct}.conf"
SOFProductConfig "/blobs/sof/product_configs/${var:ConfPathFromDMI}"
SOFConfFullPath "${ConfTopDir}${var:SOFProductConfig}"
SOFUserConfig "/blobs/sof/user_configs/${var:ConfPathFromDMI}"
--
2.47.0
From 0782bf435b8332833e7b3fc91501d78473dd6edf Mon Sep 17 00:00:00 2001
From: Jaroslav Kysela <perex@perex.cz>
Date: Fri, 29 Nov 2024 14:17:57 +0100
Subject: [PATCH 8/8] amd-soundwire: add support for AMD generic legacy machine
driver
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/478
Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/470
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
---
ucm2/conf.d/amd-soundwire/amd-soundwire.conf | 1 +
ucm2/sof-soundwire/rt722.conf | 15 +++++++++++++++
2 files changed, 16 insertions(+)
create mode 120000 ucm2/conf.d/amd-soundwire/amd-soundwire.conf
diff --git a/ucm2/conf.d/amd-soundwire/amd-soundwire.conf b/ucm2/conf.d/amd-soundwire/amd-soundwire.conf
new file mode 120000
index 0000000..0d00b73
--- /dev/null
+++ b/ucm2/conf.d/amd-soundwire/amd-soundwire.conf
@@ -0,0 +1 @@
+../../sof-soundwire/sof-soundwire.conf
\ No newline at end of file
diff --git a/ucm2/sof-soundwire/rt722.conf b/ucm2/sof-soundwire/rt722.conf
index a54664e..a4a431b 100644
--- a/ucm2/sof-soundwire/rt722.conf
+++ b/ucm2/sof-soundwire/rt722.conf
@@ -86,6 +86,21 @@ SectionDevice."Headset" {
cset "name='rt722 FU0F Capture Switch' 0"
]
+ If.hsmicsw {
+ Condition {
+ Type ControlExists
+ Control "name='Headset Mic Switch'"
+ }
+ True {
+ EnableSequence [
+ cset "name='Headset Mic Switch' on"
+ ]
+ DisableSequence [
+ cset "name='Headset Mic Switch' off"
+ ]
+ }
+ }
+
Value {
CapturePriority 200
CapturePCM "hw:${CardId},1"
--
2.47.0