From 6362d3293a91d32a2fd806199b36bde9916500d7 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Oct 09 2017 15:54:37 +0000 Subject: backport some alsa-mixer related fixes (#1492344) --- diff --git a/0004-alsa-mixer-Add-support-for-usb-audio-in-the-Dell-doc.patch b/0004-alsa-mixer-Add-support-for-usb-audio-in-the-Dell-doc.patch new file mode 100644 index 0000000..1d83034 --- /dev/null +++ b/0004-alsa-mixer-Add-support-for-usb-audio-in-the-Dell-doc.patch @@ -0,0 +1,96 @@ +From 60c0edd5286dbb731c671ad3e6886c1e3e1eb067 Mon Sep 17 00:00:00 2001 +From: Hui Wang +Date: Fri, 26 May 2017 15:42:40 +0800 +Subject: [PATCH 04/48] alsa-mixer: Add support for usb audio in the Dell dock + TB16 + +There are one headset jack on the front panel of TB16, through this +jack, we have one stereo headphone output (hw:%f,0,0) and one mono +headset-mic input (hw:%f,0,0); and there is one speaker output jack +(hw:%f,1,0) on the rear panel of TB16. + +The detail information of the Dell dock TB16: +http://www.dell.com/support/article/sg/en/sgbsdt1/SLN301105 + +Signed-off-by: Hui Wang +--- + .../alsa/mixer/profile-sets/90-pulseaudio.rules | 1 + + .../profile-sets/dell-dock-tb16-usb-audio.conf | 55 ++++++++++++++++++++++ + 2 files changed, 56 insertions(+) + create mode 100644 src/modules/alsa/mixer/profile-sets/dell-dock-tb16-usb-audio.conf + +diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules +index 70e34e6f..805a05b2 100644 +--- a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules ++++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules +@@ -98,5 +98,6 @@ ATTRS{idVendor}=="17cc", ATTRS{idProduct}=="1021", ENV{PULSE_PROFILE_SET}="nativ + ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012", ENV{PULSE_PROFILE_SET}="maudio-fasttrack-pro.conf" + ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb", ENV{PULSE_PROFILE_SET}="kinect-audio.conf" + ATTRS{idVendor}=="041e", ATTRS{idProduct}=="322c", ENV{PULSE_PROFILE_SET}="sb-omni-surround-5.1.conf" ++ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="4014", ENV{PULSE_PROFILE_SET}="dell-dock-tb16-usb-audio.conf" + + LABEL="pulseaudio_end" +diff --git a/src/modules/alsa/mixer/profile-sets/dell-dock-tb16-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/dell-dock-tb16-usb-audio.conf +new file mode 100644 +index 00000000..11865524 +--- /dev/null ++++ b/src/modules/alsa/mixer/profile-sets/dell-dock-tb16-usb-audio.conf +@@ -0,0 +1,55 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++; Dell Dock TB16 USB audio ++; ++; This card has two stereo pairs of output, One Mono input. ++; ++; See default.conf for an explanation on the directives used here. ++ ++[General] ++auto-profiles = no ++ ++[Mapping analog-stereo-headphone] ++description = Headphone ++device-strings = hw:%f,0,0 ++channel-map = left,right ++direction = output ++ ++[Mapping analog-stereo-speaker] ++description = Speaker ++device-strings = hw:%f,1,0 ++channel-map = left,right ++direction = output ++ ++[Mapping analog-stereo-mic] ++description = Headset-Mic ++device-strings = hw:%f,0,0 ++channel-map = left,right ++direction = input ++ ++ ++[Profile output:analog-stereo-speaker] ++description = Speaker ++output-mappings = analog-stereo-speaker ++priority = 60 ++skip-probe = yes ++ ++[Profile output:analog-stereo-headphone+input:analog-stereo-mic] ++description = Headset ++output-mappings = analog-stereo-headphone ++input-mappings = analog-stereo-mic ++priority = 80 ++skip-probe = yes +-- +2.13.6 + diff --git a/0009-alsa-mixer-set-PCM-Capture-Source-for-iec958-input.patch b/0009-alsa-mixer-set-PCM-Capture-Source-for-iec958-input.patch new file mode 100644 index 0000000..4689456 --- /dev/null +++ b/0009-alsa-mixer-set-PCM-Capture-Source-for-iec958-input.patch @@ -0,0 +1,48 @@ +From ec325304cdca5e2a46f5a84f93c8b614a204d87f Mon Sep 17 00:00:00 2001 +From: Tanu Kaskinen +Date: Fri, 4 Aug 2017 11:14:43 +0300 +Subject: [PATCH 09/48] alsa-mixer: set PCM Capture Source for iec958 input + +It was reported that on a certain USB card, identified as +"0d8c:0102 C-Media Electronics, Inc. CM106 Like Sound Device", +the "PCM Capture Source" element had to be set to "IEC958 In" before +the iec958 input would work. + +The iec958-stereo-input.conf file didn't exist before, although the path +was referenced in the default.conf profile configuration file. + +BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=101973 +--- + .../alsa/mixer/paths/iec958-stereo-input.conf | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) + create mode 100644 src/modules/alsa/mixer/paths/iec958-stereo-input.conf + +diff --git a/src/modules/alsa/mixer/paths/iec958-stereo-input.conf b/src/modules/alsa/mixer/paths/iec958-stereo-input.conf +new file mode 100644 +index 00000000..babc8398 +--- /dev/null ++++ b/src/modules/alsa/mixer/paths/iec958-stereo-input.conf +@@ -0,0 +1,20 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++[Element PCM Capture Source] ++enumeration = select ++ ++[Option PCM Capture Source:IEC958 In] ++name = iec958-input +-- +2.13.6 + diff --git a/0015-alsa-mixer-round-not-truncate-in-to_alsa_dB.patch b/0015-alsa-mixer-round-not-truncate-in-to_alsa_dB.patch new file mode 100644 index 0000000..45fff8c --- /dev/null +++ b/0015-alsa-mixer-round-not-truncate-in-to_alsa_dB.patch @@ -0,0 +1,45 @@ +From 739a4b3d2318f05eb7101c2baa861e5c636125a5 Mon Sep 17 00:00:00 2001 +From: Ian Ray +Date: Wed, 30 Aug 2017 11:09:48 +0300 +Subject: [PATCH 15/48] alsa-mixer: round, not truncate, in to_alsa_dB + +to_alsa_dB() returns a result rounded to two decimal places (instead of +using integer truncation) to avoid small errors when converting between +dB and volume. + +Consider playback at -22 dB (which is supported by ALSA) but results in +the higher level of -21 dB plus software attenuation. + + pa_sw_volume_from_dB(-22) = 28172 + pa_sw_volume_to_dB(28172) = -21.9997351 + to_alsa_dB(-21.9997351) = -2199 + + ALSA value 106 = -2200 + ALSA value 107 = -2100 + ... + + rounding = +1 /* "accurate or first above" */ + snd_mixer_selem_ask_playback_dB_vol(me, -2199, rounding, &alsa_val) + alsa_val = -2100 + +Signed-off-by: Ian Ray +--- + src/modules/alsa/alsa-mixer.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c +index f59cad39..aeaf12c4 100644 +--- a/src/modules/alsa/alsa-mixer.c ++++ b/src/modules/alsa/alsa-mixer.c +@@ -700,7 +700,7 @@ void pa_alsa_path_set_free(pa_alsa_path_set *ps) { + } + + static long to_alsa_dB(pa_volume_t v) { +- return (long) (pa_sw_volume_to_dB(v) * 100.0); ++ return lround(pa_sw_volume_to_dB(v) * 100.0); + } + + static pa_volume_t from_alsa_dB(long v) { +-- +2.13.6 + diff --git a/0016-alsa-mixer-add-support-for-Steelseries-Arctis-7-head.patch b/0016-alsa-mixer-add-support-for-Steelseries-Arctis-7-head.patch new file mode 100644 index 0000000..55e65b8 --- /dev/null +++ b/0016-alsa-mixer-add-support-for-Steelseries-Arctis-7-head.patch @@ -0,0 +1,193 @@ +From 15386a710c1500f70085a6312fb4d84be4d254c9 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Johan=20Heikkil=C3=A4?= +Date: Sun, 27 Aug 2017 16:29:37 +0300 +Subject: [PATCH 16/48] alsa-mixer: add support for Steelseries Arctis 7 + headset + +--- + src/modules/alsa/alsa-mixer.c | 1 + + .../alsa/mixer/paths/steelseries-arctis-input.conf | 25 +++++++++++++ + .../paths/steelseries-arctis-output-mono.conf | 29 +++++++++++++++ + .../paths/steelseries-arctis-output-stereo.conf | 27 ++++++++++++++ + .../alsa/mixer/profile-sets/90-pulseaudio.rules | 1 + + .../profile-sets/steelseries-arctis-usb-audio.conf | 43 ++++++++++++++++++++++ + 6 files changed, 126 insertions(+) + create mode 100644 src/modules/alsa/mixer/paths/steelseries-arctis-input.conf + create mode 100644 src/modules/alsa/mixer/paths/steelseries-arctis-output-mono.conf + create mode 100644 src/modules/alsa/mixer/paths/steelseries-arctis-output-stereo.conf + create mode 100644 src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf + +diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c +index aeaf12c4..08ea45d3 100644 +--- a/src/modules/alsa/alsa-mixer.c ++++ b/src/modules/alsa/alsa-mixer.c +@@ -2469,6 +2469,7 @@ static int path_verify(pa_alsa_path *p) { + { "analog-input-video", N_("Video") }, + { "analog-output", N_("Analog Output") }, + { "analog-output-headphones", N_("Headphones") }, ++ { "analog-output-headphones-mono", N_("Headphones Mono Output") }, + { "analog-output-lfe-on-mono", N_("LFE on Separate Mono Output") }, + { "analog-output-lineout", N_("Line Out") }, + { "analog-output-mono", N_("Analog Mono Output") }, +diff --git a/src/modules/alsa/mixer/paths/steelseries-arctis-input.conf b/src/modules/alsa/mixer/paths/steelseries-arctis-input.conf +new file mode 100644 +index 00000000..f3115ba6 +--- /dev/null ++++ b/src/modules/alsa/mixer/paths/steelseries-arctis-input.conf +@@ -0,0 +1,25 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++; Steelseries Arctis 7 USB headset microphone path. ++ ++[General] ++description-key = analog-input-microphone-headset ++ ++[Element Headset] ++volume = merge ++switch = mute ++override-map.1 = all ++override-map.2 = all-left,all-right +diff --git a/src/modules/alsa/mixer/paths/steelseries-arctis-output-mono.conf b/src/modules/alsa/mixer/paths/steelseries-arctis-output-mono.conf +new file mode 100644 +index 00000000..67950618 +--- /dev/null ++++ b/src/modules/alsa/mixer/paths/steelseries-arctis-output-mono.conf +@@ -0,0 +1,29 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++; Steelseries Arctis 7 USB headset mono output path. The headset has two ++; output devices. The first one is mono, meant for voice audio, and the ++; second one is stereo, meant for everything else. The purpose of this ++; unusual design is to provide separate volume controls for voice and ++; other audio, which can be useful in gaming. ++ ++[General] ++description-key = analog-output-headphones-mono ++ ++[Element PCM] ++volume = merge ++switch = mute ++override-map.1 = all ++override-map.2 = all-left,all-right +diff --git a/src/modules/alsa/mixer/paths/steelseries-arctis-output-stereo.conf b/src/modules/alsa/mixer/paths/steelseries-arctis-output-stereo.conf +new file mode 100644 +index 00000000..4e10c800 +--- /dev/null ++++ b/src/modules/alsa/mixer/paths/steelseries-arctis-output-stereo.conf +@@ -0,0 +1,27 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++; Steelseries Arctis 7 USB headset stereo output path. The headset has two ++; output devices. The first one is mono, meant for voice audio, and the ++; second one is stereo, meant for everything else. The purpose of this ++; unusual design is to provide separate volume controls for voice and ++; other audio, which can be useful in gaming. ++; ++; This path doesn't provide hardware volume control, because the stereo ++; output is controlled by the PCM element with index 1, and currently ++; PulseAudio only supports elements with index 0. ++ ++[General] ++description-key = analog-output-headphones +diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules +index 805a05b2..2392ca50 100644 +--- a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules ++++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules +@@ -99,5 +99,6 @@ ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012", ENV{PULSE_PROFILE_SET}="maudi + ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb", ENV{PULSE_PROFILE_SET}="kinect-audio.conf" + ATTRS{idVendor}=="041e", ATTRS{idProduct}=="322c", ENV{PULSE_PROFILE_SET}="sb-omni-surround-5.1.conf" + ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="4014", ENV{PULSE_PROFILE_SET}="dell-dock-tb16-usb-audio.conf" ++ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260", ENV{PULSE_PROFILE_SET}="steelseries-arctis-usb-audio.conf" + + LABEL="pulseaudio_end" +diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf +new file mode 100644 +index 00000000..d3563a16 +--- /dev/null ++++ b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf +@@ -0,0 +1,43 @@ ++# This file is part of PulseAudio. ++# ++# PulseAudio is free software; you can redistribute it and/or modify ++# it under the terms of the GNU Lesser General Public License as ++# published by the Free Software Foundation; either version 2.1 of the ++# License, or (at your option) any later version. ++# ++# PulseAudio is distributed in the hope that it will be useful, but ++# WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++# General Public License for more details. ++# ++# You should have received a copy of the GNU Lesser General Public License ++# along with PulseAudio; if not, see . ++ ++; Steelseries Arctis 7 USB headset. The headset has a microphone and two output ++; devices. The first output device is mono, meant for voice audio, and the ++; second one is stereo, meant for everything else. The purpose of this unusual ++; design is to provide separate volume controls for voice and other audio, ++; which can be useful in gaming. ++; ++; See default.conf for an explanation on the directives used here. ++ ++[General] ++auto-profiles = yes ++ ++[Mapping analog-mono] ++device-strings = hw:%f,0,0 ++channel-map = mono ++paths-output = steelseries-arctis-output-mono ++paths-input = steelseries-arctis-input ++ ++[Mapping analog-stereo] ++device-strings = hw:%f,1,0 ++channel-map = left,right ++paths-output = steelseries-arctis-output-stereo ++direction = output ++ ++[Profile output:analog-mono+output:analog-stereo+input:analog-mono] ++output-mappings = analog-mono analog-stereo ++input-mappings = analog-mono ++priority = 5100 ++skip-probe = yes +-- +2.13.6 + diff --git a/0035-alsa-mixer-Prioritize-hdmi-mappings-over-iec958-mapp.patch b/0035-alsa-mixer-Prioritize-hdmi-mappings-over-iec958-mapp.patch new file mode 100644 index 0000000..b2e54ba --- /dev/null +++ b/0035-alsa-mixer-Prioritize-hdmi-mappings-over-iec958-mapp.patch @@ -0,0 +1,380 @@ +From 184c28795bb98ad14bdfcef01a475d5ba11e40d5 Mon Sep 17 00:00:00 2001 +From: Kristian Klausen +Date: Fri, 22 Sep 2017 17:54:14 +0000 +Subject: [PATCH 35/48] alsa-mixer: Prioritize hdmi-* mappings over iec958-* + mappings + +Pulseaudio tries to pick the best profile (on startup or +hotplugged), the best profile is the profile with the highest +priority which isn't unavailable. +Due to the facts that iec958 ports available status always (?) +is unknown, and that it is generally more likely that a user use +hdmi than iec958, lets prioritze hdmi over iec958. + +This patch shift the analog-* mappings +5 and hdmi-* mappings +5. +--- + src/modules/alsa/mixer/profile-sets/default.conf | 80 ++++++++++++------------ + 1 file changed, 40 insertions(+), 40 deletions(-) + +diff --git a/src/modules/alsa/mixer/profile-sets/default.conf b/src/modules/alsa/mixer/profile-sets/default.conf +index c360e772..f5093830 100644 +--- a/src/modules/alsa/mixer/profile-sets/default.conf ++++ b/src/modules/alsa/mixer/profile-sets/default.conf +@@ -106,14 +106,14 @@ device-strings = hw:%f + channel-map = mono + paths-output = analog-output analog-output-lineout analog-output-speaker analog-output-headphones analog-output-headphones-2 analog-output-mono + paths-input = analog-input-front-mic analog-input-rear-mic analog-input-internal-mic analog-input-dock-mic analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line analog-input-headset-mic +-priority = 2 ++priority = 7 + + [Mapping analog-stereo] + device-strings = front:%f + channel-map = left,right + paths-output = analog-output analog-output-lineout analog-output-speaker analog-output-headphones analog-output-headphones-2 + paths-input = analog-input-front-mic analog-input-rear-mic analog-input-internal-mic analog-input-dock-mic analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line analog-input-headphone-mic analog-input-headset-mic +-priority = 10 ++priority = 15 + + # If everything else fails, try to use hw:0 as a stereo device. + [Mapping stereo-fallback] +@@ -128,35 +128,35 @@ priority = 1 + device-strings = surround21:%f + channel-map = front-left,front-right,lfe + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 8 ++priority = 13 + direction = output + + [Mapping analog-surround-40] + device-strings = surround40:%f + channel-map = front-left,front-right,rear-left,rear-right + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 7 ++priority = 12 + direction = output + + [Mapping analog-surround-41] + device-strings = surround41:%f + channel-map = front-left,front-right,rear-left,rear-right,lfe + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 8 ++priority = 13 + direction = output + + [Mapping analog-surround-50] + device-strings = surround50:%f + channel-map = front-left,front-right,rear-left,rear-right,front-center + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 7 ++priority = 12 + direction = output + + [Mapping analog-surround-51] + device-strings = surround51:%f + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 8 ++priority = 13 + direction = output + + [Mapping analog-surround-71] +@@ -164,7 +164,7 @@ device-strings = surround71:%f + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right + description = Analog Surround 7.1 + paths-output = analog-output analog-output-lineout analog-output-speaker +-priority = 7 ++priority = 12 + direction = output + + [Mapping iec958-stereo] +@@ -200,7 +200,7 @@ description = Digital Stereo (HDMI) + device-strings = hdmi:%f + paths-output = hdmi-output-0 + channel-map = left,right +-priority = 4 ++priority = 9 + direction = output + + [Mapping hdmi-surround] +@@ -208,7 +208,7 @@ description = Digital Surround 5.1 (HDMI) + device-strings = hdmi:%f + paths-output = hdmi-output-0 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 3 ++priority = 8 + direction = output + + [Mapping hdmi-surround71] +@@ -216,7 +216,7 @@ description = Digital Surround 7.1 (HDMI) + device-strings = hdmi:%f + paths-output = hdmi-output-0 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 3 ++priority = 8 + direction = output + + [Mapping hdmi-dts-surround] +@@ -224,7 +224,7 @@ description = Digital Surround 5.1 (HDMI/DTS) + device-strings = dcahdmi:%f + paths-output = hdmi-output-0 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra1] +@@ -232,7 +232,7 @@ description = Digital Stereo (HDMI 2) + device-strings = hdmi:%f,1 + paths-output = hdmi-output-1 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra1] +@@ -240,7 +240,7 @@ description = Digital Surround 5.1 (HDMI 2) + device-strings = hdmi:%f,1 + paths-output = hdmi-output-1 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra1] +@@ -248,7 +248,7 @@ description = Digital Surround 7.1 (HDMI 2) + device-strings = hdmi:%f,1 + paths-output = hdmi-output-1 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra1] +@@ -256,7 +256,7 @@ description = Digital Surround 5.1 (HDMI 2/DTS) + device-strings = dcahdmi:%f,1 + paths-output = hdmi-output-1 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra2] +@@ -264,7 +264,7 @@ description = Digital Stereo (HDMI 3) + device-strings = hdmi:%f,2 + paths-output = hdmi-output-2 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra2] +@@ -272,7 +272,7 @@ description = Digital Surround 5.1 (HDMI 3) + device-strings = hdmi:%f,2 + paths-output = hdmi-output-2 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra2] +@@ -280,7 +280,7 @@ description = Digital Surround 7.1 (HDMI 3) + device-strings = hdmi:%f,2 + paths-output = hdmi-output-2 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra2] +@@ -288,7 +288,7 @@ description = Digital Surround 5.1 (HDMI 3/DTS) + device-strings = dcahdmi:%f,2 + paths-output = hdmi-output-2 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra3] +@@ -296,7 +296,7 @@ description = Digital Stereo (HDMI 4) + device-strings = hdmi:%f,3 + paths-output = hdmi-output-3 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra3] +@@ -304,7 +304,7 @@ description = Digital Surround 5.1 (HDMI 4) + device-strings = hdmi:%f,3 + paths-output = hdmi-output-3 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra3] +@@ -312,7 +312,7 @@ description = Digital Surround 7.1 (HDMI 4) + device-strings = hdmi:%f,3 + paths-output = hdmi-output-3 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra3] +@@ -320,7 +320,7 @@ description = Digital Surround 5.1 (HDMI 4/DTS) + device-strings = dcahdmi:%f,3 + paths-output = hdmi-output-3 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra4] +@@ -328,7 +328,7 @@ description = Digital Stereo (HDMI 5) + device-strings = hdmi:%f,4 + paths-output = hdmi-output-4 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra4] +@@ -336,7 +336,7 @@ description = Digital Surround 5.1 (HDMI 5) + device-strings = hdmi:%f,4 + paths-output = hdmi-output-4 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra4] +@@ -344,7 +344,7 @@ description = Digital Surround 7.1 (HDMI 5) + device-strings = hdmi:%f,4 + paths-output = hdmi-output-4 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra4] +@@ -352,7 +352,7 @@ description = Digital Surround 5.1 (HDMI 5/DTS) + device-strings = dcahdmi:%f,4 + paths-output = hdmi-output-4 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra5] +@@ -360,7 +360,7 @@ description = Digital Stereo (HDMI 6) + device-strings = hdmi:%f,5 + paths-output = hdmi-output-5 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra5] +@@ -368,7 +368,7 @@ description = Digital Surround 5.1 (HDMI 6) + device-strings = hdmi:%f,5 + paths-output = hdmi-output-5 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra5] +@@ -376,7 +376,7 @@ description = Digital Surround 7.1 (HDMI 6) + device-strings = hdmi:%f,5 + paths-output = hdmi-output-5 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra5] +@@ -384,7 +384,7 @@ description = Digital Surround 5.1 (HDMI 6/DTS) + device-strings = dcahdmi:%f,5 + paths-output = hdmi-output-5 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra6] +@@ -392,7 +392,7 @@ description = Digital Stereo (HDMI 7) + device-strings = hdmi:%f,6 + paths-output = hdmi-output-6 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra6] +@@ -400,7 +400,7 @@ description = Digital Surround 5.1 (HDMI 7) + device-strings = hdmi:%f,6 + paths-output = hdmi-output-6 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra6] +@@ -408,7 +408,7 @@ description = Digital Surround 7.1 (HDMI 7) + device-strings = hdmi:%f,6 + paths-output = hdmi-output-6 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra6] +@@ -416,7 +416,7 @@ description = Digital Surround 5.1 (HDMI 7/DTS) + device-strings = dcahdmi:%f,6 + paths-output = hdmi-output-6 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-stereo-extra7] +@@ -424,7 +424,7 @@ description = Digital Stereo (HDMI 8) + device-strings = hdmi:%f,7 + paths-output = hdmi-output-7 + channel-map = left,right +-priority = 2 ++priority = 7 + direction = output + + [Mapping hdmi-surround-extra7] +@@ -432,7 +432,7 @@ description = Digital Surround 5.1 (HDMI 8) + device-strings = hdmi:%f,7 + paths-output = hdmi-output-7 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-surround71-extra7] +@@ -440,7 +440,7 @@ description = Digital Surround 7.1 (HDMI 8) + device-strings = hdmi:%f,7 + paths-output = hdmi-output-7 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right +-priority = 1 ++priority = 6 + direction = output + + [Mapping hdmi-dts-surround-extra7] +@@ -448,7 +448,7 @@ description = Digital Surround 5.1 (HDMI 8/DTS) + device-strings = dcahdmi:%f,7 + paths-output = hdmi-output-7 + channel-map = front-left,front-right,rear-left,rear-right,front-center,lfe +-priority = 1 ++priority = 6 + direction = output + + [Mapping multichannel-output] +-- +2.13.6 + diff --git a/pulseaudio.spec b/pulseaudio.spec index 405f0d1..db54c66 100644 --- a/pulseaudio.spec +++ b/pulseaudio.spec @@ -25,7 +25,7 @@ Name: pulseaudio Summary: Improved Linux Sound Server Version: %{pa_major}%{?pa_minor:.%{pa_minor}} -Release: 1%{?snap:.%{snap}git%{shortcommit}}%{?dist} +Release: 2%{?snap:.%{snap}git%{shortcommit}}%{?dist} License: LGPLv2+ URL: http://www.freedesktop.org/wiki/Software/PulseAudio %if 0%{?gitrel} @@ -54,6 +54,11 @@ Patch2: pulseaudio-9.0-disable_flat_volumes.patch Patch3: pulseaudio-8.99.2-getaffinity.patch ## upstream patches +Patch4: 0004-alsa-mixer-Add-support-for-usb-audio-in-the-Dell-doc.patch +Patch9: 0009-alsa-mixer-set-PCM-Capture-Source-for-iec958-input.patch +Patch15: 0015-alsa-mixer-round-not-truncate-in-to_alsa_dB.patch +Patch16: 0016-alsa-mixer-add-support-for-Steelseries-Arctis-7-head.patch +Patch35: 0035-alsa-mixer-Prioritize-hdmi-mappings-over-iec958-mapp.patch ## upstreamable patches @@ -234,6 +239,13 @@ This package contains GDM integration hooks for the PulseAudio sound server. %prep %setup -q -T -b0 -n %{name}-%{version}%{?gitrel:-%{gitrel}-g%{shortcommit}} +## upstream patches +%patch4 -p1 -b .0004 +%patch9 -p1 -b .0009 +%patch15 -p1 -b .0015 +%patch16 -p1 -b .0016 +%patch35 -p1 -b .0035 + %patch1 -p1 -b .autostart %patch2 -p1 -b .disable_flat_volumes %patch3 -p1 -b .affinity @@ -573,6 +585,9 @@ exit 0 %changelog +* Mon Oct 09 2017 Rex Dieter - 11.1-2 +- backport some alsa-mixer related fixes (#1492344) + * Wed Sep 20 2017 Rex Dieter - 11.1-1 - pulseaudio-11.1