* [PATCH v2] ASoC: wm8994: Demux the microphone detection IRQ
@ 2014-08-13 9:05 Nikesh Oswal
2014-08-13 10:37 ` Mark Brown
0 siblings, 1 reply; 2+ messages in thread
From: Nikesh Oswal @ 2014-08-13 9:05 UTC (permalink / raw)
To: broonie, lgirdwood; +Cc: perex, tiwai, alsa-devel, linux-kernel, patches
Current code only allows direct routing of the WM8994 microphone
detection signal to a GPIO this change adds support to demux the
interrupt from the main interrupt line of the codec.
Signed-off-by: Nikesh Oswal <nikesh@opensource.wolfsonmicro.com>
---
sound/soc/codecs/wm8994.c | 18 ++++++++++++------
1 file changed, 12 insertions(+), 6 deletions(-)
diff --git a/sound/soc/codecs/wm8994.c b/sound/soc/codecs/wm8994.c
index 247b390..557156e 100644
--- a/sound/soc/codecs/wm8994.c
+++ b/sound/soc/codecs/wm8994.c
@@ -4089,17 +4089,23 @@ static int wm8994_codec_probe(struct snd_soc_codec *codec)
switch (control->type) {
case WM8994:
- if (wm8994->micdet_irq) {
+ if (wm8994->micdet_irq)
ret = request_threaded_irq(wm8994->micdet_irq, NULL,
wm8994_mic_irq,
IRQF_TRIGGER_RISING,
"Mic1 detect",
wm8994);
- if (ret != 0)
- dev_warn(codec->dev,
- "Failed to request Mic1 detect IRQ: %d\n",
- ret);
- }
+ else
+ ret = wm8994_request_irq(wm8994->wm8994,
+ WM8994_IRQ_MIC1_DET,
+ wm8994_mic_irq, "Mic 1 detect",
+ wm8994);
+
+ if (ret != 0)
+ dev_warn(codec->dev,
+ "Failed to request Mic1 detect IRQ: %d\n",
+ ret);
+
ret = wm8994_request_irq(wm8994->wm8994,
WM8994_IRQ_MIC1_SHRT,
--
1.7.9.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] ASoC: wm8994: Demux the microphone detection IRQ
2014-08-13 9:05 [PATCH v2] ASoC: wm8994: Demux the microphone detection IRQ Nikesh Oswal
@ 2014-08-13 10:37 ` Mark Brown
0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2014-08-13 10:37 UTC (permalink / raw)
To: Nikesh Oswal; +Cc: lgirdwood, perex, tiwai, alsa-devel, linux-kernel, patches
[-- Attachment #1: Type: text/plain, Size: 269 bytes --]
On Wed, Aug 13, 2014 at 10:05:45AM +0100, Nikesh Oswal wrote:
> Current code only allows direct routing of the WM8994 microphone
> detection signal to a GPIO this change adds support to demux the
> interrupt from the main interrupt line of the codec.
Applied, thanks.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-08-13 10:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-13 9:05 [PATCH v2] ASoC: wm8994: Demux the microphone detection IRQ Nikesh Oswal
2014-08-13 10:37 ` Mark Brown
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.