From: Santosh Shilimkar <santosh.shilimkar@ti.com>
To: Andreas Fenkart <andreas.fenkart@streamunlimited.com>, jon-hunter@ti.com
Cc: khilman@deeprootsystems.com, grant.likely@secretlab.ca,
linus.walleij@linaro.org, linux-omap@vger.kernel.org,
daniel@zonque.org
Subject: Re: [PATCH] gpio/omap: implement irq_enable/disable using mask/unmask.
Date: Fri, 12 Apr 2013 15:49:52 +0530 [thread overview]
Message-ID: <5167DFC8.8060202@ti.com> (raw)
In-Reply-To: <1365758001-15562-2-git-send-email-andreas.fenkart@streamunlimited.com>
On Friday 12 April 2013 02:43 PM, Andreas Fenkart wrote:
> In PM suspend, some omaps can't detect sdio irqs via the sdio interface.
> The way to implement this, is to declare the corresponding pin as part
> of the sdio interface and as a gpio input via pinctrl-single states.
> The MMC driver request states "default" "active" and "idle" during the
> probe, then toggles between active and idle during the runtime. This
> requires low overhead functions for enable/disable of gpio irqs.
>
> For level triggered interrupt there is no difference between masking
> and disabling an interrupt. For edge interrupt interrupts there is.
> When masked, interrupts should still be latched to the interrupt status
> register so when unmasked later there is an interrupt straight away.
> However, if the interrupt is disabled then gpio events occurring will not
> be latched/stored. Hence proposed patch is incomplete for edge type
> interrupts.
>
> Signed-off-by: Andreas Fenkart <andreas.fenkart@streamunlimited.com>
> ---
Patch is incomplete and still confusing ;-) if some one reads the
patch without the thread. I think you have already ask the question/
suggestion in past but its better to split masking/disabling functions
and make them behave properly. Mapping enable/disable to mask/unmask
to get around the issue seems more of a hack.
Also I think, we can address the edge type IRQ issue along with this
patch to be complete.
Before you go ahead with the update, I would like to hear Jon's
opinion on the edge IRQ related fixing.
> drivers/gpio/gpio-omap.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
> index 159f5c5..69ef2d8 100644
> --- a/drivers/gpio/gpio-omap.c
> +++ b/drivers/gpio/gpio-omap.c
> @@ -815,6 +815,8 @@ static struct irq_chip gpio_irq_chip = {
> .irq_unmask = gpio_unmask_irq,
> .irq_set_type = gpio_irq_type,
> .irq_set_wake = gpio_wake_enable,
> + .irq_disable = gpio_mask_irq, /* FIXME for edge type IRQ */
> + .irq_enable = gpio_unmask_irq,
> };
>
> /*---------------------------------------------------------------------*/
>
Sorry to make you wait for the proposal discussion.
Regards,
Santosh
next prev parent reply other threads:[~2013-04-12 10:18 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-12 9:13 [PATCH v2] gpio/omap: implement irq_enable/disable using mask/unmask Andreas Fenkart
2013-04-12 9:13 ` [PATCH] " Andreas Fenkart
2013-04-12 10:19 ` Santosh Shilimkar [this message]
2013-04-12 11:07 ` Felipe Balbi
2013-04-19 19:25 ` Andreas Fenkart
2013-04-19 19:20 ` [PATCH v2] gpio/omap: implement irq mask/disable with proper semantic Andreas Fenkart
2013-04-20 12:35 ` Santosh Shilimkar
2013-04-22 8:54 ` [PATCH v3] gpio/omap: implement irq mask/disable with proper Andreas Fenkart
2013-04-22 8:54 ` [PATCH v3] gpio/omap: implement irq mask/disable with proper semantic Andreas Fenkart
2013-04-23 23:38 ` Kevin Hilman
2013-04-25 19:30 ` Jon Hunter
2013-04-25 19:40 ` Jon Hunter
2013-04-26 15:46 ` Jon Hunter
2013-04-26 7:56 ` [PATCH v2] " Linus Walleij
-- strict thread matches above, loose matches on Subject: below --
2012-12-17 9:27 [PATCH] gpio/omap: implement irq_enable/disable using mask/unmask Andreas Fenkart
2012-12-20 5:59 ` Santosh Shilimkar
2012-12-20 16:16 ` Jon Hunter
2013-03-25 22:24 ` Andreas Fenkart
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=5167DFC8.8060202@ti.com \
--to=santosh.shilimkar@ti.com \
--cc=andreas.fenkart@streamunlimited.com \
--cc=daniel@zonque.org \
--cc=grant.likely@secretlab.ca \
--cc=jon-hunter@ti.com \
--cc=khilman@deeprootsystems.com \
--cc=linus.walleij@linaro.org \
--cc=linux-omap@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).