[meta-freescale] [meta-fsl-arm][PATCH] pulseaudio: Remove the control for speaker/headphone widget for i.MX7D

Yuqing Zhu carol.zhu at nxp.com
Wed May 4 02:43:02 PDT 2016


In order to fix issue "headphone volume will be set to zero when pulseaudio
can't detect the headphone jack status", remove the control in configuration file.

Signed-off-by: Yuqing Zhu <carol.zhu at nxp.com>
---
 ...e-the-control-for-speaker-headphone-widge.patch | 73 ++++++++++++++++++++++
 .../pulseaudio/pulseaudio_%.bbappend               |  4 +-
 2 files changed, 76 insertions(+), 1 deletion(-)
 create mode 100644 recipes-multimedia/pulseaudio/pulseaudio/imx/pulseaudio-remove-the-control-for-speaker-headphone-widge.patch

diff --git a/recipes-multimedia/pulseaudio/pulseaudio/imx/pulseaudio-remove-the-control-for-speaker-headphone-widge.patch b/recipes-multimedia/pulseaudio/pulseaudio/imx/pulseaudio-remove-the-control-for-speaker-headphone-widge.patch
new file mode 100644
index 0000000..019f9ba
--- /dev/null
+++ b/recipes-multimedia/pulseaudio/pulseaudio/imx/pulseaudio-remove-the-control-for-speaker-headphone-widge.patch
@@ -0,0 +1,73 @@
+From 015e048d3662b9f82e9aa5cd04d7c9de4eadb68d Mon Sep 17 00:00:00 2001
+From: Shengjiu Wang <shengjiu.wang at freescale.com>
+Date: Mon, 30 Mar 2015 10:26:14 +0800
+Subject: [PATCH] pulseaudio: remove the control for speaker/headphone widget
+
+In imx7d-sdb, there is no headphone jack, the jack detection is done
+by the codec itself. When headphone plugin, pulseaudio can't detect
+the headphone jack status, so it will set the heaphone volume to zero.
+Here fix this issue by remove the control in configuration.
+
+Upstream-Status: Inappropriate [i.MX specific]
+
+Signed-off-by: Shengjiu Wang <shengjiu.wang at freescale.com>
+---
+ .../alsa/mixer/paths/analog-output-headphones.conf |    8 ++++----
+ .../alsa/mixer/paths/analog-output-speaker.conf    |    8 ++++----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/src/modules/alsa/mixer/paths/analog-output-headphones.conf b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
+index b6ee70b..a617976 100644
+--- a/src/modules/alsa/mixer/paths/analog-output-headphones.conf
++++ b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
+@@ -81,8 +81,8 @@ override-map.2 = all-left,all-right
+ 
+ [Element Headphone]
+ required-any = any
+-switch = mute
+-volume = merge
++switch = on
++volume = ignore
+ override-map.1 = all
+ override-map.2 = all-left,all-right
+ 
+@@ -105,8 +105,8 @@ switch = mute
+ volume = zero
+ 
+ [Element Speaker]
+-switch = off
+-volume = off
++switch = on
++volume = ignore
+ 
+ [Element Desktop Speaker]
+ switch = off
+diff --git a/src/modules/alsa/mixer/paths/analog-output-speaker.conf b/src/modules/alsa/mixer/paths/analog-output-speaker.conf
+index 39193dd..34bbb85 100644
+--- a/src/modules/alsa/mixer/paths/analog-output-speaker.conf
++++ b/src/modules/alsa/mixer/paths/analog-output-speaker.conf
+@@ -73,8 +73,8 @@ volume = off
+ ; This profile path is intended to control the speaker, let's mute headphones
+ ; else there will be a spike when plugging in headphones
+ [Element Headphone]
+-switch = off
+-volume = off
++switch = on
++volume = ignore
+ 
+ [Element Headphone2]
+ switch = off
+@@ -93,8 +93,8 @@ override-map.2 = all-left,all-right
+ 
+ [Element Speaker]
+ required-any = any
+-switch = mute
+-volume = merge
++switch = on
++volume = ignore
+ override-map.1 = all
+ override-map.2 = all-left,all-right
+ 
+-- 
+1.7.9.5
+
diff --git a/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend b/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
index 68dc1c9..ebb8fcc 100644
--- a/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
+++ b/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
@@ -5,7 +5,9 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}/imx:"
 
 SRC_URI_append_mx6 = " file://daemon.conf file://default.pa"
 SRC_URI_append_mx6ul = " file://daemon.conf file://default.pa"
-SRC_URI_append_mx7 = " file://daemon.conf file://default.pa"
+SRC_URI_append_mx7 = " file://daemon.conf file://default.pa \
+                       file://pulseaudio-remove-the-control-for-speaker-headphone-widge.patch \
+"
 
 do_install_append() {
     if [ -e "${WORKDIR}/daemon.conf" ] && [ -e "${WORKDIR}/default.pa" ]; then
-- 
1.9.1



More information about the meta-freescale mailing list