[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1442396541-7145-9-git-send-email-ckeepax@opensource.wolfsonmicro.com>
Date: Wed, 16 Sep 2015 10:42:20 +0100
From: Charles Keepax <ckeepax@...nsource.wolfsonmicro.com>
To: <cw00.choi@...sung.com>, <lee.jones@...aro.org>
CC: <myungjoo.ham@...sung.com>, <sameo@...ux.intel.com>,
<patches@...nsource.wolfsonmicro.com>,
<linux-kernel@...r.kernel.org>
Subject: [PATCH 8/9] extcon: arizona: Use the micd_clamp for interrupts if it is available
Currently we only use the microphone clamp IRQ if GPIO5 is being used as
a second jack detection pin. But we should be using it on any system
where the clamp is available. This patch updates the driver to do so.
Signed-off-by: Charles Keepax <ckeepax@...nsource.wolfsonmicro.com>
---
drivers/extcon/extcon-arizona.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/extcon/extcon-arizona.c b/drivers/extcon/extcon-arizona.c
index ece5892..9255c1f 100644
--- a/drivers/extcon/extcon-arizona.c
+++ b/drivers/extcon/extcon-arizona.c
@@ -1057,7 +1057,7 @@ static irqreturn_t arizona_jackdet(int irq, void *data)
mutex_lock(&info->lock);
- if (arizona->pdata.jd_gpio5) {
+ if (info->micd_clamp) {
mask = ARIZONA_MICD_CLAMP_STS;
present = 0;
} else {
@@ -1504,7 +1504,7 @@ static int arizona_extcon_probe(struct platform_device *pdev)
pm_runtime_idle(&pdev->dev);
pm_runtime_get_sync(&pdev->dev);
- if (arizona->pdata.jd_gpio5) {
+ if (info->micd_clamp) {
jack_irq_rise = ARIZONA_IRQ_MICD_CLAMP_RISE;
jack_irq_fall = ARIZONA_IRQ_MICD_CLAMP_FALL;
} else {
@@ -1609,7 +1609,7 @@ static int arizona_extcon_remove(struct platform_device *pdev)
ARIZONA_MICD_CLAMP_CONTROL,
ARIZONA_MICD_CLAMP_MODE_MASK, 0);
- if (arizona->pdata.jd_gpio5) {
+ if (info->micd_clamp) {
jack_irq_rise = ARIZONA_IRQ_MICD_CLAMP_RISE;
jack_irq_fall = ARIZONA_IRQ_MICD_CLAMP_FALL;
} else {
--
1.7.2.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists