summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorlizhuangzhi <zhuangzhi.li@intel.com>2012-03-27 08:49:13 +0800
committerbuildbot <buildbot@intel.com>2012-04-12 05:23:16 -0700
commitfdc11b431b54e0c1245bf609c88058ebce752b47 (patch)
treee2ebb7156c50a3190504d62b77716070fd036f1e /sound
parent5485b9ef3232681dd20e4a01fff608b35e7fd802 (diff)
downloadkernel-mfld-blackbay-fdc11b431b54e0c1245bf609c88058ebce752b47.tar.gz
kernel-mfld-blackbay-fdc11b431b54e0c1245bf609c88058ebce752b47.tar.bz2
kernel-mfld-blackbay-fdc11b431b54e0c1245bf609c88058ebce752b47.zip
audio: sn95031: [WORKAROUND]Make jack detect delay time longer for Lexington platform
BZ: 27775 On LEX platform, the jack module type is changed. Jack_DET is connected to the left HP channel, only one interrupt occur during people plug in headset, It's good for plug interrupt stable, But the mic bias voltage maybe unstale after 250ms wq delay, Use CONFIG_SND_MFLD_MACHINE_GI macro to control 700ms longer time delay as workaround for LEX platform. Change-Id: I274b915644adaeed8749a49cd5655e6b16c81ed0 Signed-off-by: Zhuangzhi Li <zhuangzhi.li@intel.com> Reviewed-on: http://android.intel.com:8080/40775 Reviewed-by: Abdullah, Omair M <omair.m.abdullah@intel.com> Reviewed-by: Babu, Ramesh <ramesh.babu@intel.com> Reviewed-by: Koul, Vinod <vinod.koul@intel.com> Reviewed-by: Gross, Mark <mark.gross@intel.com> Reviewed-by: Gupta, ArvindX K <arvindx.k.gupta@intel.com> Reviewed-by: Hibare, PramodX <pramodx.hibare@intel.com> Tested-by: Hibare, PramodX <pramodx.hibare@intel.com> Reviewed-by: buildbot <buildbot@intel.com> Tested-by: buildbot <buildbot@intel.com>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/sn95031.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/sound/soc/codecs/sn95031.c b/sound/soc/codecs/sn95031.c
index b9b1d598bd0..6486d8c432b 100644
--- a/sound/soc/codecs/sn95031.c
+++ b/sound/soc/codecs/sn95031.c
@@ -44,9 +44,18 @@
#define SN95031_RATES (SNDRV_PCM_RATE_8000_96000)
#define SN95031_FORMATS (SNDRV_PCM_FMTBIT_S24_LE | SNDRV_PCM_FMTBIT_S16_LE)
-#define SN95031_SW_DBNC 250
#define LP_THRESHOLD 400
#define HEADSET_DET_PIN 77
+/*
+ * On LEX platform, for JACK mechanism changed, the mic bias voltage
+ * maybe unstale after 250ms wq delay, Use longer time delay 700ms as
+ * workaround, it covers most normal plug in operation.
+ */
+#ifdef CONFIG_SND_MFLD_MACHINE_GI
+#define SN95031_SW_DBNC 700
+#else
+#define SN95031_SW_DBNC 250
+#endif
struct sn95031_jack_work {
unsigned int intr_id;