Merge ~mschiu77/ubuntu/+source/alsa-ucm-conf:ubuntu/noble-devel into ubuntu/+source/alsa-ucm-conf:ubuntu/devel
- Git
- lp:~mschiu77/ubuntu/+source/alsa-ucm-conf
- ubuntu/noble-devel
- Merge into ubuntu/devel
Status: | Needs review | ||||||||
---|---|---|---|---|---|---|---|---|---|
Proposed branch: | ~mschiu77/ubuntu/+source/alsa-ucm-conf:ubuntu/noble-devel | ||||||||
Merge into: | ubuntu/+source/alsa-ucm-conf:ubuntu/devel | ||||||||
Diff against target: |
2430 lines (+2266/-1) (has conflicts) 22 files modified
debian/changelog (+130/-0) debian/control (+6/-1) debian/patches/0001-acppdmmach-add-support-for-ACP-7.0.patch (+37/-0) debian/patches/0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch (+46/-0) debian/patches/0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch (+28/-0) debian/patches/0001-sof-soundwire-Change-map-control-names-to-make-them-.patch (+93/-0) debian/patches/0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch (+415/-0) debian/patches/0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch (+23/-0) debian/patches/0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch (+78/-0) debian/patches/0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch (+254/-0) debian/patches/0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch (+34/-0) debian/patches/0001-ucm2-soundwire-add-rt713-SDCA-device.patch (+159/-0) debian/patches/0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch (+62/-0) debian/patches/0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch (+53/-0) debian/patches/0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch (+95/-0) debian/patches/0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch (+30/-0) debian/patches/0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch (+243/-0) debian/patches/0003-sof-soundwire-Add-basic-support-for-cs42l43.patch (+128/-0) debian/patches/0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch (+36/-0) debian/patches/0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch (+253/-0) debian/patches/0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch (+44/-0) debian/patches/series (+19/-0) Conflict in debian/changelog Conflict in debian/control |
||||||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Simon Quigley (community) | git-only, not packaging | Needs Resubmitting | |
git-ubuntu import | Pending | ||
Review via email:
|
Commit message
Added patch to fix missing digital speaker on Dell Tarako (LP: #2088403)
Description of the change

Simon Quigley (tsimonq2) wrote : | # |
Unmerged commits
- 2503c3c... by Chris Chiu
-
1.2.10-1ubuntu5.3 (patches unapplied)
Imported using git-ubuntu import.
- a72feeb... by Chris Chiu
-
1.2.10-1ubuntu5.2 (patches unapplied)
Imported using git-ubuntu import.
- 34ff806... by Chris Chiu
-
1.2.10-1ubuntu5.1 (patches unapplied)
Imported using git-ubuntu import.
- 5d58b19... by Julian Andres Klode
-
1.2.10-1ubuntu5 (patches unapplied)
Imported using git-ubuntu import.
- d450035... by Steve Langasek
-
1.2.10-1ubuntu4 (patches unapplied)
Imported using git-ubuntu import.
- b9ff197... by ethan.hsieh
-
changelog for 1.2.10-1ubuntu3
- b1b9d7c... by ethan.hsieh
-
* Dropped changes:
- d/p/0001-Add-initial- support- for-MediaTek- mt8390- evk-and- mt83.patch
- replace it with patches accepted by upstream
* Added changes:
- d/p/0001-ucm2-MediaTek- mt8390- evk-Add- alsa-ucm- support. patch
- d/p/0002-ucm2-MediaTek- mt8395- evk-Add- alsa-ucm- support. patch
- d/p/0003-ucm2-MediaTek- mt8370- evk-Add- alsa-ucm- support. patch
- d/p/0001-ucm2-conf. d-mt8370- evk-Fix- the-type- of-mt8370- evk.co. patch
- d/p/0001-ucm-MediaTek- mt8395- evk-Add- HDMIRX- config. patch
- add supports for MediaTek mt8390-evk, mt8395-evk, and mt8370-evk.
- fix a file type issue on the mt8370-evk config
- add mt8395 HDMI RX support
(LP: #2051199) - 7988b7d... by Zhaoxuan Zhai
-
1.2.10-1ubuntu2 (patches unapplied)
Imported using git-ubuntu import.
- db64b2e... by Christian Ehrhardt
-
changelog: 1.2.10-1ubuntu1 merge and LP: #2042902 fix
Signed-off-by: Christian Ehrhardt <email address hidden>
- 5239251... by Christian Ehrhardt
-
added headers and background info to d/p/0001-
Add-initial- support- for-MediaTek- mt8390- evk-and- mt83.patch Signed-off-by: Christian Ehrhardt <email address hidden>
Preview Diff
1 | diff --git a/debian/changelog b/debian/changelog | |||
2 | index 1c4a2c0..9e3d9e3 100644 | |||
3 | --- a/debian/changelog | |||
4 | +++ b/debian/changelog | |||
5 | @@ -1,3 +1,4 @@ | |||
6 | 1 | <<<<<<< debian/changelog | ||
7 | 1 | alsa-ucm-conf (1.2.12-1) unstable; urgency=medium | 2 | alsa-ucm-conf (1.2.12-1) unstable; urgency=medium |
8 | 2 | 3 | ||
9 | 3 | * New upstream release. | 4 | * New upstream release. |
10 | @@ -19,6 +20,109 @@ alsa-ucm-conf (1.2.11-1) unstable; urgency=medium | |||
11 | 19 | * Update copyright years. | 20 | * Update copyright years. |
12 | 20 | 21 | ||
13 | 21 | -- Jordi Mallach <jordi@debian.org> Fri, 01 Mar 2024 11:28:05 +0100 | 22 | -- Jordi Mallach <jordi@debian.org> Fri, 01 Mar 2024 11:28:05 +0100 |
14 | 23 | ======= | ||
15 | 24 | alsa-ucm-conf (1.2.10-1ubuntu5.3) noble; urgency=medium | ||
16 | 25 | |||
17 | 26 | * Added patch to fix missing digital speaker on Dell Tarako (LP: #2088403) | ||
18 | 27 | - d/p/0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch | ||
19 | 28 | |||
20 | 29 | -- Chris Chiu <chris.chiu@canonical.com> Fri, 15 Nov 2024 17:02:01 +0800 | ||
21 | 30 | |||
22 | 31 | alsa-ucm-conf (1.2.10-1ubuntu5.2) noble; urgency=medium | ||
23 | 32 | |||
24 | 33 | * Added changes: | ||
25 | 34 | - d/p/0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch | ||
26 | 35 | - d/p/0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch | ||
27 | 36 | - d/p/0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch | ||
28 | 37 | - d/p/0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch | ||
29 | 38 | - d/p/0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch | ||
30 | 39 | - d/p/0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch | ||
31 | 40 | - d/p/0001-sof-soundwire-Change-map-control-names-to-make-them-.patch | ||
32 | 41 | - d/p/0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch | ||
33 | 42 | - Fix the regression on rt13xx which use only one file for speakers | ||
34 | 43 | - Add missing configuration for CS41L43+CS35L56 | ||
35 | 44 | - Fix control names for speakers/mic on CS42L43+CS35L56 | ||
36 | 45 | (LP: #2069760) | ||
37 | 46 | - d/p/0001-acppdmmach-add-support-for-ACP-7.0.patch | ||
38 | 47 | - Backport the support of AMD micmute LED of acppdmmach. | ||
39 | 48 | (LP: #2085067) | ||
40 | 49 | |||
41 | 50 | -- Chris Chiu <chris.chiu@canonical.com> Tue, 12 Nov 2024 10:26:07 +0800 | ||
42 | 51 | |||
43 | 52 | alsa-ucm-conf (1.2.10-1ubuntu5.1) noble; urgency=medium | ||
44 | 53 | |||
45 | 54 | * Added changes: | ||
46 | 55 | - d/p/0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch | ||
47 | 56 | - d/p/0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch | ||
48 | 57 | - d/p/0003-sof-soundwire-Add-basic-support-for-cs42l43.patch | ||
49 | 58 | - Soundwire support for CS42L43 and CS35L56 on Intel MTL | ||
50 | 59 | (LP: #2069760) | ||
51 | 60 | |||
52 | 61 | -- Chris Chiu <chris.chiu@canonical.com> Tue, 02 Jul 2024 22:32:17 +0800 | ||
53 | 62 | |||
54 | 63 | alsa-ucm-conf (1.2.10-1ubuntu5) noble; urgency=medium | ||
55 | 64 | |||
56 | 65 | * Actual rebuild against libasound2t64; the dependency is hardcoded. | ||
57 | 66 | |||
58 | 67 | -- Julian Andres Klode <juliank@ubuntu.com> Fri, 22 Mar 2024 17:09:13 +0100 | ||
59 | 68 | |||
60 | 69 | alsa-ucm-conf (1.2.10-1ubuntu4) noble; urgency=medium | ||
61 | 70 | |||
62 | 71 | * No-change rebuild against libasound2t64 | ||
63 | 72 | |||
64 | 73 | -- Steve Langasek <steve.langasek@ubuntu.com> Tue, 12 Mar 2024 06:28:57 +0000 | ||
65 | 74 | |||
66 | 75 | alsa-ucm-conf (1.2.10-1ubuntu3) noble; urgency=medium | ||
67 | 76 | |||
68 | 77 | * Dropped changes: | ||
69 | 78 | - d/p/0001-Add-initial-support-for-MediaTek-mt8390-evk-and-mt83.patch | ||
70 | 79 | - replace it with patches accepted by upstream | ||
71 | 80 | * Added changes: | ||
72 | 81 | - d/p/0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch | ||
73 | 82 | - d/p/0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch | ||
74 | 83 | - d/p/0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch | ||
75 | 84 | - d/p/0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch | ||
76 | 85 | - d/p/0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch | ||
77 | 86 | - add supports for MediaTek mt8390-evk, mt8395-evk, and mt8370-evk. | ||
78 | 87 | - fix a file type issue on the mt8370-evk config | ||
79 | 88 | - add mt8395 HDMI RX support | ||
80 | 89 | (LP: #2051199) | ||
81 | 90 | |||
82 | 91 | -- Ethan Hsieh <ethan.hsieh@canonical.com> Thu, 25 Jan 2024 13:29:18 +0800 | ||
83 | 92 | |||
84 | 93 | alsa-ucm-conf (1.2.10-1ubuntu2) noble; urgency=medium | ||
85 | 94 | |||
86 | 95 | * d/p/0001-Add-initial-support-for-MediaTek-Genio-boards.patch | ||
87 | 96 | - fix typo to make the patch work on mtk8390-evk (lp: #2049327) | ||
88 | 97 | |||
89 | 98 | -- Zhaoxuan Zhai <zhai.zhaoxuan@canonical.com> Tue, 16 Jan 2024 11:23:07 +0100 | ||
90 | 99 | |||
91 | 100 | alsa-ucm-conf (1.2.10-1ubuntu1) noble; urgency=medium | ||
92 | 101 | |||
93 | 102 | * Merge with Debian unstable. Remaining changes: | ||
94 | 103 | - d/p/0001-Add-initial-support-for-MediaTek-mt8390-evk-and-mt83.patch | ||
95 | 104 | - add initial support for MediaTek mt8390-evk and mt8395-evk | ||
96 | 105 | (LP: 2000228) | ||
97 | 106 | * Dropped changes [all in upstream 1.2.10]: | ||
98 | 107 | - d/p/0001-ucm2-Qualcomm-sc8280xp-fix-device-numbers.patch | ||
99 | 108 | - ucm2: Qualcomm: sc8280xp: fix device numbers | ||
100 | 109 | (LP: 2036731) | ||
101 | 110 | - d/p/0001-acp63-add-initial-support-for-AMD-Pink-Sardine-ACP63.patch | ||
102 | 111 | d/p/0002-acp63.conf-use-symbolic-link.patch | ||
103 | 112 | d/p/0003-acp62-add-initial-support-for-AMD-ACP-v6.2-RPL.patch | ||
104 | 113 | - Backport patches to add support AMD ACP RPL and Pink Sardine. | ||
105 | 114 | (LP: 2025353) | ||
106 | 115 | * Added changes | ||
107 | 116 | - added headers and background info to | ||
108 | 117 | d/p/0001-Add-initial-support-for-MediaTek-mt8390-evk-and-mt83.patch | ||
109 | 118 | |||
110 | 119 | [Artur Pak] | ||
111 | 120 | * d/p/0001-ucm2-soundwire-add-rt713-SDCA-device.patch: | ||
112 | 121 | - Backport patch to add rt713 SDCA device | ||
113 | 122 | (LP: #2042902) | ||
114 | 123 | |||
115 | 124 | -- Christian Ehrhardt <christian.ehrhardt@canonical.com> Fri, 24 Nov 2023 09:12:05 +0100 | ||
116 | 125 | >>>>>>> debian/changelog | ||
117 | 22 | 126 | ||
118 | 23 | alsa-ucm-conf (1.2.10-1) unstable; urgency=medium | 127 | alsa-ucm-conf (1.2.10-1) unstable; urgency=medium |
119 | 24 | 128 | ||
120 | @@ -26,6 +130,32 @@ alsa-ucm-conf (1.2.10-1) unstable; urgency=medium | |||
121 | 26 | 130 | ||
122 | 27 | -- Jordi Mallach <jordi@debian.org> Wed, 13 Sep 2023 01:12:05 +0200 | 131 | -- Jordi Mallach <jordi@debian.org> Wed, 13 Sep 2023 01:12:05 +0200 |
123 | 28 | 132 | ||
124 | 133 | alsa-ucm-conf (1.2.9-1ubuntu3) mantic; urgency=medium | ||
125 | 134 | |||
126 | 135 | * d/p/0001-ucm2-Qualcomm-sc8280xp-fix-device-numbers.patch | ||
127 | 136 | - ucm2: Qualcomm: sc8280xp: fix device numbers | ||
128 | 137 | (LP: #2036731) | ||
129 | 138 | |||
130 | 139 | -- Juerg Haefliger <juerg.haefliger@canonical.com> Wed, 20 Sep 2023 13:37:38 +0200 | ||
131 | 140 | |||
132 | 141 | alsa-ucm-conf (1.2.9-1ubuntu2) mantic; urgency=medium | ||
133 | 142 | |||
134 | 143 | * d/p/0001-Add-initial-support-for-MediaTek-mt8390-evk-and-mt83.patch | ||
135 | 144 | - add initial support for MediaTek mt8390-evk and mt8395-evk | ||
136 | 145 | (LP: #2000228) | ||
137 | 146 | |||
138 | 147 | -- Ethan Hsieh <ethan.hsieh@canonical.com> Mon, 18 Sep 2023 16:13:56 +0800 | ||
139 | 148 | |||
140 | 149 | alsa-ucm-conf (1.2.9-1ubuntu1) mantic; urgency=medium | ||
141 | 150 | |||
142 | 151 | * d/p/0001-acp63-add-initial-support-for-AMD-Pink-Sardine-ACP63.patch | ||
143 | 152 | d/p/0002-acp63.conf-use-symbolic-link.patch | ||
144 | 153 | d/p/0003-acp62-add-initial-support-for-AMD-ACP-v6.2-RPL.patch | ||
145 | 154 | - Backport patches to add support AMD ACP RPL and Pink Sardine. | ||
146 | 155 | (LP: #2025353) | ||
147 | 156 | |||
148 | 157 | -- Juerg Haefliger <juerg.haefliger@canonical.com> Thu, 06 Jul 2023 15:29:27 +0200 | ||
149 | 158 | |||
150 | 29 | alsa-ucm-conf (1.2.9-1) unstable; urgency=medium | 159 | alsa-ucm-conf (1.2.9-1) unstable; urgency=medium |
151 | 30 | 160 | ||
152 | 31 | * New upstream release. | 161 | * New upstream release. |
153 | diff --git a/debian/control b/debian/control | |||
154 | index 6e789bd..570ed57 100644 | |||
155 | --- a/debian/control | |||
156 | +++ b/debian/control | |||
157 | @@ -1,7 +1,8 @@ | |||
158 | 1 | Source: alsa-ucm-conf | 1 | Source: alsa-ucm-conf |
159 | 2 | Section: libs | 2 | Section: libs |
160 | 3 | Priority: optional | 3 | Priority: optional |
162 | 4 | Maintainer: Debian ALSA Maintainers <pkg-alsa-devel@lists.alioth.debian.org> | 4 | Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com> |
163 | 5 | XSBC-Original-Maintainer: Debian ALSA Maintainers <pkg-alsa-devel@lists.alioth.debian.org> | ||
164 | 5 | Uploaders: Jordi Mallach <jordi@debian.org>, | 6 | Uploaders: Jordi Mallach <jordi@debian.org>, |
165 | 6 | Elimar Riesebieter <riesebie@lxtec.de>, | 7 | Elimar Riesebieter <riesebie@lxtec.de>, |
166 | 7 | Luke Yelavich <themuso@ubuntu.com> | 8 | Luke Yelavich <themuso@ubuntu.com> |
167 | @@ -15,7 +16,11 @@ Rules-Requires-Root: no | |||
168 | 15 | Package: alsa-ucm-conf | 16 | Package: alsa-ucm-conf |
169 | 16 | Architecture: all | 17 | Architecture: all |
170 | 17 | Multi-Arch: foreign | 18 | Multi-Arch: foreign |
171 | 19 | <<<<<<< debian/control | ||
172 | 18 | Depends: ${misc:Depends}, libasound2t64 | 20 | Depends: ${misc:Depends}, libasound2t64 |
173 | 21 | ======= | ||
174 | 22 | Depends: ${misc:Depends}, libasound2t64 (>= 1.2.7) | ||
175 | 23 | >>>>>>> debian/control | ||
176 | 19 | Description: ALSA Use Case Manager configuration files | 24 | Description: ALSA Use Case Manager configuration files |
177 | 20 | This package contains ALSA Use Case Manager configuration of audio | 25 | This package contains ALSA Use Case Manager configuration of audio |
178 | 21 | input/output names and routing for specific audio hardware. They can be | 26 | input/output names and routing for specific audio hardware. They can be |
179 | diff --git a/debian/patches/0001-acppdmmach-add-support-for-ACP-7.0.patch b/debian/patches/0001-acppdmmach-add-support-for-ACP-7.0.patch | |||
180 | 22 | new file mode 100644 | 27 | new file mode 100644 |
181 | index 0000000..049497f | |||
182 | --- /dev/null | |||
183 | +++ b/debian/patches/0001-acppdmmach-add-support-for-ACP-7.0.patch | |||
184 | @@ -0,0 +1,37 @@ | |||
185 | 1 | From b2358f24a93d5a07b5bf7c35f0d76676dc85869c Mon Sep 17 00:00:00 2001 | ||
186 | 2 | From: Mario Limonciello <mario.limonciello@amd.com> | ||
187 | 3 | Date: Thu, 17 Oct 2024 11:44:20 -0500 | ||
188 | 4 | Subject: [PATCH] acppdmmach: add support for ACP 7.0 | ||
189 | 5 | |||
190 | 6 | Starting with ACP 7.0 there is a generic 'acppdmmach' driver that | ||
191 | 7 | will be utilized. | ||
192 | 8 | |||
193 | 9 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/452 | ||
194 | 10 | Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> | ||
195 | 11 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
196 | 12 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/b2358f24a93d5a07b5bf7c35f0d76676dc85869c | ||
197 | 13 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2085067 | ||
198 | 14 | Signed-off-by: Aaron Ma <aaron.ma@canonical.com> | ||
199 | 15 | --- | ||
200 | 16 | ucm2/HDA/HDA.conf | 2 +- | ||
201 | 17 | ucm2/conf.d/acp-pdm-mach/acp-pdm-mach.conf | 1 + | ||
202 | 18 | 2 files changed, 2 insertions(+), 1 deletion(-) | ||
203 | 19 | create mode 120000 ucm2/conf.d/acp-pdm-mach/acp-pdm-mach.conf | ||
204 | 20 | |||
205 | 21 | --- a/ucm2/HDA/HDA.conf | ||
206 | 22 | +++ b/ucm2/HDA/HDA.conf | ||
207 | 23 | @@ -3,7 +3,7 @@ | ||
208 | 24 | Define.Use "" # a non-empty string to use UCM configuration for HDA devices | ||
209 | 25 | Define.Done "" # a non-empty string to skip the end error | ||
210 | 26 | |||
211 | 27 | -Define.AcpCardId "$${find-card:field=name,return=id,regex='^acp(|6[23x])$'}" | ||
212 | 28 | +Define.AcpCardId "$${find-card:field=name,return=id,regex='^acp(|6[23x]|-pdm-mach)$'}" | ||
213 | 29 | Define.DeviceMic "Mic" | ||
214 | 30 | |||
215 | 31 | If.dualcodec { | ||
216 | 32 | --- /dev/null | ||
217 | 33 | +++ b/ucm2/conf.d/acp-pdm-mach/acp-pdm-mach.conf | ||
218 | 34 | @@ -0,0 +1,3 @@ | ||
219 | 35 | +Syntax 3 | ||
220 | 36 | + | ||
221 | 37 | +Include.linked.File "/common/linked.conf" | ||
222 | diff --git a/debian/patches/0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch b/debian/patches/0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch | |||
223 | 0 | new file mode 100644 | 38 | new file mode 100644 |
224 | index 0000000..bbbbe4c | |||
225 | --- /dev/null | |||
226 | +++ b/debian/patches/0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch | |||
227 | @@ -0,0 +1,46 @@ | |||
228 | 1 | From: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
229 | 2 | Date: Tue, 23 Apr 2024 16:43:05 +0100 | ||
230 | 3 | Subject: [PATCH] sof-soundwire: Add basic support for cs42l43's speaker | ||
231 | 4 | |||
232 | 5 | Previous support was added for the mics and headset on cs42l43, expand | ||
233 | 6 | this support with additional configuration for the speaker output. | ||
234 | 7 | |||
235 | 8 | Link: https://lore.kernel.org/alsa-devel/20240423154305.2782347-1-ckeepax@opensource.cirrus.com/ | ||
236 | 9 | Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
237 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
238 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/035d9206cffdf7942352d2daf3c34dde491c01dc.patch | ||
239 | 12 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2088403 | ||
240 | 13 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
241 | 14 | --- | ||
242 | 15 | ucm2/sof-soundwire/cs42l43-spk.conf | 25 +++++++++++++++++++++++++ | ||
243 | 16 | 1 file changed, 25 insertions(+) | ||
244 | 17 | create mode 100644 ucm2/sof-soundwire/cs42l43-spk.conf | ||
245 | 18 | |||
246 | 19 | --- /dev/null | ||
247 | 20 | +++ b/ucm2/sof-soundwire/cs42l43-spk.conf | ||
248 | 21 | @@ -0,0 +1,25 @@ | ||
249 | 22 | +# Use case Configuration for sof-soundwire card | ||
250 | 23 | + | ||
251 | 24 | +SectionDevice."Speaker" { | ||
252 | 25 | + Comment "Speaker" | ||
253 | 26 | + | ||
254 | 27 | + ConflictingDevice [ | ||
255 | 28 | + "Headphones" | ||
256 | 29 | + ] | ||
257 | 30 | + | ||
258 | 31 | + EnableSequence [ | ||
259 | 32 | + cset "name='cs42l43 Speaker L Input 1' 'DP5RX1'" | ||
260 | 33 | + cset "name='cs42l43 Speaker R Input 1' 'DP5RX2'" | ||
261 | 34 | + ] | ||
262 | 35 | + | ||
263 | 36 | + DisableSequence [ | ||
264 | 37 | + cset "name='cs42l43 Speaker L Input 1' 'None'" | ||
265 | 38 | + cset "name='cs42l43 Speaker R Input 1' 'None'" | ||
266 | 39 | + ] | ||
267 | 40 | + | ||
268 | 41 | + Value { | ||
269 | 42 | + PlaybackPriority 100 | ||
270 | 43 | + PlaybackPCM "hw:${CardId},0" | ||
271 | 44 | + PlaybackMixerElem "cs42l43 Speaker Digital" | ||
272 | 45 | + } | ||
273 | 46 | +} | ||
274 | diff --git a/debian/patches/0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch b/debian/patches/0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch | |||
275 | 0 | new file mode 100644 | 47 | new file mode 100644 |
276 | index 0000000..ebfe89a | |||
277 | --- /dev/null | |||
278 | +++ b/debian/patches/0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch | |||
279 | @@ -0,0 +1,28 @@ | |||
280 | 1 | From: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
281 | 2 | Date: Mon, 8 Jul 2024 12:59:18 +0100 | ||
282 | 3 | Subject: sof-soundwire: Add missing match for cs42l43 speakers | ||
283 | 4 | |||
284 | 5 | The cs42l43 reports as cs42l43-spk in the speaker case, the regex in | ||
285 | 6 | sof-soundwire needs updated to recognise that. | ||
286 | 7 | |||
287 | 8 | Fixes: 035d9206cffd ("sof-soundwire: Add basic support for cs42l43's speaker") | ||
288 | 9 | Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
289 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
290 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/d8aea84bebaae416c530a2d448f5e3758809c09f | ||
291 | 12 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
292 | 13 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
293 | 14 | --- | ||
294 | 15 | ucm2/sof-soundwire/sof-soundwire.conf | 2 +- | ||
295 | 16 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
296 | 17 | |||
297 | 18 | --- a/ucm2/sof-soundwire/sof-soundwire.conf | ||
298 | 19 | +++ b/ucm2/sof-soundwire/sof-soundwire.conf | ||
299 | 20 | @@ -19,7 +19,7 @@ | ||
300 | 21 | |||
301 | 22 | DefineRegex { | ||
302 | 23 | SpeakerCodec { | ||
303 | 24 | - Regex " spk:([a-z0-9]+(-sdca)?)" | ||
304 | 25 | + Regex " spk:([a-z0-9]+((-sdca)|(-spk))?)" | ||
305 | 26 | String "${CardComponents}" | ||
306 | 27 | } | ||
307 | 28 | SpeakerChannels { | ||
308 | diff --git a/debian/patches/0001-sof-soundwire-Change-map-control-names-to-make-them-.patch b/debian/patches/0001-sof-soundwire-Change-map-control-names-to-make-them-.patch | |||
309 | 0 | new file mode 100644 | 29 | new file mode 100644 |
310 | index 0000000..7b89176 | |||
311 | --- /dev/null | |||
312 | +++ b/debian/patches/0001-sof-soundwire-Change-map-control-names-to-make-them-.patch | |||
313 | @@ -0,0 +1,93 @@ | |||
314 | 1 | From: Maciej Strozek <mstrozek@opensource.cirrus.com> | ||
315 | 2 | Date: Thu, 17 Oct 2024 13:20:26 +0100 | ||
316 | 3 | Subject: sof-soundwire: Change map control names to make them unique and user | ||
317 | 4 | friendly | ||
318 | 5 | |||
319 | 6 | Both 'Speaker Digital' and 'cs42l43 PDM2' names were found in other alsa | ||
320 | 7 | controls, confusing the MixerElems paths. Make them unique to avoid errors for | ||
321 | 8 | hardware mutes. Also add 'Capture' string into microphone controls to make | ||
322 | 9 | them work properly. | ||
323 | 10 | |||
324 | 11 | Link: https://lore.kernel.org/alsa-devel/20241017122027.1207373-1-mstrozek@opensource.cirrus.com/ | ||
325 | 12 | Signed-off-by: Maciej Strozek <mstrozek@opensource.cirrus.com> | ||
326 | 13 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
327 | 14 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/9864d624b27e3779d958138561e48f59287a124a | ||
328 | 15 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
329 | 16 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
330 | 17 | --- | ||
331 | 18 | ucm2/codecs/cs42l43/init.conf | 10 ++++++++-- | ||
332 | 19 | ucm2/sof-soundwire/cs35l56-bridge.conf | 6 +++--- | ||
333 | 20 | ucm2/sof-soundwire/cs42l43-dmic.conf | 2 +- | ||
334 | 21 | ucm2/sof-soundwire/cs42l43.conf | 3 ++- | ||
335 | 22 | 4 files changed, 14 insertions(+), 7 deletions(-) | ||
336 | 23 | |||
337 | 24 | --- a/ucm2/codecs/cs42l43/init.conf | ||
338 | 25 | +++ b/ucm2/codecs/cs42l43/init.conf | ||
339 | 26 | @@ -2,13 +2,19 @@ | ||
340 | 27 | |||
341 | 28 | LibraryConfig.remap.Config { | ||
342 | 29 | ctl.default.map { | ||
343 | 30 | - "name='cs42l43 PDM2 Switch'" { | ||
344 | 31 | + "name='cs42l43 Microphone Capture Switch'" { | ||
345 | 32 | "name='cs42l43 Decimator 3 Switch'".vindex.0 0 | ||
346 | 33 | "name='cs42l43 Decimator 4 Switch'".vindex.1 0 | ||
347 | 34 | } | ||
348 | 35 | - "name='cs42l43 PDM2 Volume'" { | ||
349 | 36 | + "name='cs42l43 Microphone Capture Volume'" { | ||
350 | 37 | "name='cs42l43 Decimator 3 Volume'".vindex.0 0 | ||
351 | 38 | "name='cs42l43 Decimator 4 Volume'".vindex.1 0 | ||
352 | 39 | } | ||
353 | 40 | + "name='cs42l43 Headset Microphone Capture Switch'" { | ||
354 | 41 | + "name='cs42l43 Decimator 1 Switch'".vindex.0 0 | ||
355 | 42 | + } | ||
356 | 43 | + "name='cs42l43 Headset Microphone Capture Volume'" { | ||
357 | 44 | + "name='cs42l43 Decimator 1 Volume'".vindex.0 0 | ||
358 | 45 | + } | ||
359 | 46 | } | ||
360 | 47 | } | ||
361 | 48 | --- a/ucm2/sof-soundwire/cs35l56-bridge.conf | ||
362 | 49 | +++ b/ucm2/sof-soundwire/cs35l56-bridge.conf | ||
363 | 50 | @@ -2,11 +2,11 @@ | ||
364 | 51 | |||
365 | 52 | LibraryConfig.remap.Config { | ||
366 | 53 | ctl.default.map { | ||
367 | 54 | - "name='Speaker Digital Switch'" { | ||
368 | 55 | + "name='Speaker Playback Switch'" { | ||
369 | 56 | "name='AMPL Speaker Switch'".vindex.0 0 | ||
370 | 57 | "name='AMPR Speaker Switch'".vindex.1 0 | ||
371 | 58 | } | ||
372 | 59 | - "name='Speaker Digital Volume'" { | ||
373 | 60 | + "name='Speaker Playback Volume'" { | ||
374 | 61 | "name='AMPL Speaker Volume'".vindex.0 0 | ||
375 | 62 | "name='AMPR Speaker Volume'".vindex.1 0 | ||
376 | 63 | } | ||
377 | 64 | @@ -56,6 +56,6 @@ | ||
378 | 65 | PlaybackPriority 100 | ||
379 | 66 | PlaybackPCM "hw:${CardId},0" | ||
380 | 67 | PlaybackMixer "default:${CardId}" | ||
381 | 68 | - PlaybackMixerElem "Speaker Digital" | ||
382 | 69 | + PlaybackMixerElem "Speaker" | ||
383 | 70 | } | ||
384 | 71 | } | ||
385 | 72 | --- a/ucm2/sof-soundwire/cs42l43-dmic.conf | ||
386 | 73 | +++ b/ucm2/sof-soundwire/cs42l43-dmic.conf | ||
387 | 74 | @@ -21,6 +21,6 @@ | ||
388 | 75 | CapturePriority 100 | ||
389 | 76 | CapturePCM "hw:${CardId},4" | ||
390 | 77 | CaptureMixer "default:${CardId}" | ||
391 | 78 | - CaptureMixerElem "cs42l43 PDM2" | ||
392 | 79 | + CaptureMixerElem "cs42l43 Microphone" | ||
393 | 80 | } | ||
394 | 81 | } | ||
395 | 82 | --- a/ucm2/sof-soundwire/cs42l43.conf | ||
396 | 83 | +++ b/ucm2/sof-soundwire/cs42l43.conf | ||
397 | 84 | @@ -40,7 +40,8 @@ | ||
398 | 85 | Value { | ||
399 | 86 | CapturePriority 200 | ||
400 | 87 | CapturePCM "hw:${CardId},4" | ||
401 | 88 | - CaptureMixerElem "cs42l43 Decimator 1" | ||
402 | 89 | + CaptureMixer "default:${CardId}" | ||
403 | 90 | + CaptureMixerElem "cs42l43 Headset Microphone" | ||
404 | 91 | JackControl "Headset Mic Jack" | ||
405 | 92 | } | ||
406 | 93 | } | ||
407 | diff --git a/debian/patches/0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch b/debian/patches/0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch | |||
408 | 0 | new file mode 100644 | 94 | new file mode 100644 |
409 | index 0000000..f37f067 | |||
410 | --- /dev/null | |||
411 | +++ b/debian/patches/0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch | |||
412 | @@ -0,0 +1,415 @@ | |||
413 | 1 | From: Jaroslav Kysela <perex@perex.cz> | ||
414 | 2 | Date: Wed, 6 Dec 2023 15:53:38 +0100 | ||
415 | 3 | Subject: [PATCH 1/3] sof-soundwire: Use one file for speaker codec | ||
416 | 4 | initialization | ||
417 | 5 | |||
418 | 6 | Use macros to minimize configuration blocks. | ||
419 | 7 | |||
420 | 8 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
421 | 9 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/c0a4df6037860b4e1dffb497e5a28258a351a0f8 | ||
422 | 10 | Bug: https://github.com/alsa-project/alsa-ucm-conf/pull/370 | ||
423 | 11 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
424 | 12 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
425 | 13 | --- | ||
426 | 14 | ucm2/sof-soundwire/HiFi.conf | 2 +- | ||
427 | 15 | ucm2/sof-soundwire/rt1308-1.conf | 22 -------------- | ||
428 | 16 | ucm2/sof-soundwire/rt1308-2.conf | 29 ------------------ | ||
429 | 17 | ucm2/sof-soundwire/rt1308.conf | 46 ++++++++++++++++++++++++++++ | ||
430 | 18 | ucm2/sof-soundwire/rt1316-1.conf | 41 ------------------------- | ||
431 | 19 | ucm2/sof-soundwire/rt1316-2.conf | 51 ------------------------------- | ||
432 | 20 | ucm2/sof-soundwire/rt1316.conf | 65 ++++++++++++++++++++++++++++++++++++++++ | ||
433 | 21 | ucm2/sof-soundwire/rt1318-1.conf | 20 ------------- | ||
434 | 22 | ucm2/sof-soundwire/rt1318-2.conf | 25 ---------------- | ||
435 | 23 | ucm2/sof-soundwire/rt1318.conf | 44 +++++++++++++++++++++++++++ | ||
436 | 24 | 10 files changed, 156 insertions(+), 189 deletions(-) | ||
437 | 25 | delete mode 100644 ucm2/sof-soundwire/rt1308-1.conf | ||
438 | 26 | delete mode 100644 ucm2/sof-soundwire/rt1308-2.conf | ||
439 | 27 | create mode 100644 ucm2/sof-soundwire/rt1308.conf | ||
440 | 28 | delete mode 100644 ucm2/sof-soundwire/rt1316-1.conf | ||
441 | 29 | delete mode 100644 ucm2/sof-soundwire/rt1316-2.conf | ||
442 | 30 | create mode 100644 ucm2/sof-soundwire/rt1316.conf | ||
443 | 31 | delete mode 100644 ucm2/sof-soundwire/rt1318-1.conf | ||
444 | 32 | delete mode 100644 ucm2/sof-soundwire/rt1318-2.conf | ||
445 | 33 | create mode 100644 ucm2/sof-soundwire/rt1318.conf | ||
446 | 34 | |||
447 | 35 | --- a/ucm2/sof-soundwire/HiFi.conf | ||
448 | 36 | +++ b/ucm2/sof-soundwire/HiFi.conf | ||
449 | 37 | @@ -13,7 +13,7 @@ | ||
450 | 38 | Type String | ||
451 | 39 | Empty "${var:SpeakerCodec1}" | ||
452 | 40 | } | ||
453 | 41 | - False.Include.spkdev.File "/sof-soundwire/${var:SpeakerCodec1}-${var:SpeakerAmps1}.conf" | ||
454 | 42 | + False.Include.spkdev.File "/sof-soundwire/${var:SpeakerCodec1}.conf" | ||
455 | 43 | } | ||
456 | 44 | |||
457 | 45 | If.micdev { | ||
458 | 46 | --- a/ucm2/sof-soundwire/rt1308-1.conf | ||
459 | 47 | +++ /dev/null | ||
460 | 48 | @@ -1,22 +0,0 @@ | ||
461 | 49 | -# Use case Configuration for sof-soundwire card | ||
462 | 50 | - | ||
463 | 51 | -SectionDevice."Speaker" { | ||
464 | 52 | - Comment "Speaker" | ||
465 | 53 | - | ||
466 | 54 | - EnableSequence [ | ||
467 | 55 | - cset "name='rt1308-1 DAC L Switch' 1" | ||
468 | 56 | - cset "name='rt1308-1 DAC R Switch' 1" | ||
469 | 57 | - cset "name='Speaker Switch' on" | ||
470 | 58 | - ] | ||
471 | 59 | - | ||
472 | 60 | - DisableSequence [ | ||
473 | 61 | - cset "name='rt1308-1 DAC L Switch' 0" | ||
474 | 62 | - cset "name='rt1308-1 DAC R Switch' 0" | ||
475 | 63 | - cset "name='Speaker Switch' off" | ||
476 | 64 | - ] | ||
477 | 65 | - | ||
478 | 66 | - Value { | ||
479 | 67 | - PlaybackPriority 100 | ||
480 | 68 | - PlaybackPCM "hw:${CardId},2" | ||
481 | 69 | - } | ||
482 | 70 | -} | ||
483 | 71 | --- a/ucm2/sof-soundwire/rt1308-2.conf | ||
484 | 72 | +++ /dev/null | ||
485 | 73 | @@ -1,29 +0,0 @@ | ||
486 | 74 | -# Use case Configuration for sof-soundwire card | ||
487 | 75 | - | ||
488 | 76 | -SectionDevice."Speaker" { | ||
489 | 77 | - Comment "Speaker" | ||
490 | 78 | - | ||
491 | 79 | - EnableSequence [ | ||
492 | 80 | - cset "name='rt1308-1 RX Channel Select' LL" | ||
493 | 81 | - cset "name='rt1308-2 RX Channel Select' RR" | ||
494 | 82 | - | ||
495 | 83 | - cset "name='rt1308-1 DAC L Switch' 1" | ||
496 | 84 | - cset "name='rt1308-1 DAC R Switch' 1" | ||
497 | 85 | - cset "name='rt1308-2 DAC L Switch' 1" | ||
498 | 86 | - cset "name='rt1308-2 DAC R Switch' 1" | ||
499 | 87 | - cset "name='Speaker Switch' on" | ||
500 | 88 | - ] | ||
501 | 89 | - | ||
502 | 90 | - DisableSequence [ | ||
503 | 91 | - cset "name='rt1308-1 DAC L Switch' 0" | ||
504 | 92 | - cset "name='rt1308-1 DAC R Switch' 0" | ||
505 | 93 | - cset "name='rt1308-2 DAC L Switch' 0" | ||
506 | 94 | - cset "name='rt1308-2 DAC R Switch' 0" | ||
507 | 95 | - cset "name='Speaker Switch' off" | ||
508 | 96 | - ] | ||
509 | 97 | - | ||
510 | 98 | - Value { | ||
511 | 99 | - PlaybackPriority 100 | ||
512 | 100 | - PlaybackPCM "hw:${CardId},2" | ||
513 | 101 | - } | ||
514 | 102 | -} | ||
515 | 103 | --- /dev/null | ||
516 | 104 | +++ b/ucm2/sof-soundwire/rt1308.conf | ||
517 | 105 | @@ -0,0 +1,46 @@ | ||
518 | 106 | +# Use case Configuration for sof-soundwire card | ||
519 | 107 | + | ||
520 | 108 | +# | ||
521 | 109 | +# Arguments: | ||
522 | 110 | +# ForAmps - regex filter for var:SpeakerAmps | ||
523 | 111 | +# Amp - amplifier number (1,2 etc.) | ||
524 | 112 | +# Sel - channel selection (LR LL RL RR) | ||
525 | 113 | +# | ||
526 | 114 | +DefineMacro.rt1308spk.If.0 { | ||
527 | 115 | + Condition { | ||
528 | 116 | + Type RegexMatch | ||
529 | 117 | + Regex "${var:__ForAmps}" | ||
530 | 118 | + String "${var:SpeakerAmps}" | ||
531 | 119 | + } | ||
532 | 120 | + True { | ||
533 | 121 | + EnableSequence [ | ||
534 | 122 | + cset "name='rt1308-${var:__Amp} RX Channel Select' ${var:__Sel}" | ||
535 | 123 | + cset "name='rt1308-${var:__Amp} DAC L Switch' 1" | ||
536 | 124 | + cset "name='rt1308-${var:__Amp} DAC R Switch' 1" | ||
537 | 125 | + ] | ||
538 | 126 | + DisableSequence [ | ||
539 | 127 | + cset "name='rt1308-${var:__Amp} DAC L Switch' 0" | ||
540 | 128 | + cset "name='rt1308-${var:__Amp} DAC R Switch' 0" | ||
541 | 129 | + ] | ||
542 | 130 | + } | ||
543 | 131 | +} | ||
544 | 132 | + | ||
545 | 133 | +SectionDevice."Speaker" { | ||
546 | 134 | + Comment "Speaker" | ||
547 | 135 | + | ||
548 | 136 | + Macro.num1.rt1308spk { ForAmps "[12]" Amp 1 Sel LL } | ||
549 | 137 | + Macro.num2.rt1308spk { ForAmps "2" Amp 2 Sel RR } | ||
550 | 138 | + | ||
551 | 139 | + EnableSequence [ | ||
552 | 140 | + cset "name='Speaker Switch' on" | ||
553 | 141 | + ] | ||
554 | 142 | + | ||
555 | 143 | + DisableSequence [ | ||
556 | 144 | + cset "name='Speaker Switch' off" | ||
557 | 145 | + ] | ||
558 | 146 | + | ||
559 | 147 | + Value { | ||
560 | 148 | + PlaybackPriority 100 | ||
561 | 149 | + PlaybackPCM "hw:${CardId},2" | ||
562 | 150 | + } | ||
563 | 151 | +} | ||
564 | 152 | --- a/ucm2/sof-soundwire/rt1316-1.conf | ||
565 | 153 | +++ /dev/null | ||
566 | 154 | @@ -1,41 +0,0 @@ | ||
567 | 155 | -# Use case Configuration for sof-soundwire card | ||
568 | 156 | - | ||
569 | 157 | -SectionDevice."Speaker" { | ||
570 | 158 | - Comment "Speaker" | ||
571 | 159 | - | ||
572 | 160 | - If.lrswitch { | ||
573 | 161 | - Condition { | ||
574 | 162 | - Type ControlExists | ||
575 | 163 | - Control "name='rt1316-1 DAC L Switch'" | ||
576 | 164 | - } | ||
577 | 165 | - True { | ||
578 | 166 | - EnableSequence [ | ||
579 | 167 | - cset "name='rt1316-1 DAC L Switch' 1" | ||
580 | 168 | - cset "name='rt1316-1 DAC R Switch' 1" | ||
581 | 169 | - cset "name='Speaker Switch' on" | ||
582 | 170 | - ] | ||
583 | 171 | - | ||
584 | 172 | - DisableSequence [ | ||
585 | 173 | - cset "name='rt1316-1 DAC L Switch' 0" | ||
586 | 174 | - cset "name='rt1316-1 DAC R Switch' 0" | ||
587 | 175 | - cset "name='Speaker Switch' off" | ||
588 | 176 | - ] | ||
589 | 177 | - } | ||
590 | 178 | - False { | ||
591 | 179 | - EnableSequence [ | ||
592 | 180 | - cset "name='rt1316-1 DAC Switch' 1" | ||
593 | 181 | - cset "name='Speaker Switch' on" | ||
594 | 182 | - ] | ||
595 | 183 | - | ||
596 | 184 | - DisableSequence [ | ||
597 | 185 | - cset "name='rt1316-1 DAC Switch' 0" | ||
598 | 186 | - cset "name='Speaker Switch' off" | ||
599 | 187 | - ] | ||
600 | 188 | - } | ||
601 | 189 | - } | ||
602 | 190 | - | ||
603 | 191 | - Value { | ||
604 | 192 | - PlaybackPriority 100 | ||
605 | 193 | - PlaybackPCM "hw:${CardId},2" | ||
606 | 194 | - } | ||
607 | 195 | -} | ||
608 | 196 | --- a/ucm2/sof-soundwire/rt1316-2.conf | ||
609 | 197 | +++ /dev/null | ||
610 | 198 | @@ -1,51 +0,0 @@ | ||
611 | 199 | -# Use case Configuration for sof-soundwire card | ||
612 | 200 | - | ||
613 | 201 | -SectionDevice."Speaker" { | ||
614 | 202 | - Comment "Speaker" | ||
615 | 203 | - | ||
616 | 204 | - If.lrswitch { | ||
617 | 205 | - Condition { | ||
618 | 206 | - Type ControlExists | ||
619 | 207 | - Control "name='rt1316-1 DAC L Switch'" | ||
620 | 208 | - } | ||
621 | 209 | - True { | ||
622 | 210 | - EnableSequence [ | ||
623 | 211 | - cset "name='rt1316-1 RX Channel Select' L,L" | ||
624 | 212 | - cset "name='rt1316-2 RX Channel Select' R,R" | ||
625 | 213 | - cset "name='rt1316-1 DAC L Switch' 1" | ||
626 | 214 | - cset "name='rt1316-1 DAC R Switch' 1" | ||
627 | 215 | - cset "name='rt1316-2 DAC L Switch' 1" | ||
628 | 216 | - cset "name='rt1316-2 DAC R Switch' 1" | ||
629 | 217 | - cset "name='Speaker Switch' on" | ||
630 | 218 | - ] | ||
631 | 219 | - | ||
632 | 220 | - DisableSequence [ | ||
633 | 221 | - cset "name='rt1316-1 DAC L Switch' 0" | ||
634 | 222 | - cset "name='rt1316-1 DAC R Switch' 0" | ||
635 | 223 | - cset "name='rt1316-2 DAC L Switch' 0" | ||
636 | 224 | - cset "name='rt1316-2 DAC R Switch' 0" | ||
637 | 225 | - cset "name='Speaker Switch' off" | ||
638 | 226 | - ] | ||
639 | 227 | - } | ||
640 | 228 | - False { | ||
641 | 229 | - EnableSequence [ | ||
642 | 230 | - cset "name='rt1316-1 RX Channel Select' L,L" | ||
643 | 231 | - cset "name='rt1316-2 RX Channel Select' R,R" | ||
644 | 232 | - cset "name='rt1316-1 DAC Switch' 1" | ||
645 | 233 | - cset "name='rt1316-2 DAC Switch' 1" | ||
646 | 234 | - cset "name='Speaker Switch' on" | ||
647 | 235 | - ] | ||
648 | 236 | - | ||
649 | 237 | - DisableSequence [ | ||
650 | 238 | - cset "name='rt1316-1 DAC Switch' 0" | ||
651 | 239 | - cset "name='rt1316-2 DAC Switch' 0" | ||
652 | 240 | - cset "name='Speaker Switch' off" | ||
653 | 241 | - ] | ||
654 | 242 | - } | ||
655 | 243 | - } | ||
656 | 244 | - | ||
657 | 245 | - Value { | ||
658 | 246 | - PlaybackPriority 100 | ||
659 | 247 | - PlaybackPCM "hw:${CardId},2" | ||
660 | 248 | - } | ||
661 | 249 | -} | ||
662 | 250 | --- /dev/null | ||
663 | 251 | +++ b/ucm2/sof-soundwire/rt1316.conf | ||
664 | 252 | @@ -0,0 +1,65 @@ | ||
665 | 253 | +# Use case Configuration for sof-soundwire card | ||
666 | 254 | + | ||
667 | 255 | +# | ||
668 | 256 | +# Arguments: | ||
669 | 257 | +# ForAmps - regex filter for var:SpeakerAmps | ||
670 | 258 | +# Amp - amplifier number (1,2 etc.) | ||
671 | 259 | +# Sel - channel selection (L,R L,L L,R L,L+R R,L R,R R,L+R L+R,L L+R,R L+R,L+R) | ||
672 | 260 | +# | ||
673 | 261 | +DefineMacro.rt1316spk.If.0 { | ||
674 | 262 | + Condition { | ||
675 | 263 | + Type RegexMatch | ||
676 | 264 | + Regex "${var:__ForAmps}" | ||
677 | 265 | + String "${var:SpeakerAmps}" | ||
678 | 266 | + } | ||
679 | 267 | + True { | ||
680 | 268 | + EnableSequence [ | ||
681 | 269 | + cset "name='rt1316-${var:__Amp} RX Channel Select' ${var:__Sel}" | ||
682 | 270 | + ] | ||
683 | 271 | + If.lrswitch { | ||
684 | 272 | + Condition { | ||
685 | 273 | + Type ControlExists | ||
686 | 274 | + Control "name='rt1316-${var:__Amp} DAC L Switch'" | ||
687 | 275 | + } | ||
688 | 276 | + True { | ||
689 | 277 | + EnableSequence [ | ||
690 | 278 | + cset "name='rt1316-${var:__Amp} DAC L Switch' 1" | ||
691 | 279 | + cset "name='rt1316-${var:__Amp} DAC R Switch' 1" | ||
692 | 280 | + ] | ||
693 | 281 | + DisableSequence [ | ||
694 | 282 | + cset "name='rt1316-${var:__Amp} DAC L Switch' 0" | ||
695 | 283 | + cset "name='rt1316-${var:__Amp} DAC R Switch' 0" | ||
696 | 284 | + ] | ||
697 | 285 | + } | ||
698 | 286 | + False { | ||
699 | 287 | + EnableSequence [ | ||
700 | 288 | + cset "name='rt1316-${var:__Amp} DAC Switch' 1" | ||
701 | 289 | + ] | ||
702 | 290 | + | ||
703 | 291 | + DisableSequence [ | ||
704 | 292 | + cset "name='rt1316-${var:__Amp} DAC Switch' 0" | ||
705 | 293 | + ] | ||
706 | 294 | + } | ||
707 | 295 | + } | ||
708 | 296 | + } | ||
709 | 297 | +} | ||
710 | 298 | + | ||
711 | 299 | +SectionDevice."Speaker" { | ||
712 | 300 | + Comment "Speaker" | ||
713 | 301 | + | ||
714 | 302 | + Macro.num1.rt1316spk { ForAmps "[12]" Amp 1 Sel "L,L" } | ||
715 | 303 | + Macro.num2.rt1316spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
716 | 304 | + | ||
717 | 305 | + EnableSequence [ | ||
718 | 306 | + cset "name='Speaker Switch' on" | ||
719 | 307 | + ] | ||
720 | 308 | + | ||
721 | 309 | + DisableSequence [ | ||
722 | 310 | + cset "name='Speaker Switch' off" | ||
723 | 311 | + ] | ||
724 | 312 | + | ||
725 | 313 | + Value { | ||
726 | 314 | + PlaybackPriority 100 | ||
727 | 315 | + PlaybackPCM "hw:${CardId},2" | ||
728 | 316 | + } | ||
729 | 317 | +} | ||
730 | 318 | --- a/ucm2/sof-soundwire/rt1318-1.conf | ||
731 | 319 | +++ /dev/null | ||
732 | 320 | @@ -1,20 +0,0 @@ | ||
733 | 321 | -# Use case Configuration for sof-soundwire card | ||
734 | 322 | - | ||
735 | 323 | -SectionDevice."Speaker" { | ||
736 | 324 | - Comment "Speaker" | ||
737 | 325 | - | ||
738 | 326 | - EnableSequence [ | ||
739 | 327 | - cset "name='rt1318-1 DAC Switch' 1" | ||
740 | 328 | - cset "name='Speaker Switch' on" | ||
741 | 329 | - ] | ||
742 | 330 | - | ||
743 | 331 | - DisableSequence [ | ||
744 | 332 | - cset "name='rt1318-1 DAC Switch' 0" | ||
745 | 333 | - cset "name='Speaker Switch' off" | ||
746 | 334 | - ] | ||
747 | 335 | - | ||
748 | 336 | - Value { | ||
749 | 337 | - PlaybackPriority 100 | ||
750 | 338 | - PlaybackPCM "hw:${CardId},2" | ||
751 | 339 | - } | ||
752 | 340 | -} | ||
753 | 341 | --- a/ucm2/sof-soundwire/rt1318-2.conf | ||
754 | 342 | +++ /dev/null | ||
755 | 343 | @@ -1,25 +0,0 @@ | ||
756 | 344 | -# Use case Configuration for sof-soundwire card | ||
757 | 345 | - | ||
758 | 346 | -SectionDevice."Speaker" { | ||
759 | 347 | - Comment "Speaker" | ||
760 | 348 | - | ||
761 | 349 | - EnableSequence [ | ||
762 | 350 | - cset "name='rt1318-1 RX Channel Select' L,L" | ||
763 | 351 | - cset "name='rt1318-2 RX Channel Select' R,R" | ||
764 | 352 | - | ||
765 | 353 | - cset "name='rt1318-1 DAC Switch' 1" | ||
766 | 354 | - cset "name='rt1318-2 DAC Switch' 1" | ||
767 | 355 | - cset "name='Speaker Switch' on" | ||
768 | 356 | - ] | ||
769 | 357 | - | ||
770 | 358 | - DisableSequence [ | ||
771 | 359 | - cset "name='rt1318-1 DAC Switch' 0" | ||
772 | 360 | - cset "name='rt1318-2 DAC Switch' 0" | ||
773 | 361 | - cset "name='Speaker Switch' off" | ||
774 | 362 | - ] | ||
775 | 363 | - | ||
776 | 364 | - Value { | ||
777 | 365 | - PlaybackPriority 100 | ||
778 | 366 | - PlaybackPCM "hw:${CardId},2" | ||
779 | 367 | - } | ||
780 | 368 | -} | ||
781 | 369 | --- /dev/null | ||
782 | 370 | +++ b/ucm2/sof-soundwire/rt1318.conf | ||
783 | 371 | @@ -0,0 +1,44 @@ | ||
784 | 372 | +# Use case Configuration for sof-soundwire card | ||
785 | 373 | + | ||
786 | 374 | +# | ||
787 | 375 | +# Arguments: | ||
788 | 376 | +# ForAmps - regex filter for var:SpeakerAmps | ||
789 | 377 | +# Amp - amplifier number (1,2 etc.) | ||
790 | 378 | +# Sel - channel selection (L,R L,L L,R L,L+R R,L R,R R,L+R L+R,L L+R,R L+R,L+R) | ||
791 | 379 | +# | ||
792 | 380 | +DefineMacro.rt1318spk.If.0 { | ||
793 | 381 | + Condition { | ||
794 | 382 | + Type RegexMatch | ||
795 | 383 | + Regex "${var:__RegEx}" | ||
796 | 384 | + String "${var:SpeakerAmps}" | ||
797 | 385 | + } | ||
798 | 386 | + True { | ||
799 | 387 | + EnableSequence [ | ||
800 | 388 | + cset "name='rt1308-${var:__Amp} RX Channel Select' ${var:__Sel}" | ||
801 | 389 | + cset "name='rt1308-${var:__Amp} DAC Switch' 1" | ||
802 | 390 | + ] | ||
803 | 391 | + DisableSequence [ | ||
804 | 392 | + cset "name='rt1308-${var:__Amp} DAC Switch' 0" | ||
805 | 393 | + ] | ||
806 | 394 | + } | ||
807 | 395 | +} | ||
808 | 396 | + | ||
809 | 397 | +SectionDevice."Speaker" { | ||
810 | 398 | + Comment "Speaker" | ||
811 | 399 | + | ||
812 | 400 | + Macro.num1.rt1318spk { ForAmps "[12]" Amp 1 Sel "L,L" } | ||
813 | 401 | + Macro.num2.rt1318spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
814 | 402 | + | ||
815 | 403 | + EnableSequence [ | ||
816 | 404 | + cset "name='Speaker Switch' on" | ||
817 | 405 | + ] | ||
818 | 406 | + | ||
819 | 407 | + DisableSequence [ | ||
820 | 408 | + cset "name='Speaker Switch' off" | ||
821 | 409 | + ] | ||
822 | 410 | + | ||
823 | 411 | + Value { | ||
824 | 412 | + PlaybackPriority 100 | ||
825 | 413 | + PlaybackPCM "hw:${CardId},2" | ||
826 | 414 | + } | ||
827 | 415 | +} | ||
828 | diff --git a/debian/patches/0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch b/debian/patches/0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch | |||
829 | 0 | new file mode 100644 | 416 | new file mode 100644 |
830 | index 0000000..1c60872 | |||
831 | --- /dev/null | |||
832 | +++ b/debian/patches/0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch | |||
833 | @@ -0,0 +1,23 @@ | |||
834 | 1 | From: Jaroslav Kysela <perex@perex.cz> | ||
835 | 2 | Date: Mon, 11 Mar 2024 11:06:15 +0100 | ||
836 | 3 | Subject: sof-soundwire: fix rt1318 config typo in rt1318spk macro | ||
837 | 4 | |||
838 | 5 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
839 | 6 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/7e22b7c214d346bd156131f3e6c6a5900bbf116d | ||
840 | 7 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
841 | 8 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
842 | 9 | --- | ||
843 | 10 | ucm2/sof-soundwire/rt1318.conf | 2 +- | ||
844 | 11 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
845 | 12 | |||
846 | 13 | --- a/ucm2/sof-soundwire/rt1318.conf | ||
847 | 14 | +++ b/ucm2/sof-soundwire/rt1318.conf | ||
848 | 15 | @@ -9,7 +9,7 @@ | ||
849 | 16 | DefineMacro.rt1318spk.If.0 { | ||
850 | 17 | Condition { | ||
851 | 18 | Type RegexMatch | ||
852 | 19 | - Regex "${var:__RegEx}" | ||
853 | 20 | + Regex "${var:__ForAmps}" | ||
854 | 21 | String "${var:SpeakerAmps}" | ||
855 | 22 | } | ||
856 | 23 | True { | ||
857 | diff --git a/debian/patches/0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch b/debian/patches/0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch | |||
858 | 0 | new file mode 100644 | 24 | new file mode 100644 |
859 | index 0000000..1ec9814 | |||
860 | --- /dev/null | |||
861 | +++ b/debian/patches/0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch | |||
862 | @@ -0,0 +1,78 @@ | |||
863 | 1 | From 1ab2d020d71a570f691fafbd341782fabb6569d1 Mon Sep 17 00:00:00 2001 | ||
864 | 2 | From: Zoran Zhan <zoran.zhan@mediatek.com> | ||
865 | 3 | Date: Mon, 22 Jan 2024 17:52:05 +0800 | ||
866 | 4 | Subject: [PATCH] ucm: MediaTek: mt8395-evk: Add HDMIRX config | ||
867 | 5 | |||
868 | 6 | Add HDMI RX config and modify the priority value | ||
869 | 7 | of the capture devices. | ||
870 | 8 | |||
871 | 9 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/389 | ||
872 | 10 | Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com> | ||
873 | 11 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
874 | 12 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/1ab2d020d71a570f691fafbd341782fabb6569d1 | ||
875 | 13 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2051199 | ||
876 | 14 | --- | ||
877 | 15 | ucm2/MediaTek/mt8395-evk/HiFi.conf | 15 ++++++++++++--- | ||
878 | 16 | ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | 1 + | ||
879 | 17 | 2 files changed, 13 insertions(+), 3 deletions(-) | ||
880 | 18 | |||
881 | 19 | diff --git a/ucm2/MediaTek/mt8395-evk/HiFi.conf b/ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
882 | 20 | index 81e4423..5c25cfb 100644 | ||
883 | 21 | --- a/ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
884 | 22 | +++ b/ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
885 | 23 | @@ -34,6 +34,15 @@ SectionDevice."HDMI2" { | ||
886 | 24 | ] | ||
887 | 25 | } | ||
888 | 26 | |||
889 | 27 | +SectionDevice."HDMI3" { | ||
890 | 28 | + Comment "HDMI RX" | ||
891 | 29 | + | ||
892 | 30 | + Value { | ||
893 | 31 | + CapturePriority 200 | ||
894 | 32 | + CapturePCM "hw:${CardId},7" | ||
895 | 33 | + } | ||
896 | 34 | +} | ||
897 | 35 | + | ||
898 | 36 | SectionDevice."Speaker" { | ||
899 | 37 | Comment "Lineout speaker" | ||
900 | 38 | |||
901 | 39 | @@ -90,7 +99,7 @@ SectionDevice."Headset" { | ||
902 | 40 | ] | ||
903 | 41 | |||
904 | 42 | Value { | ||
905 | 43 | - CapturePriority 400 | ||
906 | 44 | + CapturePriority 500 | ||
907 | 45 | CaptureChannels 3 | ||
908 | 46 | CapturePCM "hw:${CardId},15" | ||
909 | 47 | } | ||
910 | 48 | @@ -117,7 +126,7 @@ SectionDevice."Mic1" { | ||
911 | 49 | ] | ||
912 | 50 | |||
913 | 51 | Value { | ||
914 | 52 | - CapturePriority 300 | ||
915 | 53 | + CapturePriority 400 | ||
916 | 54 | CaptureChannels 3 | ||
917 | 55 | CapturePCM "hw:${CardId},15" | ||
918 | 56 | } | ||
919 | 57 | @@ -127,7 +136,7 @@ SectionDevice."Mic2" { | ||
920 | 58 | Comment "Digital microphone" | ||
921 | 59 | |||
922 | 60 | Value { | ||
923 | 61 | - CapturePriority 200 | ||
924 | 62 | + CapturePriority 300 | ||
925 | 63 | CaptureChannels 2 | ||
926 | 64 | CapturePCM "hw:${CardId},14" | ||
927 | 65 | } | ||
928 | 66 | diff --git a/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf b/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
929 | 67 | index 1957b69..b739ec0 100644 | ||
930 | 68 | --- a/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
931 | 69 | +++ b/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
932 | 70 | @@ -18,6 +18,7 @@ BootSequence [ | ||
933 | 71 | cset "name='PGA_3_Mux' AIN3" | ||
934 | 72 | cset "name='HDMI_OUT_MUX' Connect" | ||
935 | 73 | cset "name='DPTX_OUT_MUX' Disconnect" | ||
936 | 74 | + cset "name='MULTI_IN1_MUX' HDMI_RX_I2S" | ||
937 | 75 | cset "name='Lineout Volume' 10" | ||
938 | 76 | cset "name='Headset Volume' 2" | ||
939 | 77 | cset "name='PGA1 Volume' 4" | ||
940 | 78 | -- | ||
941 | diff --git a/debian/patches/0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch b/debian/patches/0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch | |||
942 | 0 | new file mode 100644 | 79 | new file mode 100644 |
943 | index 0000000..2245480 | |||
944 | --- /dev/null | |||
945 | +++ b/debian/patches/0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch | |||
946 | @@ -0,0 +1,254 @@ | |||
947 | 1 | From c5366bdff656092241225d2ad663c3e41b146f8b Mon Sep 17 00:00:00 2001 | ||
948 | 2 | From: Zoran Zhan <zoran.zhan@mediatek.com> | ||
949 | 3 | Date: Thu, 1 Jun 2023 15:37:14 +0800 | ||
950 | 4 | Subject: [PATCH 1/3] ucm2: MediaTek: mt8390-evk: Add alsa-ucm support | ||
951 | 5 | |||
952 | 6 | Add alsa-ucm support for the MediaTek mt8390-evk platform. | ||
953 | 7 | |||
954 | 8 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/321 | ||
955 | 9 | Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com> | ||
956 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
957 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/c5366bdff656092241225d2ad663c3e41b146f8b | ||
958 | 12 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2051199 | ||
959 | 13 | --- | ||
960 | 14 | ucm2/MediaTek/mt8390-evk/HiFi.conf | 165 +++++++++++++++++++++++ | ||
961 | 15 | ucm2/MediaTek/mt8390-evk/mt8390-evk.conf | 45 +++++++ | ||
962 | 16 | ucm2/conf.d/mt8390-evk/mt8390-evk.conf | 1 + | ||
963 | 17 | 3 files changed, 211 insertions(+) | ||
964 | 18 | create mode 100644 ucm2/MediaTek/mt8390-evk/HiFi.conf | ||
965 | 19 | create mode 100644 ucm2/MediaTek/mt8390-evk/mt8390-evk.conf | ||
966 | 20 | create mode 120000 ucm2/conf.d/mt8390-evk/mt8390-evk.conf | ||
967 | 21 | |||
968 | 22 | diff --git a/ucm2/MediaTek/mt8390-evk/HiFi.conf b/ucm2/MediaTek/mt8390-evk/HiFi.conf | ||
969 | 23 | new file mode 100644 | ||
970 | 24 | index 0000000..42a4582 | ||
971 | 25 | --- /dev/null | ||
972 | 26 | +++ b/ucm2/MediaTek/mt8390-evk/HiFi.conf | ||
973 | 27 | @@ -0,0 +1,165 @@ | ||
974 | 28 | +SectionDevice."HDMI1" { | ||
975 | 29 | + Comment "HDMI output" | ||
976 | 30 | + | ||
977 | 31 | + Value { | ||
978 | 32 | + PlaybackPriority 300 | ||
979 | 33 | + PlaybackPCM "hw:${CardId},5" | ||
980 | 34 | + JackControl "HDMI Jack" | ||
981 | 35 | + } | ||
982 | 36 | + | ||
983 | 37 | + EnableSequence [ | ||
984 | 38 | + cset "name='HDMI_OUT_MUX' 1" | ||
985 | 39 | + ] | ||
986 | 40 | + | ||
987 | 41 | + DisableSequence [ | ||
988 | 42 | + cset "name='HDMI_OUT_MUX' 0" | ||
989 | 43 | + ] | ||
990 | 44 | +} | ||
991 | 45 | + | ||
992 | 46 | +SectionDevice."HDMI2" { | ||
993 | 47 | + Comment "DP output" | ||
994 | 48 | + | ||
995 | 49 | + Value { | ||
996 | 50 | + PlaybackPriority 300 | ||
997 | 51 | + PlaybackPCM "hw:${CardId},5" | ||
998 | 52 | + JackControl "DP Jack" | ||
999 | 53 | + } | ||
1000 | 54 | + | ||
1001 | 55 | + EnableSequence [ | ||
1002 | 56 | + cset "name='DPTX_OUT_MUX' 1" | ||
1003 | 57 | + ] | ||
1004 | 58 | + | ||
1005 | 59 | + DisableSequence [ | ||
1006 | 60 | + cset "name='DPTX_OUT_MUX' 0" | ||
1007 | 61 | + ] | ||
1008 | 62 | +} | ||
1009 | 63 | + | ||
1010 | 64 | +SectionDevice."Speaker" { | ||
1011 | 65 | + Comment "Lineout speaker" | ||
1012 | 66 | + | ||
1013 | 67 | + ConflictingDevice [ | ||
1014 | 68 | + "Headphones" | ||
1015 | 69 | + ] | ||
1016 | 70 | + | ||
1017 | 71 | + EnableSequence [ | ||
1018 | 72 | + cset "name='LOL Mux' Playback_L_DAC" | ||
1019 | 73 | + ] | ||
1020 | 74 | + | ||
1021 | 75 | + DisableSequence [ | ||
1022 | 76 | + cset "name='LOL Mux' Open" | ||
1023 | 77 | + ] | ||
1024 | 78 | + | ||
1025 | 79 | + Value { | ||
1026 | 80 | + PlaybackPriority 400 | ||
1027 | 81 | + PlaybackChannels 2 | ||
1028 | 82 | + PlaybackPCM "hw:${CardId},0" | ||
1029 | 83 | + } | ||
1030 | 84 | +} | ||
1031 | 85 | + | ||
1032 | 86 | +SectionDevice."Headphones" { | ||
1033 | 87 | + Comment "Earphone speaker" | ||
1034 | 88 | + | ||
1035 | 89 | + ConflictingDevice [ | ||
1036 | 90 | + "Speaker" | ||
1037 | 91 | + ] | ||
1038 | 92 | + | ||
1039 | 93 | + EnableSequence [ | ||
1040 | 94 | + cset "name='HP Mux' Audio Playback" | ||
1041 | 95 | + ] | ||
1042 | 96 | + | ||
1043 | 97 | + DisableSequence [ | ||
1044 | 98 | + cset "name='HP Mux' Open" | ||
1045 | 99 | + ] | ||
1046 | 100 | + | ||
1047 | 101 | + Value { | ||
1048 | 102 | + PlaybackPriority 500 | ||
1049 | 103 | + PlaybackChannels 2 | ||
1050 | 104 | + PlaybackPCM "hw:${CardId},0" | ||
1051 | 105 | + } | ||
1052 | 106 | +} | ||
1053 | 107 | + | ||
1054 | 108 | +SectionDevice."Headset" { | ||
1055 | 109 | + Comment "Earphone microphone" | ||
1056 | 110 | + | ||
1057 | 111 | + ConflictingDevice [ | ||
1058 | 112 | + "Mic1" | ||
1059 | 113 | + ] | ||
1060 | 114 | + | ||
1061 | 115 | + EnableSequence [ | ||
1062 | 116 | + cset "name='PGA_L_Mux' AIN1" | ||
1063 | 117 | + ] | ||
1064 | 118 | + | ||
1065 | 119 | + Value { | ||
1066 | 120 | + CapturePriority 500 | ||
1067 | 121 | + CaptureChannels 1 | ||
1068 | 122 | + CapturePCM "hw:${CardId},10" | ||
1069 | 123 | + } | ||
1070 | 124 | +} | ||
1071 | 125 | + | ||
1072 | 126 | +SectionDevice."Mic1" { | ||
1073 | 127 | + Comment "Analog microphone" | ||
1074 | 128 | + | ||
1075 | 129 | + ConflictingDevice [ | ||
1076 | 130 | + "Headset" | ||
1077 | 131 | + ] | ||
1078 | 132 | + | ||
1079 | 133 | + EnableSequence [ | ||
1080 | 134 | + cset "name='PGA_L_Mux' AIN0" | ||
1081 | 135 | + ] | ||
1082 | 136 | + | ||
1083 | 137 | + Value { | ||
1084 | 138 | + CapturePriority 400 | ||
1085 | 139 | + CaptureChannels 1 | ||
1086 | 140 | + CapturePCM "hw:${CardId},10" | ||
1087 | 141 | + } | ||
1088 | 142 | +} | ||
1089 | 143 | + | ||
1090 | 144 | +SectionDevice."Mic2" { | ||
1091 | 145 | + Comment "Digital microphone" | ||
1092 | 146 | + | ||
1093 | 147 | + Value { | ||
1094 | 148 | + CapturePriority 300 | ||
1095 | 149 | + CaptureChannels 2 | ||
1096 | 150 | + CapturePCM "hw:${CardId},14" | ||
1097 | 151 | + } | ||
1098 | 152 | +} | ||
1099 | 153 | + | ||
1100 | 154 | +SectionDevice."Line1" { | ||
1101 | 155 | + Comment "PCM input" | ||
1102 | 156 | + | ||
1103 | 157 | + Value { | ||
1104 | 158 | + CapturePriority 200 | ||
1105 | 159 | + CaptureChannels 2 | ||
1106 | 160 | + CapturePCM "hw:${CardId},8" | ||
1107 | 161 | + } | ||
1108 | 162 | +} | ||
1109 | 163 | + | ||
1110 | 164 | +SectionDevice."Line2" { | ||
1111 | 165 | + Comment "PCM output" | ||
1112 | 166 | + | ||
1113 | 167 | + Value { | ||
1114 | 168 | + PlaybackPriority 200 | ||
1115 | 169 | + PlaybackChannels 2 | ||
1116 | 170 | + PlaybackPCM "hw:${CardId},2" | ||
1117 | 171 | + } | ||
1118 | 172 | +} | ||
1119 | 173 | + | ||
1120 | 174 | +SectionDevice."Line3" { | ||
1121 | 175 | + Comment "I2S input" | ||
1122 | 176 | + | ||
1123 | 177 | + Value { | ||
1124 | 178 | + CapturePriority 100 | ||
1125 | 179 | + CaptureChannels 2 | ||
1126 | 180 | + CapturePCM "hw:${CardId},11" | ||
1127 | 181 | + } | ||
1128 | 182 | +} | ||
1129 | 183 | + | ||
1130 | 184 | +SectionDevice."Line4" { | ||
1131 | 185 | + Comment "I2S output" | ||
1132 | 186 | + | ||
1133 | 187 | + Value { | ||
1134 | 188 | + PlaybackPriority 100 | ||
1135 | 189 | + PlaybackChannels 8 | ||
1136 | 190 | + PlaybackPCM "hw:${CardId},6" | ||
1137 | 191 | + } | ||
1138 | 192 | +} | ||
1139 | 193 | \ No newline at end of file | ||
1140 | 194 | diff --git a/ucm2/MediaTek/mt8390-evk/mt8390-evk.conf b/ucm2/MediaTek/mt8390-evk/mt8390-evk.conf | ||
1141 | 195 | new file mode 100644 | ||
1142 | 196 | index 0000000..e2d56e2 | ||
1143 | 197 | --- /dev/null | ||
1144 | 198 | +++ b/ucm2/MediaTek/mt8390-evk/mt8390-evk.conf | ||
1145 | 199 | @@ -0,0 +1,45 @@ | ||
1146 | 200 | +Syntax 4 | ||
1147 | 201 | + | ||
1148 | 202 | +SectionUseCase."HiFi" { | ||
1149 | 203 | + File "/MediaTek/mt8390-evk/HiFi.conf" | ||
1150 | 204 | + Comment "Play high quality music" | ||
1151 | 205 | +} | ||
1152 | 206 | + | ||
1153 | 207 | +BootSequence [ | ||
1154 | 208 | + cset "name='HP Mux' Audio Playback" | ||
1155 | 209 | + cset "name='LOL Mux' Open" | ||
1156 | 210 | + cset "name='MISO0_MUX' UL1_CH1" | ||
1157 | 211 | + cset "name='MISO1_MUX' UL1_CH1" | ||
1158 | 212 | + cset "name='ADC_L_Mux' Left Preamplifier" | ||
1159 | 213 | + cset "name='PGA_L_Mux' AIN1" | ||
1160 | 214 | + cset "name='HDMI_OUT_MUX' Connect" | ||
1161 | 215 | + cset "name='DPTX_OUT_MUX' Disconnect" | ||
1162 | 216 | + cset "name='ETDM_OUT1_Clock_Source' a1sys_a2sys" | ||
1163 | 217 | + cset "name='ETDM_OUT2_Clock_Source' a1sys_a2sys" | ||
1164 | 218 | + cset "name='ETDM_OUT3_Clock_Source' a1sys_a2sys" | ||
1165 | 219 | + cset "name='ETDM_IN1_Clock_Source' a1sys_a2sys" | ||
1166 | 220 | + cset "name='ETDM_IN2_Clock_Source' a1sys_a2sys" | ||
1167 | 221 | + cset "name='Lineout Volume' 10" | ||
1168 | 222 | + cset "name='Headset Volume' 2" | ||
1169 | 223 | + cset "name='PGA1 Volume' 4" | ||
1170 | 224 | + cset "name='O000 I000 Switch' on" | ||
1171 | 225 | + cset "name='O001 I001 Switch' on" | ||
1172 | 226 | + cset "name='O002 I004 Switch' on" | ||
1173 | 227 | + cset "name='O003 I006 Switch' on" | ||
1174 | 228 | + cset "name='O034 I168 Switch' on" | ||
1175 | 229 | + cset "name='O035 I169 Switch' on" | ||
1176 | 230 | + cset "name='O036 I012 Switch' on" | ||
1177 | 231 | + cset "name='O037 I013 Switch' on" | ||
1178 | 232 | + cset "name='O040 I002 Switch' on" | ||
1179 | 233 | + cset "name='O041 I003 Switch' on" | ||
1180 | 234 | + cset "name='O048 I022 Switch' on" | ||
1181 | 235 | + cset "name='O049 I023 Switch' on" | ||
1182 | 236 | + cset "name='O050 I024 Switch' on" | ||
1183 | 237 | + cset "name='O051 I025 Switch' on" | ||
1184 | 238 | + cset "name='O052 I026 Switch' on" | ||
1185 | 239 | + cset "name='O053 I027 Switch' on" | ||
1186 | 240 | + cset "name='O054 I028 Switch' on" | ||
1187 | 241 | + cset "name='O055 I029 Switch' on" | ||
1188 | 242 | + cset "name='O176 I070 Switch' on" | ||
1189 | 243 | + cset "name='O177 I071 Switch' on" | ||
1190 | 244 | +] | ||
1191 | 245 | \ No newline at end of file | ||
1192 | 246 | diff --git a/ucm2/conf.d/mt8390-evk/mt8390-evk.conf b/ucm2/conf.d/mt8390-evk/mt8390-evk.conf | ||
1193 | 247 | new file mode 120000 | ||
1194 | 248 | index 0000000..5b5c2b9 | ||
1195 | 249 | --- /dev/null | ||
1196 | 250 | +++ b/ucm2/conf.d/mt8390-evk/mt8390-evk.conf | ||
1197 | 251 | @@ -0,0 +1 @@ | ||
1198 | 252 | +../../MediaTek/mt8390-evk/mt8390-evk.conf | ||
1199 | 253 | \ No newline at end of file | ||
1200 | 254 | -- | ||
1201 | diff --git a/debian/patches/0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch b/debian/patches/0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch | |||
1202 | 0 | new file mode 100644 | 255 | new file mode 100644 |
1203 | index 0000000..f78a404 | |||
1204 | --- /dev/null | |||
1205 | +++ b/debian/patches/0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch | |||
1206 | @@ -0,0 +1,34 @@ | |||
1207 | 1 | From d864e945ce4171fcaf6249bebec4f683fef0f5cf Mon Sep 17 00:00:00 2001 | ||
1208 | 2 | From: Zoran Zhan <zoran.zhan@mediatek.com> | ||
1209 | 3 | Date: Mon, 22 Jan 2024 11:49:08 +0800 | ||
1210 | 4 | Subject: [PATCH] ucm2: conf.d: mt8370-evk: Fix the type of mt8370-evk.conf | ||
1211 | 5 | |||
1212 | 6 | Fix the type of mt8370-evk.conf at /ucm2/conf.d, to let the | ||
1213 | 7 | symbolic link can correctly point to the conf. | ||
1214 | 8 | |||
1215 | 9 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/386 | ||
1216 | 10 | Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com> | ||
1217 | 11 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1218 | 12 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/d864e945ce4171fcaf6249bebec4f683fef0f5cf | ||
1219 | 13 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2051199 | ||
1220 | 14 | --- | ||
1221 | 15 | ucm2/conf.d/mt8370-evk/mt8370-evk.conf | 2 +- | ||
1222 | 16 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
1223 | 17 | mode change 100644 => 120000 ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
1224 | 18 | |||
1225 | 19 | diff --git a/ucm2/conf.d/mt8370-evk/mt8370-evk.conf b/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
1226 | 20 | deleted file mode 100644 | ||
1227 | 21 | index 6edb08f..0000000 | ||
1228 | 22 | --- a/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
1229 | 23 | +++ /dev/null | ||
1230 | 24 | @@ -1 +0,0 @@ | ||
1231 | 25 | -../../MediaTek/mt8370-evk/mt8370-evk.conf | ||
1232 | 26 | diff --git a/ucm2/conf.d/mt8370-evk/mt8370-evk.conf b/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
1233 | 27 | new file mode 120000 | ||
1234 | 28 | index 0000000..fed8ef1 | ||
1235 | 29 | --- /dev/null | ||
1236 | 30 | +++ b/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
1237 | 31 | @@ -0,0 +1 @@ | ||
1238 | 32 | +../../MediaTek/mt8370-evk/mt8370-evk.conf | ||
1239 | 33 | \ No newline at end of file | ||
1240 | 34 | -- | ||
1241 | diff --git a/debian/patches/0001-ucm2-soundwire-add-rt713-SDCA-device.patch b/debian/patches/0001-ucm2-soundwire-add-rt713-SDCA-device.patch | |||
1242 | 0 | new file mode 100644 | 35 | new file mode 100644 |
1243 | index 0000000..b4f1387 | |||
1244 | --- /dev/null | |||
1245 | +++ b/debian/patches/0001-ucm2-soundwire-add-rt713-SDCA-device.patch | |||
1246 | @@ -0,0 +1,159 @@ | |||
1247 | 1 | From b422a8e08cb3845053ece1fc832294adca21a684 Mon Sep 17 00:00:00 2001 | ||
1248 | 2 | From: Shuming Fan <shumingf@realtek.com> | ||
1249 | 3 | Date: Thu, 12 Oct 2023 10:07:36 +0800 | ||
1250 | 4 | Subject: [PATCH] ucm2: soundwire: add rt713 SDCA device | ||
1251 | 5 | |||
1252 | 6 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/363 | ||
1253 | 7 | Signed-off-by: Shuming Fan <shumingf@realtek.com> | ||
1254 | 8 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1255 | 9 | |||
1256 | 10 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/b422a8e08cb3845053ece1fc832294adca21a684 | ||
1257 | 11 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2042902 | ||
1258 | 12 | Applied-Upstream: v1.2.11 | ||
1259 | 13 | Last-Update: 2023-11-24 | ||
1260 | 14 | |||
1261 | 15 | --- | ||
1262 | 16 | ucm2/codecs/rt713-dmic/init.conf | 6 ++++ | ||
1263 | 17 | ucm2/codecs/rt713-sdca/init.conf | 8 ++++++ | ||
1264 | 18 | ucm2/sof-soundwire/rt713-dmic.conf | 21 ++++++++++++++ | ||
1265 | 19 | ucm2/sof-soundwire/rt713-sdca.conf | 40 +++++++++++++++++++++++++++ | ||
1266 | 20 | ucm2/sof-soundwire/sof-soundwire.conf | 6 ++-- | ||
1267 | 21 | 5 files changed, 78 insertions(+), 3 deletions(-) | ||
1268 | 22 | create mode 100644 ucm2/codecs/rt713-dmic/init.conf | ||
1269 | 23 | create mode 100644 ucm2/codecs/rt713-sdca/init.conf | ||
1270 | 24 | create mode 100644 ucm2/sof-soundwire/rt713-dmic.conf | ||
1271 | 25 | create mode 100644 ucm2/sof-soundwire/rt713-sdca.conf | ||
1272 | 26 | |||
1273 | 27 | diff --git a/ucm2/codecs/rt713-dmic/init.conf b/ucm2/codecs/rt713-dmic/init.conf | ||
1274 | 28 | new file mode 100644 | ||
1275 | 29 | index 0000000..6547a36 | ||
1276 | 30 | --- /dev/null | ||
1277 | 31 | +++ b/ucm2/codecs/rt713-dmic/init.conf | ||
1278 | 32 | @@ -0,0 +1,6 @@ | ||
1279 | 33 | +# RT713-dmic specific volume control settings | ||
1280 | 34 | + | ||
1281 | 35 | +BootSequence [ | ||
1282 | 36 | + cset "name='rt713-dmic ADC 25 Mux' 'DMIC1'" | ||
1283 | 37 | + cset "name='rt713-dmic FU1E Capture Switch' 1" | ||
1284 | 38 | +] | ||
1285 | 39 | diff --git a/ucm2/codecs/rt713-sdca/init.conf b/ucm2/codecs/rt713-sdca/init.conf | ||
1286 | 40 | new file mode 100644 | ||
1287 | 41 | index 0000000..df6a7aa | ||
1288 | 42 | --- /dev/null | ||
1289 | 43 | +++ b/ucm2/codecs/rt713-sdca/init.conf | ||
1290 | 44 | @@ -0,0 +1,8 @@ | ||
1291 | 45 | +# RT713-sdca specific volume control settings | ||
1292 | 46 | + | ||
1293 | 47 | +BootSequence [ | ||
1294 | 48 | + cset "name='rt713 FU05 Playback Volume' 87" | ||
1295 | 49 | + cset "name='rt713 ADC 23 Mux' 'MIC2'" | ||
1296 | 50 | + cset "name='rt713 FU0F Capture Volume' 57" | ||
1297 | 51 | + cset "name='rt713 FU0F Capture Switch' 1" | ||
1298 | 52 | +] | ||
1299 | 53 | diff --git a/ucm2/sof-soundwire/rt713-dmic.conf b/ucm2/sof-soundwire/rt713-dmic.conf | ||
1300 | 54 | new file mode 100644 | ||
1301 | 55 | index 0000000..dc5fe0e | ||
1302 | 56 | --- /dev/null | ||
1303 | 57 | +++ b/ucm2/sof-soundwire/rt713-dmic.conf | ||
1304 | 58 | @@ -0,0 +1,21 @@ | ||
1305 | 59 | +# Use case Configuration for sof-soundwire card | ||
1306 | 60 | + | ||
1307 | 61 | +SectionDevice."Mic" { | ||
1308 | 62 | + Comment "SoundWire microphones" | ||
1309 | 63 | + | ||
1310 | 64 | + EnableSequence [ | ||
1311 | 65 | + cset "name='rt713-dmic FU1E Capture Switch' 1" | ||
1312 | 66 | + ] | ||
1313 | 67 | + | ||
1314 | 68 | + DisableSequence [ | ||
1315 | 69 | + cset "name='rt713-dmic FU1E Capture Switch' 0" | ||
1316 | 70 | + ] | ||
1317 | 71 | + | ||
1318 | 72 | + Value { | ||
1319 | 73 | + CapturePriority 100 | ||
1320 | 74 | + CapturePCM "hw:${CardId},4" | ||
1321 | 75 | + CaptureSwitch "rt713-dmic FU1E Capture Switch" | ||
1322 | 76 | + CaptureVolume "rt713-dmic FU1E Capture Volume" | ||
1323 | 77 | + CaptureMixerElem "rt713-dmic FU1E" | ||
1324 | 78 | + } | ||
1325 | 79 | +} | ||
1326 | 80 | diff --git a/ucm2/sof-soundwire/rt713-sdca.conf b/ucm2/sof-soundwire/rt713-sdca.conf | ||
1327 | 81 | new file mode 100644 | ||
1328 | 82 | index 0000000..f1cee7c | ||
1329 | 83 | --- /dev/null | ||
1330 | 84 | +++ b/ucm2/sof-soundwire/rt713-sdca.conf | ||
1331 | 85 | @@ -0,0 +1,40 @@ | ||
1332 | 86 | +# Use case Configuration for sof-soundwire card | ||
1333 | 87 | + | ||
1334 | 88 | +SectionDevice."Headphones" { | ||
1335 | 89 | + Comment "Headphones" | ||
1336 | 90 | + | ||
1337 | 91 | + EnableSequence [ | ||
1338 | 92 | + cset "name='Headphone Switch' on" | ||
1339 | 93 | + ] | ||
1340 | 94 | + | ||
1341 | 95 | + DisableSequence [ | ||
1342 | 96 | + cset "name='Headphone Switch' off" | ||
1343 | 97 | + ] | ||
1344 | 98 | + | ||
1345 | 99 | + Value { | ||
1346 | 100 | + PlaybackPriority 200 | ||
1347 | 101 | + PlaybackPCM "hw:${CardId}" | ||
1348 | 102 | + JackControl "Headphone Jack" | ||
1349 | 103 | + } | ||
1350 | 104 | +} | ||
1351 | 105 | + | ||
1352 | 106 | +SectionDevice."Headset" { | ||
1353 | 107 | + Comment "Headset Microphone" | ||
1354 | 108 | + | ||
1355 | 109 | + EnableSequence [ | ||
1356 | 110 | + cset "name='rt713 FU0F Capture Switch' 1" | ||
1357 | 111 | + ] | ||
1358 | 112 | + | ||
1359 | 113 | + DisableSequence [ | ||
1360 | 114 | + cset "name='rt713 FU0F Capture Switch' 0" | ||
1361 | 115 | + ] | ||
1362 | 116 | + | ||
1363 | 117 | + Value { | ||
1364 | 118 | + CapturePriority 200 | ||
1365 | 119 | + CapturePCM "hw:${CardId},1" | ||
1366 | 120 | + JackControl "Headset Mic Jack" | ||
1367 | 121 | + CaptureSwitch "rt713 FU0F Capture Switch" | ||
1368 | 122 | + CaptureVolume "rt713 FU0F Capture Volume" | ||
1369 | 123 | + CaptureMixerElem "rt713 FU0F" | ||
1370 | 124 | + } | ||
1371 | 125 | +} | ||
1372 | 126 | diff --git a/ucm2/sof-soundwire/sof-soundwire.conf b/ucm2/sof-soundwire/sof-soundwire.conf | ||
1373 | 127 | index 3368d65..18b1bf8 100644 | ||
1374 | 128 | --- a/ucm2/sof-soundwire/sof-soundwire.conf | ||
1375 | 129 | +++ b/ucm2/sof-soundwire/sof-soundwire.conf | ||
1376 | 130 | @@ -35,7 +35,7 @@ DefineRegex { | ||
1377 | 131 | String "${CardComponents}" | ||
1378 | 132 | } | ||
1379 | 133 | MicCodec { | ||
1380 | 134 | - Regex " mic:([a-z0-9]+(-sdca)?)" | ||
1381 | 135 | + Regex " mic:([a-z0-9]+(-dmic)?+(-sdca)?)" | ||
1382 | 136 | String "${CardComponents}" | ||
1383 | 137 | } | ||
1384 | 138 | Mics { | ||
1385 | 139 | @@ -47,7 +47,7 @@ DefineRegex { | ||
1386 | 140 | If.hs_init { | ||
1387 | 141 | Condition { | ||
1388 | 142 | Type RegexMatch | ||
1389 | 143 | - Regex "(rt5682|rt700|rt711(-sdca)?)" | ||
1390 | 144 | + Regex "(rt5682|rt700|rt711|rt713(-sdca)?)" | ||
1391 | 145 | String "${var:HeadsetCodec1}" | ||
1392 | 146 | } | ||
1393 | 147 | True.Include.hs_init.File "/codecs/${var:HeadsetCodec1}/init.conf" | ||
1394 | 148 | @@ -56,7 +56,7 @@ If.hs_init { | ||
1395 | 149 | If.mic_init { | ||
1396 | 150 | Condition { | ||
1397 | 151 | Type RegexMatch | ||
1398 | 152 | - Regex "(rt715(-sdca)?)" | ||
1399 | 153 | + Regex "(rt713-dmic|rt715(-sdca)?)" | ||
1400 | 154 | String "${var:MicCodec1}" | ||
1401 | 155 | } | ||
1402 | 156 | True.Include.mic_init.File "/codecs/${var:MicCodec1}/init.conf" | ||
1403 | 157 | -- | ||
1404 | 158 | 2.34.1 | ||
1405 | 159 | |||
1406 | diff --git a/debian/patches/0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch b/debian/patches/0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch | |||
1407 | 0 | new file mode 100644 | 160 | new file mode 100644 |
1408 | index 0000000..2ffb1bd | |||
1409 | --- /dev/null | |||
1410 | +++ b/debian/patches/0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch | |||
1411 | @@ -0,0 +1,62 @@ | |||
1412 | 1 | From: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1413 | 2 | Date: Wed, 6 Dec 2023 16:46:12 +0000 | ||
1414 | 3 | Subject: [PATCH 2/3] sof-soundwire: Add basic support for basic cs35l56 | ||
1415 | 4 | configurations | ||
1416 | 5 | |||
1417 | 6 | cs35l56 is a boosted speaker amp, add UCM support for configurations | ||
1418 | 7 | with up to 8 amps. | ||
1419 | 8 | |||
1420 | 9 | Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1421 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1422 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/8e39917518b62cce44d098bd6fe5d2c1b41f92bd | ||
1423 | 12 | Bug: https://github.com/alsa-project/alsa-ucm-conf/pull/370 | ||
1424 | 13 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
1425 | 14 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
1426 | 15 | --- | ||
1427 | 16 | ucm2/sof-soundwire/cs35l56.conf | 40 ++++++++++++++++++++++++++++++++++++++++ | ||
1428 | 17 | 1 file changed, 40 insertions(+) | ||
1429 | 18 | create mode 100644 ucm2/sof-soundwire/cs35l56.conf | ||
1430 | 19 | |||
1431 | 20 | --- /dev/null | ||
1432 | 21 | +++ b/ucm2/sof-soundwire/cs35l56.conf | ||
1433 | 22 | @@ -0,0 +1,40 @@ | ||
1434 | 23 | +# Use case Configuration for sof-soundwire card | ||
1435 | 24 | + | ||
1436 | 25 | +# | ||
1437 | 26 | +# Arguments: | ||
1438 | 27 | +# ForAmps - regex filter for var:SpeakerAmps | ||
1439 | 28 | +# Amp - amplifier number 1-8 | ||
1440 | 29 | +# | ||
1441 | 30 | +DefineMacro.cs42l43spk.If.0 { | ||
1442 | 31 | + Condition { | ||
1443 | 32 | + Type RegexMatch | ||
1444 | 33 | + Regex "${var:__ForAmps}" | ||
1445 | 34 | + String "${var:SpeakerAmps}" | ||
1446 | 35 | + } | ||
1447 | 36 | + True { | ||
1448 | 37 | + EnableSequence [ | ||
1449 | 38 | + cset "name='AMP${var:__Amp} Speaker Switch' 1" | ||
1450 | 39 | + ] | ||
1451 | 40 | + DisableSequence [ | ||
1452 | 41 | + cset "name='AMP${var:__Amp} Speaker Switch' 0" | ||
1453 | 42 | + ] | ||
1454 | 43 | + } | ||
1455 | 44 | +} | ||
1456 | 45 | + | ||
1457 | 46 | +SectionDevice."Speaker" { | ||
1458 | 47 | + Comment "Speaker" | ||
1459 | 48 | + | ||
1460 | 49 | + Macro.num1.cs42l43spk { ForAmps "[1-8]" Amp 1 } | ||
1461 | 50 | + Macro.num2.cs42l43spk { ForAmps "[2-8]" Amp 2 } | ||
1462 | 51 | + Macro.num3.cs42l43spk { ForAmps "[3-8]" Amp 3 } | ||
1463 | 52 | + Macro.num4.cs42l43spk { ForAmps "[4-8]" Amp 4 } | ||
1464 | 53 | + Macro.num5.cs42l43spk { ForAmps "[5-8]" Amp 5 } | ||
1465 | 54 | + Macro.num6.cs42l43spk { ForAmps "[6-8]" Amp 6 } | ||
1466 | 55 | + Macro.num7.cs42l43spk { ForAmps "[78]" Amp 7 } | ||
1467 | 56 | + Macro.num8.cs42l43spk { ForAmps "8" Amp 8 } | ||
1468 | 57 | + | ||
1469 | 58 | + Value { | ||
1470 | 59 | + PlaybackPriority 100 | ||
1471 | 60 | + PlaybackPCM "hw:${CardId},2" | ||
1472 | 61 | + } | ||
1473 | 62 | +} | ||
1474 | diff --git a/debian/patches/0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch b/debian/patches/0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch | |||
1475 | 0 | new file mode 100644 | 63 | new file mode 100644 |
1476 | index 0000000..7a51a10 | |||
1477 | --- /dev/null | |||
1478 | +++ b/debian/patches/0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch | |||
1479 | @@ -0,0 +1,53 @@ | |||
1480 | 1 | From: Maciej Strozek <mstrozek@opensource.cirrus.com> | ||
1481 | 2 | Date: Thu, 17 Oct 2024 13:20:27 +0100 | ||
1482 | 3 | Subject: sof-soundwire: Add sequence for controlling Mic Mute LED | ||
1483 | 4 | |||
1484 | 5 | Also ensure the unused microphone is disabled so that currently used mic | ||
1485 | 6 | can fully control the LED. | ||
1486 | 7 | |||
1487 | 8 | Link: https://lore.kernel.org/alsa-devel/20241017122027.1207373-2-mstrozek@opensource.cirrus.com/ | ||
1488 | 9 | Signed-off-by: Maciej Strozek <mstrozek@opensource.cirrus.com> | ||
1489 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1490 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/e4277a204cd61f8f68f616df0d8c42e5bdeb1475 | ||
1491 | 12 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
1492 | 13 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
1493 | 14 | --- | ||
1494 | 15 | ucm2/codecs/cs42l43/init.conf | 7 +++++++ | ||
1495 | 16 | ucm2/sof-soundwire/cs42l43-dmic.conf | 2 ++ | ||
1496 | 17 | ucm2/sof-soundwire/cs42l43.conf | 1 + | ||
1497 | 18 | 3 files changed, 10 insertions(+) | ||
1498 | 19 | |||
1499 | 20 | --- a/ucm2/codecs/cs42l43/init.conf | ||
1500 | 21 | +++ b/ucm2/codecs/cs42l43/init.conf | ||
1501 | 22 | @@ -18,3 +18,10 @@ | ||
1502 | 23 | } | ||
1503 | 24 | } | ||
1504 | 25 | } | ||
1505 | 26 | + | ||
1506 | 27 | +FixedBootSequence [ | ||
1507 | 28 | + exec "-/sbin/modprobe snd_ctl_led" | ||
1508 | 29 | + sysw "-/class/sound/ctl-led/mic/card${CardNumber}/attach:cs42l43 Decimator 1 Switch" | ||
1509 | 30 | + sysw "-/class/sound/ctl-led/mic/card${CardNumber}/attach:cs42l43 Decimator 3 Switch" | ||
1510 | 31 | + sysw "-/class/sound/ctl-led/mic/card${CardNumber}/attach:cs42l43 Decimator 4 Switch" | ||
1511 | 32 | +] | ||
1512 | 33 | --- a/ucm2/sof-soundwire/cs42l43-dmic.conf | ||
1513 | 34 | +++ b/ucm2/sof-soundwire/cs42l43-dmic.conf | ||
1514 | 35 | @@ -13,6 +13,8 @@ | ||
1515 | 36 | ] | ||
1516 | 37 | |||
1517 | 38 | DisableSequence [ | ||
1518 | 39 | + cset "name='cs42l43 Decimator 3 Switch' 0" | ||
1519 | 40 | + cset "name='cs42l43 Decimator 4 Switch' 0" | ||
1520 | 41 | cset "name='cs42l43 DP1TX1 Input' 'None'" | ||
1521 | 42 | cset "name='cs42l43 DP1TX2 Input' 'None'" | ||
1522 | 43 | ] | ||
1523 | 44 | --- a/ucm2/sof-soundwire/cs42l43.conf | ||
1524 | 45 | +++ b/ucm2/sof-soundwire/cs42l43.conf | ||
1525 | 46 | @@ -33,6 +33,7 @@ | ||
1526 | 47 | ] | ||
1527 | 48 | |||
1528 | 49 | DisableSequence [ | ||
1529 | 50 | + cset "name='cs42l43 Decimator 1 Switch' 0" | ||
1530 | 51 | cset "name='cs42l43 DP1TX1 Input' 'None'" | ||
1531 | 52 | cset "name='cs42l43 DP1TX2 Input' 'None'" | ||
1532 | 53 | ] | ||
1533 | diff --git a/debian/patches/0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch b/debian/patches/0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch | |||
1534 | 0 | new file mode 100644 | 54 | new file mode 100644 |
1535 | index 0000000..50076b0 | |||
1536 | --- /dev/null | |||
1537 | +++ b/debian/patches/0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch | |||
1538 | @@ -0,0 +1,95 @@ | |||
1539 | 1 | From: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1540 | 2 | Date: Mon, 8 Jul 2024 12:59:19 +0100 | ||
1541 | 3 | Subject: sof-soundwire: Add support for cs42l43/cs35l56 bridge configuration | ||
1542 | 4 | |||
1543 | 5 | The cs42l43 has both a SPI master and an I2S interface, in some | ||
1544 | 6 | configurations 2 cs35l56 amplifiers are connected to these to provide | ||
1545 | 7 | bass speakers whilst the cs42l43's internal speaker drivers are used for | ||
1546 | 8 | the tweeters. Add UCM configuration for this type of system. | ||
1547 | 9 | |||
1548 | 10 | Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1549 | 11 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1550 | 12 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/e4277a204cd61f8f68f616df0d8c42e5bdeb1475 | ||
1551 | 13 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
1552 | 14 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
1553 | 15 | --- | ||
1554 | 16 | ucm2/sof-soundwire/cs35l56-bridge.conf | 61 ++++++++++++++++++++++++++++++++++ | ||
1555 | 17 | ucm2/sof-soundwire/sof-soundwire.conf | 2 +- | ||
1556 | 18 | 2 files changed, 62 insertions(+), 1 deletion(-) | ||
1557 | 19 | create mode 100644 ucm2/sof-soundwire/cs35l56-bridge.conf | ||
1558 | 20 | |||
1559 | 21 | --- /dev/null | ||
1560 | 22 | +++ b/ucm2/sof-soundwire/cs35l56-bridge.conf | ||
1561 | 23 | @@ -0,0 +1,61 @@ | ||
1562 | 24 | +# Use case Configuration for sof-soundwire card | ||
1563 | 25 | + | ||
1564 | 26 | +LibraryConfig.remap.Config { | ||
1565 | 27 | + ctl.default.map { | ||
1566 | 28 | + "name='Speaker Digital Switch'" { | ||
1567 | 29 | + "name='AMPL Speaker Switch'".vindex.0 0 | ||
1568 | 30 | + "name='AMPR Speaker Switch'".vindex.1 0 | ||
1569 | 31 | + } | ||
1570 | 32 | + "name='Speaker Digital Volume'" { | ||
1571 | 33 | + "name='AMPL Speaker Volume'".vindex.0 0 | ||
1572 | 34 | + "name='AMPR Speaker Volume'".vindex.1 0 | ||
1573 | 35 | + } | ||
1574 | 36 | + } | ||
1575 | 37 | +} | ||
1576 | 38 | + | ||
1577 | 39 | +SectionDevice."Speaker" { | ||
1578 | 40 | + Comment "Speaker" | ||
1579 | 41 | + | ||
1580 | 42 | + ConflictingDevice [ | ||
1581 | 43 | + "Headphones" | ||
1582 | 44 | + ] | ||
1583 | 45 | + | ||
1584 | 46 | + EnableSequence [ | ||
1585 | 47 | + cset "name='cs42l43 Speaker L Input 1' 'ASPRX1'" | ||
1586 | 48 | + cset "name='cs42l43 Speaker R Input 1' 'ASPRX2'" | ||
1587 | 49 | + cset "name='cs42l43 ASPTX1 Input' 'DP5RX1'" | ||
1588 | 50 | + cset "name='cs42l43 ASPTX2 Input' 'DP5RX2'" | ||
1589 | 51 | + | ||
1590 | 52 | + cset "name='AMPL ASP1 TX1 Source' 'DSP1TX1'" | ||
1591 | 53 | + cset "name='AMPL ASP1 TX2 Source' 'None'" | ||
1592 | 54 | + cset "name='AMPL ASP1 TX3 Source' 'None'" | ||
1593 | 55 | + cset "name='AMPL ASP1 TX4 Source' 'None'" | ||
1594 | 56 | + | ||
1595 | 57 | + cset "name='AMPR ASP1 TX1 Source' 'None'" | ||
1596 | 58 | + cset "name='AMPR ASP1 TX2 Source' 'DSP1TX1'" | ||
1597 | 59 | + cset "name='AMPR ASP1 TX3 Source' 'None'" | ||
1598 | 60 | + cset "name='AMPR ASP1 TX4 Source' 'None'" | ||
1599 | 61 | + | ||
1600 | 62 | + cset "name='cs42l43 Speaker Digital Switch' 1" | ||
1601 | 63 | + cset "name='cs42l43 Speaker Digital Volume' 128" | ||
1602 | 64 | + ] | ||
1603 | 65 | + | ||
1604 | 66 | + DisableSequence [ | ||
1605 | 67 | + cset "name='cs42l43 Speaker Digital Switch' 0" | ||
1606 | 68 | + | ||
1607 | 69 | + cset "name='AMPL ASP1 TX2 Source' 'None'" | ||
1608 | 70 | + cset "name='AMPR ASP1 TX1 Source' 'None'" | ||
1609 | 71 | + | ||
1610 | 72 | + cset "name='cs42l43 ASPTX1 Input' 'None'" | ||
1611 | 73 | + cset "name='cs42l43 ASPTX2 Input' 'None'" | ||
1612 | 74 | + cset "name='cs42l43 Speaker L Input 1' 'None'" | ||
1613 | 75 | + cset "name='cs42l43 Speaker R Input 1' 'None'" | ||
1614 | 76 | + ] | ||
1615 | 77 | + | ||
1616 | 78 | + Value { | ||
1617 | 79 | + PlaybackPriority 100 | ||
1618 | 80 | + PlaybackPCM "hw:${CardId},0" | ||
1619 | 81 | + PlaybackMixer "default:${CardId}" | ||
1620 | 82 | + PlaybackMixerElem "Speaker Digital" | ||
1621 | 83 | + } | ||
1622 | 84 | +} | ||
1623 | 85 | --- a/ucm2/sof-soundwire/sof-soundwire.conf | ||
1624 | 86 | +++ b/ucm2/sof-soundwire/sof-soundwire.conf | ||
1625 | 87 | @@ -19,7 +19,7 @@ | ||
1626 | 88 | |||
1627 | 89 | DefineRegex { | ||
1628 | 90 | SpeakerCodec { | ||
1629 | 91 | - Regex " spk:([a-z0-9]+((-sdca)|(-spk))?)" | ||
1630 | 92 | + Regex " spk:([a-z0-9]+((-sdca)|(-spk)|(-bridge))?)" | ||
1631 | 93 | String "${CardComponents}" | ||
1632 | 94 | } | ||
1633 | 95 | SpeakerChannels { | ||
1634 | diff --git a/debian/patches/0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch b/debian/patches/0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch | |||
1635 | 0 | new file mode 100644 | 96 | new file mode 100644 |
1636 | index 0000000..36f50d0 | |||
1637 | --- /dev/null | |||
1638 | +++ b/debian/patches/0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch | |||
1639 | @@ -0,0 +1,30 @@ | |||
1640 | 1 | From: Jaroslav Kysela <perex@perex.cz> | ||
1641 | 2 | Date: Mon, 11 Mar 2024 12:06:44 +0100 | ||
1642 | 3 | Subject: sof-soundwire: fix rt1318 config copy-n-paste error in rt1318spk | ||
1643 | 4 | macro | ||
1644 | 5 | |||
1645 | 6 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1646 | 7 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/4e0fcc79b7d517a957e12f02ecae5f3c69fa94dc | ||
1647 | 8 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
1648 | 9 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
1649 | 10 | --- | ||
1650 | 11 | ucm2/sof-soundwire/rt1318.conf | 6 +++--- | ||
1651 | 12 | 1 file changed, 3 insertions(+), 3 deletions(-) | ||
1652 | 13 | |||
1653 | 14 | --- a/ucm2/sof-soundwire/rt1318.conf | ||
1654 | 15 | +++ b/ucm2/sof-soundwire/rt1318.conf | ||
1655 | 16 | @@ -14,11 +14,11 @@ | ||
1656 | 17 | } | ||
1657 | 18 | True { | ||
1658 | 19 | EnableSequence [ | ||
1659 | 20 | - cset "name='rt1308-${var:__Amp} RX Channel Select' ${var:__Sel}" | ||
1660 | 21 | - cset "name='rt1308-${var:__Amp} DAC Switch' 1" | ||
1661 | 22 | + cset "name='rt1318-${var:__Amp} RX Channel Select' ${var:__Sel}" | ||
1662 | 23 | + cset "name='rt1318-${var:__Amp} DAC Switch' 1" | ||
1663 | 24 | ] | ||
1664 | 25 | DisableSequence [ | ||
1665 | 26 | - cset "name='rt1308-${var:__Amp} DAC Switch' 0" | ||
1666 | 27 | + cset "name='rt1318-${var:__Amp} DAC Switch' 0" | ||
1667 | 28 | ] | ||
1668 | 29 | } | ||
1669 | 30 | } | ||
1670 | diff --git a/debian/patches/0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch b/debian/patches/0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch | |||
1671 | 0 | new file mode 100644 | 31 | new file mode 100644 |
1672 | index 0000000..6df8bfe | |||
1673 | --- /dev/null | |||
1674 | +++ b/debian/patches/0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch | |||
1675 | @@ -0,0 +1,243 @@ | |||
1676 | 1 | From 5e75929e8a487498e24db27023be0b57bac222b0 Mon Sep 17 00:00:00 2001 | ||
1677 | 2 | From: Zoran Zhan <zoran.zhan@mediatek.com> | ||
1678 | 3 | Date: Thu, 1 Jun 2023 15:48:33 +0800 | ||
1679 | 4 | Subject: [PATCH 2/3] ucm2: MediaTek: mt8395-evk: Add alsa-ucm support | ||
1680 | 5 | |||
1681 | 6 | Add alsa-ucm support for the MediaTek mt8395-evk platform. | ||
1682 | 7 | |||
1683 | 8 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/322 | ||
1684 | 9 | Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com> | ||
1685 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1686 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/5e75929e8a487498e24db27023be0b57bac222b0 | ||
1687 | 12 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2051199 | ||
1688 | 13 | --- | ||
1689 | 14 | ucm2/MediaTek/mt8395-evk/HiFi.conf | 154 +++++++++++++++++++++++ | ||
1690 | 15 | ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | 46 +++++++ | ||
1691 | 16 | ucm2/conf.d/mt8395-evk/mt8395-evk.conf | 1 + | ||
1692 | 17 | 3 files changed, 201 insertions(+) | ||
1693 | 18 | create mode 100644 ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
1694 | 19 | create mode 100644 ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
1695 | 20 | create mode 120000 ucm2/conf.d/mt8395-evk/mt8395-evk.conf | ||
1696 | 21 | |||
1697 | 22 | diff --git a/ucm2/MediaTek/mt8395-evk/HiFi.conf b/ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
1698 | 23 | new file mode 100644 | ||
1699 | 24 | index 0000000..81e4423 | ||
1700 | 25 | --- /dev/null | ||
1701 | 26 | +++ b/ucm2/MediaTek/mt8395-evk/HiFi.conf | ||
1702 | 27 | @@ -0,0 +1,154 @@ | ||
1703 | 28 | +SectionDevice."HDMI1" { | ||
1704 | 29 | + Comment "HDMI output" | ||
1705 | 30 | + | ||
1706 | 31 | + Value { | ||
1707 | 32 | + PlaybackPriority 200 | ||
1708 | 33 | + PlaybackPCM "hw:${CardId},5" | ||
1709 | 34 | + JackControl "HDMI Jack" | ||
1710 | 35 | + } | ||
1711 | 36 | + | ||
1712 | 37 | + EnableSequence [ | ||
1713 | 38 | + cset "name='HDMI_OUT_MUX' 1" | ||
1714 | 39 | + ] | ||
1715 | 40 | + | ||
1716 | 41 | + DisableSequence [ | ||
1717 | 42 | + cset "name='HDMI_OUT_MUX' 0" | ||
1718 | 43 | + ] | ||
1719 | 44 | +} | ||
1720 | 45 | + | ||
1721 | 46 | +SectionDevice."HDMI2" { | ||
1722 | 47 | + Comment "DP output" | ||
1723 | 48 | + | ||
1724 | 49 | + Value { | ||
1725 | 50 | + PlaybackPriority 200 | ||
1726 | 51 | + PlaybackPCM "hw:${CardId},5" | ||
1727 | 52 | + JackControl "DP Jack" | ||
1728 | 53 | + } | ||
1729 | 54 | + | ||
1730 | 55 | + EnableSequence [ | ||
1731 | 56 | + cset "name='DPTX_OUT_MUX' 1" | ||
1732 | 57 | + ] | ||
1733 | 58 | + | ||
1734 | 59 | + DisableSequence [ | ||
1735 | 60 | + cset "name='DPTX_OUT_MUX' 0" | ||
1736 | 61 | + ] | ||
1737 | 62 | +} | ||
1738 | 63 | + | ||
1739 | 64 | +SectionDevice."Speaker" { | ||
1740 | 65 | + Comment "Lineout speaker" | ||
1741 | 66 | + | ||
1742 | 67 | + ConflictingDevice [ | ||
1743 | 68 | + "Headphones" | ||
1744 | 69 | + ] | ||
1745 | 70 | + | ||
1746 | 71 | + EnableSequence [ | ||
1747 | 72 | + cset "name='LOL Mux' Playback_L_DAC" | ||
1748 | 73 | + ] | ||
1749 | 74 | + | ||
1750 | 75 | + DisableSequence [ | ||
1751 | 76 | + cset "name='LOL Mux' Open" | ||
1752 | 77 | + ] | ||
1753 | 78 | + | ||
1754 | 79 | + Value { | ||
1755 | 80 | + PlaybackPriority 300 | ||
1756 | 81 | + PlaybackChannels 2 | ||
1757 | 82 | + PlaybackPCM "hw:${CardId},0" | ||
1758 | 83 | + } | ||
1759 | 84 | +} | ||
1760 | 85 | + | ||
1761 | 86 | +SectionDevice."Headphones" { | ||
1762 | 87 | + Comment "Earphone speaker" | ||
1763 | 88 | + | ||
1764 | 89 | + ConflictingDevice [ | ||
1765 | 90 | + "Speaker" | ||
1766 | 91 | + ] | ||
1767 | 92 | + | ||
1768 | 93 | + EnableSequence [ | ||
1769 | 94 | + cset "name='HP Mux' Audio Playback" | ||
1770 | 95 | + ] | ||
1771 | 96 | + | ||
1772 | 97 | + DisableSequence [ | ||
1773 | 98 | + cset "name='HP Mux' Open" | ||
1774 | 99 | + ] | ||
1775 | 100 | + | ||
1776 | 101 | + Value { | ||
1777 | 102 | + PlaybackPriority 400 | ||
1778 | 103 | + PlaybackChannels 2 | ||
1779 | 104 | + PlaybackPCM "hw:${CardId},0" | ||
1780 | 105 | + } | ||
1781 | 106 | +} | ||
1782 | 107 | + | ||
1783 | 108 | +SectionDevice."Headset" { | ||
1784 | 109 | + Comment "Earphone microphone" | ||
1785 | 110 | + | ||
1786 | 111 | + ConflictingDevice [ | ||
1787 | 112 | + "Mic1" | ||
1788 | 113 | + ] | ||
1789 | 114 | + | ||
1790 | 115 | + EnableSequence [ | ||
1791 | 116 | + cset "name='PGA_L_Mux' AIN1" | ||
1792 | 117 | + ] | ||
1793 | 118 | + | ||
1794 | 119 | + Value { | ||
1795 | 120 | + CapturePriority 400 | ||
1796 | 121 | + CaptureChannels 3 | ||
1797 | 122 | + CapturePCM "hw:${CardId},15" | ||
1798 | 123 | + } | ||
1799 | 124 | +} | ||
1800 | 125 | + | ||
1801 | 126 | +SectionDevice."Mic1" { | ||
1802 | 127 | + Comment "Analog microphone" | ||
1803 | 128 | + | ||
1804 | 129 | + ConflictingDevice [ | ||
1805 | 130 | + "Headset" | ||
1806 | 131 | + ] | ||
1807 | 132 | + | ||
1808 | 133 | + EnableSequence [ | ||
1809 | 134 | + cset "name='PGA_L_Mux' AIN0" | ||
1810 | 135 | + cset "name='O039 I169 Switch' on" | ||
1811 | 136 | + cset "name='O182 I170 Switch' on" | ||
1812 | 137 | + cset "name='MISO1_MUX' UL1_CH2" | ||
1813 | 138 | + ] | ||
1814 | 139 | + | ||
1815 | 140 | + DisableSequence [ | ||
1816 | 141 | + cset "name='O039 I169 Switch' off" | ||
1817 | 142 | + cset "name='O182 I170 Switch' off" | ||
1818 | 143 | + cset "name='MISO1_MUX' UL1_CH1" | ||
1819 | 144 | + ] | ||
1820 | 145 | + | ||
1821 | 146 | + Value { | ||
1822 | 147 | + CapturePriority 300 | ||
1823 | 148 | + CaptureChannels 3 | ||
1824 | 149 | + CapturePCM "hw:${CardId},15" | ||
1825 | 150 | + } | ||
1826 | 151 | +} | ||
1827 | 152 | + | ||
1828 | 153 | +SectionDevice."Mic2" { | ||
1829 | 154 | + Comment "Digital microphone" | ||
1830 | 155 | + | ||
1831 | 156 | + Value { | ||
1832 | 157 | + CapturePriority 200 | ||
1833 | 158 | + CaptureChannels 2 | ||
1834 | 159 | + CapturePCM "hw:${CardId},14" | ||
1835 | 160 | + } | ||
1836 | 161 | +} | ||
1837 | 162 | + | ||
1838 | 163 | +SectionDevice."Line1" { | ||
1839 | 164 | + Comment "PCM input" | ||
1840 | 165 | + | ||
1841 | 166 | + Value { | ||
1842 | 167 | + CapturePriority 100 | ||
1843 | 168 | + CaptureChannels 2 | ||
1844 | 169 | + CapturePCM "hw:${CardId},8" | ||
1845 | 170 | + } | ||
1846 | 171 | +} | ||
1847 | 172 | + | ||
1848 | 173 | +SectionDevice."Line2" { | ||
1849 | 174 | + Comment "PCM output" | ||
1850 | 175 | + | ||
1851 | 176 | + Value { | ||
1852 | 177 | + PlaybackPriority 100 | ||
1853 | 178 | + PlaybackChannels 2 | ||
1854 | 179 | + PlaybackPCM "hw:${CardId},2" | ||
1855 | 180 | + } | ||
1856 | 181 | +} | ||
1857 | 182 | \ No newline at end of file | ||
1858 | 183 | diff --git a/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf b/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
1859 | 184 | new file mode 100644 | ||
1860 | 185 | index 0000000..1957b69 | ||
1861 | 186 | --- /dev/null | ||
1862 | 187 | +++ b/ucm2/MediaTek/mt8395-evk/mt8395-evk.conf | ||
1863 | 188 | @@ -0,0 +1,46 @@ | ||
1864 | 189 | +Syntax 4 | ||
1865 | 190 | + | ||
1866 | 191 | +SectionUseCase."HiFi" { | ||
1867 | 192 | + File "/MediaTek/mt8395-evk/HiFi.conf" | ||
1868 | 193 | + Comment "Play high quality music" | ||
1869 | 194 | +} | ||
1870 | 195 | + | ||
1871 | 196 | +BootSequence [ | ||
1872 | 197 | + cset "name='HP Mux' Audio Playback" | ||
1873 | 198 | + cset "name='LOL Mux' Open" | ||
1874 | 199 | + cset "name='MISO0_MUX' UL1_CH1" | ||
1875 | 200 | + cset "name='MISO1_MUX' UL1_CH1" | ||
1876 | 201 | + cset "name='ADC_L_Mux' Left Preamplifier" | ||
1877 | 202 | + cset "name='ADC_R_Mux' Right Preamplifier" | ||
1878 | 203 | + cset "name='ADC_3_Mux' Preamplifier" | ||
1879 | 204 | + cset "name='PGA_L_Mux' AIN1" | ||
1880 | 205 | + cset "name='PGA_R_Mux' AIN2" | ||
1881 | 206 | + cset "name='PGA_3_Mux' AIN3" | ||
1882 | 207 | + cset "name='HDMI_OUT_MUX' Connect" | ||
1883 | 208 | + cset "name='DPTX_OUT_MUX' Disconnect" | ||
1884 | 209 | + cset "name='Lineout Volume' 10" | ||
1885 | 210 | + cset "name='Headset Volume' 2" | ||
1886 | 211 | + cset "name='PGA1 Volume' 4" | ||
1887 | 212 | + cset "name='PGA2 Volume' 4" | ||
1888 | 213 | + cset "name='PGA3 Volume' 4" | ||
1889 | 214 | + cset "name='O000 I000 Switch' on" | ||
1890 | 215 | + cset "name='O001 I001 Switch' on" | ||
1891 | 216 | + cset "name='O002 I004 Switch' on" | ||
1892 | 217 | + cset "name='O003 I005 Switch' on" | ||
1893 | 218 | + cset "name='O004 I006 Switch' on" | ||
1894 | 219 | + cset "name='O005 I007 Switch' on" | ||
1895 | 220 | + cset "name='O006 I008 Switch' on" | ||
1896 | 221 | + cset "name='O007 I009 Switch' on" | ||
1897 | 222 | + cset "name='O008 I010 Switch' on" | ||
1898 | 223 | + cset "name='O009 I011 Switch' on" | ||
1899 | 224 | + cset "name='O034 I168 Switch' on" | ||
1900 | 225 | + cset "name='O035 I169 Switch' on" | ||
1901 | 226 | + cset "name='O038 I168 Switch' on" | ||
1902 | 227 | + cset "name='O039 I169 Switch' on" | ||
1903 | 228 | + cset "name='O040 I002 Switch' on" | ||
1904 | 229 | + cset "name='O041 I003 Switch' on" | ||
1905 | 230 | + cset "name='O176 I070 Switch' on" | ||
1906 | 231 | + cset "name='O177 I071 Switch' on" | ||
1907 | 232 | + cset "name='O182 I170 Switch' on" | ||
1908 | 233 | + cset "name='O183 I171 Switch' on" | ||
1909 | 234 | +] | ||
1910 | 235 | diff --git a/ucm2/conf.d/mt8395-evk/mt8395-evk.conf b/ucm2/conf.d/mt8395-evk/mt8395-evk.conf | ||
1911 | 236 | new file mode 120000 | ||
1912 | 237 | index 0000000..30557e3 | ||
1913 | 238 | --- /dev/null | ||
1914 | 239 | +++ b/ucm2/conf.d/mt8395-evk/mt8395-evk.conf | ||
1915 | 240 | @@ -0,0 +1 @@ | ||
1916 | 241 | +../../MediaTek/mt8395-evk/mt8395-evk.conf | ||
1917 | 242 | \ No newline at end of file | ||
1918 | 243 | -- | ||
1919 | diff --git a/debian/patches/0003-sof-soundwire-Add-basic-support-for-cs42l43.patch b/debian/patches/0003-sof-soundwire-Add-basic-support-for-cs42l43.patch | |||
1920 | 0 | new file mode 100644 | 244 | new file mode 100644 |
1921 | index 0000000..1f47bac | |||
1922 | --- /dev/null | |||
1923 | +++ b/debian/patches/0003-sof-soundwire-Add-basic-support-for-cs42l43.patch | |||
1924 | @@ -0,0 +1,128 @@ | |||
1925 | 1 | From: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1926 | 2 | Date: Wed, 17 Jan 2024 14:21:25 +0000 | ||
1927 | 3 | Subject: [PATCH 3/3] sof-soundwire: Add basic support for cs42l43 | ||
1928 | 4 | |||
1929 | 5 | cs42l43 is a codec device, add basic support for it. Including a dual | ||
1930 | 6 | channel DMIC input, stereo headphones, and a mono headset microphone. | ||
1931 | 7 | |||
1932 | 8 | Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> | ||
1933 | 9 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
1934 | 10 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/e87dde51d68950537f92af955ad0633437cc419a | ||
1935 | 11 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
1936 | 12 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
1937 | 13 | --- | ||
1938 | 14 | ucm2/codecs/cs42l43/init.conf | 14 +++++++++++ | ||
1939 | 15 | ucm2/sof-soundwire/cs42l43-dmic.conf | 26 ++++++++++++++++++++ | ||
1940 | 16 | ucm2/sof-soundwire/cs42l43.conf | 46 +++++++++++++++++++++++++++++++++++ | ||
1941 | 17 | ucm2/sof-soundwire/sof-soundwire.conf | 2 +- | ||
1942 | 18 | 4 files changed, 87 insertions(+), 1 deletion(-) | ||
1943 | 19 | create mode 100644 ucm2/codecs/cs42l43/init.conf | ||
1944 | 20 | create mode 100644 ucm2/sof-soundwire/cs42l43-dmic.conf | ||
1945 | 21 | create mode 100644 ucm2/sof-soundwire/cs42l43.conf | ||
1946 | 22 | |||
1947 | 23 | --- /dev/null | ||
1948 | 24 | +++ b/ucm2/codecs/cs42l43/init.conf | ||
1949 | 25 | @@ -0,0 +1,14 @@ | ||
1950 | 26 | +# cs42l43 specific control settings | ||
1951 | 27 | + | ||
1952 | 28 | +LibraryConfig.remap.Config { | ||
1953 | 29 | + ctl.default.map { | ||
1954 | 30 | + "name='cs42l43 PDM2 Switch'" { | ||
1955 | 31 | + "name='cs42l43 Decimator 3 Switch'".vindex.0 0 | ||
1956 | 32 | + "name='cs42l43 Decimator 4 Switch'".vindex.1 0 | ||
1957 | 33 | + } | ||
1958 | 34 | + "name='cs42l43 PDM2 Volume'" { | ||
1959 | 35 | + "name='cs42l43 Decimator 3 Volume'".vindex.0 0 | ||
1960 | 36 | + "name='cs42l43 Decimator 4 Volume'".vindex.1 0 | ||
1961 | 37 | + } | ||
1962 | 38 | + } | ||
1963 | 39 | +} | ||
1964 | 40 | --- /dev/null | ||
1965 | 41 | +++ b/ucm2/sof-soundwire/cs42l43-dmic.conf | ||
1966 | 42 | @@ -0,0 +1,26 @@ | ||
1967 | 43 | +# Use case Configuration for sof-soundwire card | ||
1968 | 44 | + | ||
1969 | 45 | +SectionDevice."Mic" { | ||
1970 | 46 | + Comment "Microphones" | ||
1971 | 47 | + | ||
1972 | 48 | + ConflictingDevice [ | ||
1973 | 49 | + "Headset" | ||
1974 | 50 | + ] | ||
1975 | 51 | + | ||
1976 | 52 | + EnableSequence [ | ||
1977 | 53 | + cset "name='cs42l43 DP1TX1 Input' 'Decimator 3'" | ||
1978 | 54 | + cset "name='cs42l43 DP1TX2 Input' 'Decimator 4'" | ||
1979 | 55 | + ] | ||
1980 | 56 | + | ||
1981 | 57 | + DisableSequence [ | ||
1982 | 58 | + cset "name='cs42l43 DP1TX1 Input' 'None'" | ||
1983 | 59 | + cset "name='cs42l43 DP1TX2 Input' 'None'" | ||
1984 | 60 | + ] | ||
1985 | 61 | + | ||
1986 | 62 | + Value { | ||
1987 | 63 | + CapturePriority 100 | ||
1988 | 64 | + CapturePCM "hw:${CardId},4" | ||
1989 | 65 | + CaptureMixer "default:${CardId}" | ||
1990 | 66 | + CaptureMixerElem "cs42l43 PDM2" | ||
1991 | 67 | + } | ||
1992 | 68 | +} | ||
1993 | 69 | --- /dev/null | ||
1994 | 70 | +++ b/ucm2/sof-soundwire/cs42l43.conf | ||
1995 | 71 | @@ -0,0 +1,46 @@ | ||
1996 | 72 | +# Use case Configuration for sof-soundwire card | ||
1997 | 73 | + | ||
1998 | 74 | +SectionDevice."Headphones" { | ||
1999 | 75 | + Comment "Headphones" | ||
2000 | 76 | + | ||
2001 | 77 | + EnableSequence [ | ||
2002 | 78 | + cset "name='cs42l43 Headphone L Input 1' 'DP5RX1'" | ||
2003 | 79 | + cset "name='cs42l43 Headphone R Input 1' 'DP5RX2'" | ||
2004 | 80 | + ] | ||
2005 | 81 | + | ||
2006 | 82 | + DisableSequence [ | ||
2007 | 83 | + cset "name='cs42l43 Headphone L Input 1' 'None'" | ||
2008 | 84 | + cset "name='cs42l43 Headphone R Input 1' 'None'" | ||
2009 | 85 | + ] | ||
2010 | 86 | + | ||
2011 | 87 | + Value { | ||
2012 | 88 | + PlaybackPriority 200 | ||
2013 | 89 | + PlaybackPCM "hw:${CardId},0" | ||
2014 | 90 | + PlaybackVolume "cs42l43 Headphone Digital Volume" | ||
2015 | 91 | + JackControl "Headphone Jack" | ||
2016 | 92 | + } | ||
2017 | 93 | +} | ||
2018 | 94 | + | ||
2019 | 95 | +SectionDevice."Headset" { | ||
2020 | 96 | + Comment "Headset Microphone" | ||
2021 | 97 | + | ||
2022 | 98 | + EnableSequence [ | ||
2023 | 99 | + cset "name='cs42l43 ADC1 Input' 'IN1'" | ||
2024 | 100 | + cset "name='cs42l43 Decimator 1 Mode' 'ADC'" | ||
2025 | 101 | + | ||
2026 | 102 | + cset "name='cs42l43 DP1TX1 Input' 'Decimator 1'" | ||
2027 | 103 | + cset "name='cs42l43 DP1TX2 Input' 'Decimator 1'" | ||
2028 | 104 | + ] | ||
2029 | 105 | + | ||
2030 | 106 | + DisableSequence [ | ||
2031 | 107 | + cset "name='cs42l43 DP1TX1 Input' 'None'" | ||
2032 | 108 | + cset "name='cs42l43 DP1TX2 Input' 'None'" | ||
2033 | 109 | + ] | ||
2034 | 110 | + | ||
2035 | 111 | + Value { | ||
2036 | 112 | + CapturePriority 200 | ||
2037 | 113 | + CapturePCM "hw:${CardId},4" | ||
2038 | 114 | + CaptureMixerElem "cs42l43 Decimator 1" | ||
2039 | 115 | + JackControl "Headset Mic Jack" | ||
2040 | 116 | + } | ||
2041 | 117 | +} | ||
2042 | 118 | --- a/ucm2/sof-soundwire/sof-soundwire.conf | ||
2043 | 119 | +++ b/ucm2/sof-soundwire/sof-soundwire.conf | ||
2044 | 120 | @@ -47,7 +47,7 @@ | ||
2045 | 121 | If.hs_init { | ||
2046 | 122 | Condition { | ||
2047 | 123 | Type RegexMatch | ||
2048 | 124 | - Regex "(rt5682|rt700|rt711|rt713(-sdca)?)" | ||
2049 | 125 | + Regex "(cs42l43|rt5682|rt700|rt711|rt713(-sdca)?)" | ||
2050 | 126 | String "${var:HeadsetCodec1}" | ||
2051 | 127 | } | ||
2052 | 128 | True.Include.hs_init.File "/codecs/${var:HeadsetCodec1}/init.conf" | ||
2053 | diff --git a/debian/patches/0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch b/debian/patches/0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch | |||
2054 | 0 | new file mode 100644 | 129 | new file mode 100644 |
2055 | index 0000000..54840df | |||
2056 | --- /dev/null | |||
2057 | +++ b/debian/patches/0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch | |||
2058 | @@ -0,0 +1,36 @@ | |||
2059 | 1 | From: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> | ||
2060 | 2 | Date: Mon, 11 Mar 2024 11:02:00 +0200 | ||
2061 | 3 | Subject: sof-soundwire: rt1308: Fix single amp configuration | ||
2062 | 4 | |||
2063 | 5 | If the device have single rt1308 amp then the codec's Channel Select should | ||
2064 | 6 | be set to "LR" and not to "LL". "LL" is only valid if we have 2 amps, in | ||
2065 | 7 | that case one is the Left and the other is the Right channel. | ||
2066 | 8 | |||
2067 | 9 | This fixes for example Dell Latitude 9520 which only played on the Left | ||
2068 | 10 | speaker, Right is silent. | ||
2069 | 11 | |||
2070 | 12 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/402 | ||
2071 | 13 | Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> | ||
2072 | 14 | Suggested-by: Jaroslav Kysela <perex@perex.cz> | ||
2073 | 15 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
2074 | 16 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/9e29f9e27f4e27dce40d8d6803031bb4f7be3c48 | ||
2075 | 17 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
2076 | 18 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
2077 | 19 | --- | ||
2078 | 20 | ucm2/sof-soundwire/rt1308.conf | 5 +++-- | ||
2079 | 21 | 1 file changed, 3 insertions(+), 2 deletions(-) | ||
2080 | 22 | |||
2081 | 23 | --- a/ucm2/sof-soundwire/rt1308.conf | ||
2082 | 24 | +++ b/ucm2/sof-soundwire/rt1308.conf | ||
2083 | 25 | @@ -28,8 +28,9 @@ | ||
2084 | 26 | SectionDevice."Speaker" { | ||
2085 | 27 | Comment "Speaker" | ||
2086 | 28 | |||
2087 | 29 | - Macro.num1.rt1308spk { ForAmps "[12]" Amp 1 Sel LL } | ||
2088 | 30 | - Macro.num2.rt1308spk { ForAmps "2" Amp 2 Sel RR } | ||
2089 | 31 | + Macro.num1.rt1308spk { ForAmps "1" Amp 1 Sel LR } | ||
2090 | 32 | + Macro.num2.rt1308spk { ForAmps "2" Amp 1 Sel LL } | ||
2091 | 33 | + Macro.num3.rt1308spk { ForAmps "2" Amp 2 Sel RR } | ||
2092 | 34 | |||
2093 | 35 | EnableSequence [ | ||
2094 | 36 | cset "name='Speaker Switch' on" | ||
2095 | diff --git a/debian/patches/0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch b/debian/patches/0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch | |||
2096 | 0 | new file mode 100644 | 37 | new file mode 100644 |
2097 | index 0000000..89126cb | |||
2098 | --- /dev/null | |||
2099 | +++ b/debian/patches/0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch | |||
2100 | @@ -0,0 +1,253 @@ | |||
2101 | 1 | From a0856afae4e8e071e7626958667cde049ec81e97 Mon Sep 17 00:00:00 2001 | ||
2102 | 2 | From: Zoran Zhan <zoran.zhan@mediatek.com> | ||
2103 | 3 | Date: Wed, 10 Jan 2024 20:16:17 +0800 | ||
2104 | 4 | Subject: [PATCH 3/3] ucm2: MediaTek: mt8370-evk: Add alsa-ucm support | ||
2105 | 5 | |||
2106 | 6 | Add alsa-ucm support for the MediaTek mt8370-evk platform. | ||
2107 | 7 | |||
2108 | 8 | Closes: https://github.com/alsa-project/alsa-ucm-conf/pull/380 | ||
2109 | 9 | Signed-off-by: Zoran Zhan <zoran.zhan@mediatek.com> | ||
2110 | 10 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
2111 | 11 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commit/a0856afae4e8e071e7626958667cde049ec81e97 | ||
2112 | 12 | Bug: https://bugs.launchpad.net/ubuntu/+source/alsa-ucm-conf/+bug/2051199 | ||
2113 | 13 | --- | ||
2114 | 14 | ucm2/MediaTek/mt8370-evk/HiFi.conf | 165 +++++++++++++++++++++++ | ||
2115 | 15 | ucm2/MediaTek/mt8370-evk/mt8370-evk.conf | 45 +++++++ | ||
2116 | 16 | ucm2/conf.d/mt8370-evk/mt8370-evk.conf | 1 + | ||
2117 | 17 | 3 files changed, 211 insertions(+) | ||
2118 | 18 | create mode 100644 ucm2/MediaTek/mt8370-evk/HiFi.conf | ||
2119 | 19 | create mode 100644 ucm2/MediaTek/mt8370-evk/mt8370-evk.conf | ||
2120 | 20 | create mode 100644 ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
2121 | 21 | |||
2122 | 22 | diff --git a/ucm2/MediaTek/mt8370-evk/HiFi.conf b/ucm2/MediaTek/mt8370-evk/HiFi.conf | ||
2123 | 23 | new file mode 100644 | ||
2124 | 24 | index 0000000..42a4582 | ||
2125 | 25 | --- /dev/null | ||
2126 | 26 | +++ b/ucm2/MediaTek/mt8370-evk/HiFi.conf | ||
2127 | 27 | @@ -0,0 +1,165 @@ | ||
2128 | 28 | +SectionDevice."HDMI1" { | ||
2129 | 29 | + Comment "HDMI output" | ||
2130 | 30 | + | ||
2131 | 31 | + Value { | ||
2132 | 32 | + PlaybackPriority 300 | ||
2133 | 33 | + PlaybackPCM "hw:${CardId},5" | ||
2134 | 34 | + JackControl "HDMI Jack" | ||
2135 | 35 | + } | ||
2136 | 36 | + | ||
2137 | 37 | + EnableSequence [ | ||
2138 | 38 | + cset "name='HDMI_OUT_MUX' 1" | ||
2139 | 39 | + ] | ||
2140 | 40 | + | ||
2141 | 41 | + DisableSequence [ | ||
2142 | 42 | + cset "name='HDMI_OUT_MUX' 0" | ||
2143 | 43 | + ] | ||
2144 | 44 | +} | ||
2145 | 45 | + | ||
2146 | 46 | +SectionDevice."HDMI2" { | ||
2147 | 47 | + Comment "DP output" | ||
2148 | 48 | + | ||
2149 | 49 | + Value { | ||
2150 | 50 | + PlaybackPriority 300 | ||
2151 | 51 | + PlaybackPCM "hw:${CardId},5" | ||
2152 | 52 | + JackControl "DP Jack" | ||
2153 | 53 | + } | ||
2154 | 54 | + | ||
2155 | 55 | + EnableSequence [ | ||
2156 | 56 | + cset "name='DPTX_OUT_MUX' 1" | ||
2157 | 57 | + ] | ||
2158 | 58 | + | ||
2159 | 59 | + DisableSequence [ | ||
2160 | 60 | + cset "name='DPTX_OUT_MUX' 0" | ||
2161 | 61 | + ] | ||
2162 | 62 | +} | ||
2163 | 63 | + | ||
2164 | 64 | +SectionDevice."Speaker" { | ||
2165 | 65 | + Comment "Lineout speaker" | ||
2166 | 66 | + | ||
2167 | 67 | + ConflictingDevice [ | ||
2168 | 68 | + "Headphones" | ||
2169 | 69 | + ] | ||
2170 | 70 | + | ||
2171 | 71 | + EnableSequence [ | ||
2172 | 72 | + cset "name='LOL Mux' Playback_L_DAC" | ||
2173 | 73 | + ] | ||
2174 | 74 | + | ||
2175 | 75 | + DisableSequence [ | ||
2176 | 76 | + cset "name='LOL Mux' Open" | ||
2177 | 77 | + ] | ||
2178 | 78 | + | ||
2179 | 79 | + Value { | ||
2180 | 80 | + PlaybackPriority 400 | ||
2181 | 81 | + PlaybackChannels 2 | ||
2182 | 82 | + PlaybackPCM "hw:${CardId},0" | ||
2183 | 83 | + } | ||
2184 | 84 | +} | ||
2185 | 85 | + | ||
2186 | 86 | +SectionDevice."Headphones" { | ||
2187 | 87 | + Comment "Earphone speaker" | ||
2188 | 88 | + | ||
2189 | 89 | + ConflictingDevice [ | ||
2190 | 90 | + "Speaker" | ||
2191 | 91 | + ] | ||
2192 | 92 | + | ||
2193 | 93 | + EnableSequence [ | ||
2194 | 94 | + cset "name='HP Mux' Audio Playback" | ||
2195 | 95 | + ] | ||
2196 | 96 | + | ||
2197 | 97 | + DisableSequence [ | ||
2198 | 98 | + cset "name='HP Mux' Open" | ||
2199 | 99 | + ] | ||
2200 | 100 | + | ||
2201 | 101 | + Value { | ||
2202 | 102 | + PlaybackPriority 500 | ||
2203 | 103 | + PlaybackChannels 2 | ||
2204 | 104 | + PlaybackPCM "hw:${CardId},0" | ||
2205 | 105 | + } | ||
2206 | 106 | +} | ||
2207 | 107 | + | ||
2208 | 108 | +SectionDevice."Headset" { | ||
2209 | 109 | + Comment "Earphone microphone" | ||
2210 | 110 | + | ||
2211 | 111 | + ConflictingDevice [ | ||
2212 | 112 | + "Mic1" | ||
2213 | 113 | + ] | ||
2214 | 114 | + | ||
2215 | 115 | + EnableSequence [ | ||
2216 | 116 | + cset "name='PGA_L_Mux' AIN1" | ||
2217 | 117 | + ] | ||
2218 | 118 | + | ||
2219 | 119 | + Value { | ||
2220 | 120 | + CapturePriority 500 | ||
2221 | 121 | + CaptureChannels 1 | ||
2222 | 122 | + CapturePCM "hw:${CardId},10" | ||
2223 | 123 | + } | ||
2224 | 124 | +} | ||
2225 | 125 | + | ||
2226 | 126 | +SectionDevice."Mic1" { | ||
2227 | 127 | + Comment "Analog microphone" | ||
2228 | 128 | + | ||
2229 | 129 | + ConflictingDevice [ | ||
2230 | 130 | + "Headset" | ||
2231 | 131 | + ] | ||
2232 | 132 | + | ||
2233 | 133 | + EnableSequence [ | ||
2234 | 134 | + cset "name='PGA_L_Mux' AIN0" | ||
2235 | 135 | + ] | ||
2236 | 136 | + | ||
2237 | 137 | + Value { | ||
2238 | 138 | + CapturePriority 400 | ||
2239 | 139 | + CaptureChannels 1 | ||
2240 | 140 | + CapturePCM "hw:${CardId},10" | ||
2241 | 141 | + } | ||
2242 | 142 | +} | ||
2243 | 143 | + | ||
2244 | 144 | +SectionDevice."Mic2" { | ||
2245 | 145 | + Comment "Digital microphone" | ||
2246 | 146 | + | ||
2247 | 147 | + Value { | ||
2248 | 148 | + CapturePriority 300 | ||
2249 | 149 | + CaptureChannels 2 | ||
2250 | 150 | + CapturePCM "hw:${CardId},14" | ||
2251 | 151 | + } | ||
2252 | 152 | +} | ||
2253 | 153 | + | ||
2254 | 154 | +SectionDevice."Line1" { | ||
2255 | 155 | + Comment "PCM input" | ||
2256 | 156 | + | ||
2257 | 157 | + Value { | ||
2258 | 158 | + CapturePriority 200 | ||
2259 | 159 | + CaptureChannels 2 | ||
2260 | 160 | + CapturePCM "hw:${CardId},8" | ||
2261 | 161 | + } | ||
2262 | 162 | +} | ||
2263 | 163 | + | ||
2264 | 164 | +SectionDevice."Line2" { | ||
2265 | 165 | + Comment "PCM output" | ||
2266 | 166 | + | ||
2267 | 167 | + Value { | ||
2268 | 168 | + PlaybackPriority 200 | ||
2269 | 169 | + PlaybackChannels 2 | ||
2270 | 170 | + PlaybackPCM "hw:${CardId},2" | ||
2271 | 171 | + } | ||
2272 | 172 | +} | ||
2273 | 173 | + | ||
2274 | 174 | +SectionDevice."Line3" { | ||
2275 | 175 | + Comment "I2S input" | ||
2276 | 176 | + | ||
2277 | 177 | + Value { | ||
2278 | 178 | + CapturePriority 100 | ||
2279 | 179 | + CaptureChannels 2 | ||
2280 | 180 | + CapturePCM "hw:${CardId},11" | ||
2281 | 181 | + } | ||
2282 | 182 | +} | ||
2283 | 183 | + | ||
2284 | 184 | +SectionDevice."Line4" { | ||
2285 | 185 | + Comment "I2S output" | ||
2286 | 186 | + | ||
2287 | 187 | + Value { | ||
2288 | 188 | + PlaybackPriority 100 | ||
2289 | 189 | + PlaybackChannels 8 | ||
2290 | 190 | + PlaybackPCM "hw:${CardId},6" | ||
2291 | 191 | + } | ||
2292 | 192 | +} | ||
2293 | 193 | \ No newline at end of file | ||
2294 | 194 | diff --git a/ucm2/MediaTek/mt8370-evk/mt8370-evk.conf b/ucm2/MediaTek/mt8370-evk/mt8370-evk.conf | ||
2295 | 195 | new file mode 100644 | ||
2296 | 196 | index 0000000..2d07c46 | ||
2297 | 197 | --- /dev/null | ||
2298 | 198 | +++ b/ucm2/MediaTek/mt8370-evk/mt8370-evk.conf | ||
2299 | 199 | @@ -0,0 +1,45 @@ | ||
2300 | 200 | +Syntax 4 | ||
2301 | 201 | + | ||
2302 | 202 | +SectionUseCase."HiFi" { | ||
2303 | 203 | + File "/MediaTek/mt8370-evk/HiFi.conf" | ||
2304 | 204 | + Comment "Play high quality music" | ||
2305 | 205 | +} | ||
2306 | 206 | + | ||
2307 | 207 | +BootSequence [ | ||
2308 | 208 | + cset "name='HP Mux' Audio Playback" | ||
2309 | 209 | + cset "name='LOL Mux' Open" | ||
2310 | 210 | + cset "name='MISO0_MUX' UL1_CH1" | ||
2311 | 211 | + cset "name='MISO1_MUX' UL1_CH1" | ||
2312 | 212 | + cset "name='ADC_L_Mux' Left Preamplifier" | ||
2313 | 213 | + cset "name='PGA_L_Mux' AIN1" | ||
2314 | 214 | + cset "name='HDMI_OUT_MUX' Connect" | ||
2315 | 215 | + cset "name='DPTX_OUT_MUX' Disconnect" | ||
2316 | 216 | + cset "name='ETDM_OUT1_Clock_Source' a1sys_a2sys" | ||
2317 | 217 | + cset "name='ETDM_OUT2_Clock_Source' a1sys_a2sys" | ||
2318 | 218 | + cset "name='ETDM_OUT3_Clock_Source' a1sys_a2sys" | ||
2319 | 219 | + cset "name='ETDM_IN1_Clock_Source' a1sys_a2sys" | ||
2320 | 220 | + cset "name='ETDM_IN2_Clock_Source' a1sys_a2sys" | ||
2321 | 221 | + cset "name='Lineout Volume' 10" | ||
2322 | 222 | + cset "name='Headset Volume' 2" | ||
2323 | 223 | + cset "name='PGA1 Volume' 4" | ||
2324 | 224 | + cset "name='O000 I000 Switch' on" | ||
2325 | 225 | + cset "name='O001 I001 Switch' on" | ||
2326 | 226 | + cset "name='O002 I004 Switch' on" | ||
2327 | 227 | + cset "name='O003 I006 Switch' on" | ||
2328 | 228 | + cset "name='O034 I168 Switch' on" | ||
2329 | 229 | + cset "name='O035 I169 Switch' on" | ||
2330 | 230 | + cset "name='O036 I012 Switch' on" | ||
2331 | 231 | + cset "name='O037 I013 Switch' on" | ||
2332 | 232 | + cset "name='O040 I002 Switch' on" | ||
2333 | 233 | + cset "name='O041 I003 Switch' on" | ||
2334 | 234 | + cset "name='O048 I022 Switch' on" | ||
2335 | 235 | + cset "name='O049 I023 Switch' on" | ||
2336 | 236 | + cset "name='O050 I024 Switch' on" | ||
2337 | 237 | + cset "name='O051 I025 Switch' on" | ||
2338 | 238 | + cset "name='O052 I026 Switch' on" | ||
2339 | 239 | + cset "name='O053 I027 Switch' on" | ||
2340 | 240 | + cset "name='O054 I028 Switch' on" | ||
2341 | 241 | + cset "name='O055 I029 Switch' on" | ||
2342 | 242 | + cset "name='O176 I070 Switch' on" | ||
2343 | 243 | + cset "name='O177 I071 Switch' on" | ||
2344 | 244 | +] | ||
2345 | 245 | \ No newline at end of file | ||
2346 | 246 | diff --git a/ucm2/conf.d/mt8370-evk/mt8370-evk.conf b/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
2347 | 247 | new file mode 100644 | ||
2348 | 248 | index 0000000..6edb08f | ||
2349 | 249 | --- /dev/null | ||
2350 | 250 | +++ b/ucm2/conf.d/mt8370-evk/mt8370-evk.conf | ||
2351 | 251 | @@ -0,0 +1 @@ | ||
2352 | 252 | +../../MediaTek/mt8370-evk/mt8370-evk.conf | ||
2353 | 253 | -- | ||
2354 | diff --git a/debian/patches/0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch b/debian/patches/0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch | |||
2355 | 0 | new file mode 100644 | 254 | new file mode 100644 |
2356 | index 0000000..1a1344b | |||
2357 | --- /dev/null | |||
2358 | +++ b/debian/patches/0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch | |||
2359 | @@ -0,0 +1,44 @@ | |||
2360 | 1 | From: Jaroslav Kysela <perex@perex.cz> | ||
2361 | 2 | Date: Mon, 11 Mar 2024 13:09:08 +0100 | ||
2362 | 3 | Subject: sof-soundwire: rt1316/rt1318 - fix channel selection for one amp | ||
2363 | 4 | |||
2364 | 5 | Like in commit 9e29f9e27f4e27dce40d8d6803031bb4f7be3c48, use L-R | ||
2365 | 6 | channel selection when single amp is present. | ||
2366 | 7 | |||
2367 | 8 | Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ||
2368 | 9 | Origin: upstream, https://github.com/alsa-project/alsa-ucm-conf/commits/73981e94bb69da1be5b1e4a69ff99df28bcfb320 | ||
2369 | 10 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/2069760 | ||
2370 | 11 | Signed-off-by: Chris Chiu <chris.chiu@canonical.com> | ||
2371 | 12 | --- | ||
2372 | 13 | ucm2/sof-soundwire/rt1316.conf | 5 +++-- | ||
2373 | 14 | ucm2/sof-soundwire/rt1318.conf | 5 +++-- | ||
2374 | 15 | 2 files changed, 6 insertions(+), 4 deletions(-) | ||
2375 | 16 | |||
2376 | 17 | --- a/ucm2/sof-soundwire/rt1316.conf | ||
2377 | 18 | +++ b/ucm2/sof-soundwire/rt1316.conf | ||
2378 | 19 | @@ -47,8 +47,9 @@ | ||
2379 | 20 | SectionDevice."Speaker" { | ||
2380 | 21 | Comment "Speaker" | ||
2381 | 22 | |||
2382 | 23 | - Macro.num1.rt1316spk { ForAmps "[12]" Amp 1 Sel "L,L" } | ||
2383 | 24 | - Macro.num2.rt1316spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
2384 | 25 | + Macro.num1.rt1316spk { ForAmps "1" Amp 1 Sel "L,R" } | ||
2385 | 26 | + Macro.num2.rt1316spk { ForAmps "2" Amp 1 Sel "L,L" } | ||
2386 | 27 | + Macro.num3.rt1316spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
2387 | 28 | |||
2388 | 29 | EnableSequence [ | ||
2389 | 30 | cset "name='Speaker Switch' on" | ||
2390 | 31 | --- a/ucm2/sof-soundwire/rt1318.conf | ||
2391 | 32 | +++ b/ucm2/sof-soundwire/rt1318.conf | ||
2392 | 33 | @@ -26,8 +26,9 @@ | ||
2393 | 34 | SectionDevice."Speaker" { | ||
2394 | 35 | Comment "Speaker" | ||
2395 | 36 | |||
2396 | 37 | - Macro.num1.rt1318spk { ForAmps "[12]" Amp 1 Sel "L,L" } | ||
2397 | 38 | - Macro.num2.rt1318spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
2398 | 39 | + Macro.num1.rt1318spk { ForAmps "1" Amp 1 Sel "L,R" } | ||
2399 | 40 | + Macro.num2.rt1318spk { ForAmps "2" Amp 1 Sel "L,L" } | ||
2400 | 41 | + Macro.num3.rt1318spk { ForAmps "2" Amp 2 Sel "R,R" } | ||
2401 | 42 | |||
2402 | 43 | EnableSequence [ | ||
2403 | 44 | cset "name='Speaker Switch' on" | ||
2404 | diff --git a/debian/patches/series b/debian/patches/series | |||
2405 | index 0583a96..0c93914 100644 | |||
2406 | --- a/debian/patches/series | |||
2407 | +++ b/debian/patches/series | |||
2408 | @@ -1,3 +1,22 @@ | |||
2409 | 1 | 0001-ucm2-add-PinePhone-configuration.patch | 1 | 0001-ucm2-add-PinePhone-configuration.patch |
2410 | 2 | 0002-ucm2-add-PineTab-configuration.patch | 2 | 0002-ucm2-add-PineTab-configuration.patch |
2411 | 3 | 0003-ucm2-add-improved-Librem-5-profiles.patch | 3 | 0003-ucm2-add-improved-Librem-5-profiles.patch |
2412 | 4 | 0001-ucm2-soundwire-add-rt713-SDCA-device.patch | ||
2413 | 5 | 0001-ucm2-MediaTek-mt8390-evk-Add-alsa-ucm-support.patch | ||
2414 | 6 | 0002-ucm2-MediaTek-mt8395-evk-Add-alsa-ucm-support.patch | ||
2415 | 7 | 0003-ucm2-MediaTek-mt8370-evk-Add-alsa-ucm-support.patch | ||
2416 | 8 | 0001-ucm2-conf.d-mt8370-evk-Fix-the-type-of-mt8370-evk.co.patch | ||
2417 | 9 | 0001-ucm-MediaTek-mt8395-evk-Add-HDMIRX-config.patch | ||
2418 | 10 | 0001-sof-soundwire-Use-one-file-for-speaker-codec-initial.patch | ||
2419 | 11 | 0002-sof-soundwire-Add-basic-support-for-basic-cs35l56-co.patch | ||
2420 | 12 | 0003-sof-soundwire-Add-basic-support-for-cs42l43.patch | ||
2421 | 13 | 0001-sof-soundwire-fix-rt1318-config-typo-in-rt1318spk-ma.patch | ||
2422 | 14 | 0002-sof-soundwire-fix-rt1318-config-copy-n-paste-error-i.patch | ||
2423 | 15 | 0003-sof-soundwire-rt1308-Fix-single-amp-configuration.patch | ||
2424 | 16 | 0004-sof-soundwire-rt1316-rt1318-fix-channel-selection-fo.patch | ||
2425 | 17 | 0001-sof-soundwire-Add-missing-match-for-cs42l43-speakers.patch | ||
2426 | 18 | 0002-sof-soundwire-Add-support-for-cs42l43-cs35l56-bridge.patch | ||
2427 | 19 | 0001-sof-soundwire-Change-map-control-names-to-make-them-.patch | ||
2428 | 20 | 0002-sof-soundwire-Add-sequence-for-controlling-Mic-Mute-.patch | ||
2429 | 21 | 0001-acppdmmach-add-support-for-ACP-7.0.patch | ||
2430 | 22 | 0001-sof-soundwire-Add-basic-support-for-cs42l43-s-speake.patch |
Hi, could you please rebase this onto a Noble branch?