From: "Bryan O'Donoghue" <pure.logic@nexus-software.ie>
To: Raymond Tan <raymond.tan@intel.com>,
Lee Jones <lee.jones@linaro.org>,
Samuel Ortiz <sameo@linux.intel.com>
Cc: linux-kernel@vger.kernel.org, Alvin Chen <alvin.chen@intel.com>,
Andriy Shevchenko <andriy.shevchenko@intel.com>
Subject: Re: [PATCH 1/1] mfd: intel_quark_i2c_gpio: Add Intel Quark X1000 I2C-GPIO MFD Driver
Date: Mon, 03 Nov 2014 10:35:20 +0000 [thread overview]
Message-ID: <54575A68.7060009@nexus-software.ie> (raw)
In-Reply-To: <1415000344-23575-2-git-send-email-raymond.tan@intel.com>
On 03/11/14 07:39, Raymond Tan wrote:
> + pdata->properties->irq = pdev->irq;
> + pdata->properties->irq_shared = true;
OK I see it.
Thanks.
My question is. How extensively have edge triggered interrupts been
tested on the GPIO block ?
The BSP reference code is quite explicit about not missing edge interrupts.
Have you tested GPIO input in edge mode ?
+irqreturn_t intel_qrk_gpio_isr(int irq, void *dev_id)
+{
+ irqreturn_t ret = IRQ_NONE;
+ u32 pending = 0, gpio = 0;
+ void __iomem *reg_pending = reg_base + PORTA_INT_STATUS;
+ void __iomem *reg_eoi = reg_base + PORTA_INT_EOI;
+
+ /* Which pin (if any) triggered the interrupt */
+ while ((pending = ioread32(reg_pending))) {
+ /*
+ * Acknowledge all the asserted GPIO interrupt lines before
+ * serving them, so that we don't lose an edge.
+ * This has only effect on edge-triggered interrupts.
+ */
+ iowrite32(pending, reg_eoi);
+
+ /* Serve each asserted interrupt */
+ do {
+ gpio = __ffs(pending);
+ generic_handle_irq(
+ gpio_to_irq(INTEL_QRK_GIP_GPIO_BASE + gpio));
+ pending &= ~BIT(gpio);
+ ret = IRQ_HANDLED;
+ } while(pending);
+ }
+
+ return ret;
+}
next prev parent reply other threads:[~2014-11-03 10:35 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-03 7:39 [PATCH 0/1] mfd: intel_quark_i2c_gpio: Add Intel Quark X1000 I2C-GPIO MFD Driver Raymond Tan
2014-11-03 7:39 ` [PATCH 1/1] " Raymond Tan
2014-11-03 9:11 ` Andy Shevchenko
2014-11-03 13:09 ` Lee Jones
2014-11-11 12:57 ` Tan, Raymond
2014-11-03 9:43 ` Bryan O'Donoghue
2014-11-04 9:10 ` Shevchenko, Andriy
2014-11-04 9:22 ` Lee Jones
2014-11-03 10:35 ` Bryan O'Donoghue [this message]
2014-11-04 0:46 ` Chen, Alvin
2014-11-04 0:51 ` Chen, Alvin
2014-11-04 10:54 ` Bryan O'Donoghue
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54575A68.7060009@nexus-software.ie \
--to=pure.logic@nexus-software.ie \
--cc=alvin.chen@intel.com \
--cc=andriy.shevchenko@intel.com \
--cc=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=raymond.tan@intel.com \
--cc=sameo@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.