From: Tony Lindgren <tony@atomide.com>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: linux-arm-kernel@lists.arm.linux.org.uk,
Kim Kyuwon <chammoru@gmail.com>,
linux-omap@vger.kernel.org
Subject: Re: [PATCH 8/9] ARM: OMAP: Mask interrupts when disabling interrupts, v2
Date: Wed, 28 Jan 2009 11:07:01 -0800 [thread overview]
Message-ID: <20090128190700.GT32148@atomide.com> (raw)
In-Reply-To: <20090128185827.GD23301@n2100.arm.linux.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1853 bytes --]
* Russell King - ARM Linux <linux@arm.linux.org.uk> [090128 11:00]:
> On Wed, Jan 28, 2009 at 10:32:09AM -0800, Tony Lindgren wrote:
> > From: 김규원 <chammoru@gmail.com>
> >
> > By Ingo Molnar, interrupts are not masked by default.
> > (refer to 76d2160147f43f982dfe881404cfde9fd0a9da21)
> >
> > But if interrupts are not masked, the processor can wake up while in
> > Suspend-to-RAM state by an external interrupt. For example, if an
> > OMAP3 board is connected to Host PC by USB and entered to Suspend-to-RAM
> > state, it wake up automatically by M_IRQ_92. The disable_irq() function
> > can't disable the interrupt in H/W level, So I modified
> > arch/arm/mach-omap2/irq.c
> >
> > Signed-off-by: Kim Kyuwon <chammoru@gmail.com>
> > Signed-off-by: Tony Lindgren <tony@atomide.com>
> > ---
> > arch/arm/mach-omap2/irq.c | 6 ++++++
> > 1 files changed, 6 insertions(+), 0 deletions(-)
> >
> > diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
> > index 636e282..52772f9 100644
> > --- a/arch/arm/mach-omap2/irq.c
> > +++ b/arch/arm/mach-omap2/irq.c
> > @@ -123,6 +123,11 @@ static void omap_unmask_irq(unsigned int irq)
> > intc_bank_write_reg(1 << irq, &irq_banks[0], INTC_MIR_CLEAR0 + offset);
> > }
> >
> > +static void omap_disable_irq(unsigned int irq)
> > +{
> > + omap_mask_irq(irq);
> > +}
> > +
> > static void omap_mask_ack_irq(unsigned int irq)
> > {
> > omap_mask_irq(irq);
> > @@ -134,6 +139,7 @@ static struct irq_chip omap_irq_chip = {
> > .ack = omap_mask_ack_irq,
> > .mask = omap_mask_irq,
> > .unmask = omap_unmask_irq,
> > + .disable = omap_disable_irq,
>
> There's no need for the indirection - omap_mask_irq() already has the
> required prototype for the .disable function. So this patch should just
> be adding:
>
> .disable = omap_mask_irq,
OK, here's the updated patch.
Tony
[-- Attachment #2: disable-irq-v2.patch --]
[-- Type: text/x-diff, Size: 1227 bytes --]
>From 12db1a5a7e0de12b643c2666f95f4840942aad49 Mon Sep 17 00:00:00 2001
From: =?utf-8?q?=EA=B9=80=EA=B7=9C=EC=9B=90?= <chammoru@gmail.com>
Date: Tue, 27 Jan 2009 12:58:16 -0800
Subject: [PATCH] ARM: OMAP: Mask interrupts when disabling interrupts, v2
By Ingo Molnar, interrupts are not masked by default.
(refer to 76d2160147f43f982dfe881404cfde9fd0a9da21)
But if interrupts are not masked, the processor can wake up while in
Suspend-to-RAM state by an external interrupt. For example, if an
OMAP3 board is connected to Host PC by USB and entered to Suspend-to-RAM
state, it wake up automatically by M_IRQ_92. The disable_irq() function
can't disable the interrupt in H/W level, So I modified
arch/arm/mach-omap2/irq.c
Signed-off-by: Kim Kyuwon <chammoru@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
index 636e282..9ba20d9 100644
--- a/arch/arm/mach-omap2/irq.c
+++ b/arch/arm/mach-omap2/irq.c
@@ -134,6 +134,7 @@ static struct irq_chip omap_irq_chip = {
.ack = omap_mask_ack_irq,
.mask = omap_mask_irq,
.unmask = omap_unmask_irq,
+ .disable = omap_mask_irq,
};
static void __init omap_irq_bank_init_one(struct omap_irq_bank *bank)
next prev parent reply other threads:[~2009-01-28 19:07 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-28 18:21 [PATCH 0/9] Omap fixes for 2.6.29-rc series, also one arm generic fix Tony Lindgren
2009-01-28 18:23 ` [PATCH 1/9] ARM: Do early I/O mapping if spinlock debugging is enabled Tony Lindgren
2009-01-28 18:53 ` Russell King - ARM Linux
2009-01-28 23:51 ` David Brownell
2009-01-29 16:52 ` Tony Lindgren
2009-01-28 18:24 ` [PATCH 2/9] ARM: OMAP: Fix McBSP spin_lock deadlock Tony Lindgren
2009-01-28 19:27 ` Russell King - ARM Linux
2009-01-28 21:28 ` Tony Lindgren
2009-01-28 23:53 ` David Brownell
2009-01-29 0:51 ` Tony Lindgren
2009-01-29 2:05 ` David Brownell
2009-01-28 18:25 ` [PATCH 3/9] ARM: OMAP: Fix race in OMAP2/3 DMA IRQ handling Tony Lindgren
2009-01-28 18:26 ` [PATCH 4/9] ARM: OMAP: DMA: Fix uninitialized channel flags Tony Lindgren
2009-01-28 18:28 ` [PATCH 5/9] ARM: OMAP: Fix omap34xx revision detection for ES3.1 Tony Lindgren
2009-01-28 18:29 ` [PATCH 6/9] ARM: OMAP: Fix hsmmc init Tony Lindgren
2009-01-28 19:08 ` Russell King - ARM Linux
2009-01-29 18:48 ` [PATCH 6/9] ARM: OMAP: Fix hsmmc init, v2 Tony Lindgren
2009-01-28 18:30 ` [PATCH 7/9] ARM: OMAP: gptimer min_delta_ns corrected Tony Lindgren
2009-01-28 18:32 ` [PATCH 8/9] ARM: OMAP: Mask interrupts when disabling interrupts Tony Lindgren
2009-01-28 18:58 ` Russell King - ARM Linux
2009-01-28 19:07 ` Tony Lindgren [this message]
2009-01-28 18:33 ` [PATCH 9/9] ARM: OMAP: fix fault in enter_full_retention() Tony Lindgren
2009-01-28 19:21 ` [PATCH 0/9] Omap fixes for 2.6.29-rc series, also one arm generic fix Russell King - ARM Linux
2009-01-29 18:49 ` git pull request for omap-fixes (Re: [PATCH 0/9] Omap fixes for 2.6.29-rc series, also one arm generic fix) Tony Lindgren
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=20090128190700.GT32148@atomide.com \
--to=tony@atomide.com \
--cc=chammoru@gmail.com \
--cc=linux-arm-kernel@lists.arm.linux.org.uk \
--cc=linux-omap@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
/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