From: tony@atomide.com (Tony Lindgren)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 01/10] omap: Use separate init_irq functions to avoid cpu_is_omap tests early
Date: Tue, 29 Mar 2011 10:14:51 -0700 [thread overview]
Message-ID: <20110329171451.GI4016@atomide.com> (raw)
In-Reply-To: <874o6lg8cv.fsf@ti.com>
* Kevin Hilman <khilman@ti.com> [110329 10:08]:
> Hi Tony,
>
> Tony Lindgren <tony@atomide.com> writes:
>
> > This allows us to remove cpu_is_omap calls from init_irq functions
> > and the irq handler. There should not be any need for cpu_is_omap
> > as at this point we only care about SoC generation, and not about
> > subcategories.
> >
> > The main reason for the patch is that we want to initialize only
> > minimal omap specific code from the init_early call, and this and
> > the following patches get us closer to that goal.
> >
> > Signed-off-by: Tony Lindgren <tony@atomide.com>
>
> [...]
>
> A couple of minor comments on naming below...
>
> > diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
> > index bc524b9..33a5c0d 100644
> > --- a/arch/arm/mach-omap2/irq.c
> > +++ b/arch/arm/mach-omap2/irq.c
> > @@ -103,28 +103,36 @@ static void omap_ack_irq(struct irq_data *d)
> > intc_bank_write_reg(0x1, &irq_banks[0], INTC_CONTROL);
> > }
> >
> > +static inline void _omap_mask_irq(int irq)
> > +{
> > + int offset = irq & (~(IRQ_BITS_PER_REG - 1));
> > + irq &= (IRQ_BITS_PER_REG - 1);
> > + intc_bank_write_reg(1 << irq, &irq_banks[0], INTC_MIR_SET0 + offset);
> > +}
> > +
> > static void omap_mask_irq(struct irq_data *d)
> > {
> > unsigned int irq = d->irq;
> > - int offset = irq & (~(IRQ_BITS_PER_REG - 1));
> >
> > - if (cpu_is_omap34xx() && !cpu_is_ti816x()) {
> > - int spurious = 0;
> > + _omap_mask_irq(irq);
> > +}
> >
> > - /*
> > - * INT_34XX_GPT12_IRQ is also the spurious irq. Maybe because
> > - * it is the highest irq number?
> > - */
> > - if (irq == INT_34XX_GPT12_IRQ)
> > - spurious = omap_check_spurious(irq);
> > +static void omap_mask_irq_omap3(struct irq_data *d)
>
> how about omap3_mask_irq().
>
> In most other code we're using the SoC name as a prefix instead of
> suffix.
>
> > +{
> > + unsigned int irq = d->irq;
> > + int spurious = 0;
> >
> > - if (!spurious)
> > - previous_irq = irq;
> > - }
> > + /*
> > + * INT_34XX_GPT12_IRQ is also the spurious irq. Maybe because
> > + * it is the highest irq number?
> > + */
> > + if (irq == INT_34XX_GPT12_IRQ)
> > + spurious = omap_check_spurious(irq);
> >
> > - irq &= (IRQ_BITS_PER_REG - 1);
> > + if (!spurious)
> > + previous_irq = irq;
> >
> > - intc_bank_write_reg(1 << irq, &irq_banks[0], INTC_MIR_SET0 + offset);
> > + _omap_mask_irq(irq);
> > }
> >
> > static void omap_unmask_irq(struct irq_data *d)
> > @@ -143,6 +151,12 @@ static void omap_mask_ack_irq(struct irq_data *d)
> > omap_ack_irq(d);
> > }
> >
> > +static void omap_mask_ack_irq_omap3(struct irq_data *d)
>
> Also here: omap3_mask_ack_irq()
Sounds good to me.
Tony
next prev parent reply other threads:[~2011-03-29 17:14 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-28 22:21 [PATCH 00/10] omap init_early changes for irq and timer init Tony Lindgren
2011-03-28 22:21 ` [PATCH 01/10] omap: Use separate init_irq functions to avoid cpu_is_omap tests early Tony Lindgren
2011-03-29 6:11 ` [PATCH 01/10] omap: Use separate init_irq functions to avoidcpu_is_omap " Santosh Shilimkar
2011-03-29 6:11 ` Santosh Shilimkar
2011-03-29 15:30 ` Tony Lindgren
2011-03-29 22:27 ` Tony Lindgren
2011-03-29 6:11 ` Santosh Shilimkar
2011-03-29 6:11 ` Santosh Shilimkar
2011-03-29 17:11 ` [PATCH 01/10] omap: Use separate init_irq functions to avoid cpu_is_omap " Kevin Hilman
2011-03-29 17:14 ` Tony Lindgren [this message]
2011-05-17 11:28 ` Tony Lindgren
2011-03-28 22:21 ` [PATCH 02/10] omap: Set separate timer init functions to avoid cpu_is_omap tests Tony Lindgren
2011-03-28 22:21 ` [PATCH 03/10] omap: Move dmtimer defines to dmtimer.h Tony Lindgren
2011-03-29 17:41 ` Kevin Hilman
2011-03-29 17:44 ` Tony Lindgren
2011-03-28 22:21 ` [PATCH 04/10] omap: Make a subset of dmtimer functions into inline functions Tony Lindgren
2011-03-29 17:51 ` Kevin Hilman
2011-03-29 17:58 ` Tony Lindgren
2011-03-29 18:01 ` Kevin Hilman
2011-03-29 18:02 ` Tony Lindgren
2011-03-28 22:21 ` [PATCH 05/10] omap2+: Use dmtimer macros for clockevent Tony Lindgren
2011-03-29 17:16 ` Tony Lindgren
2011-03-31 21:35 ` Kevin Hilman
2011-03-31 22:04 ` Tony Lindgren
2011-03-28 22:21 ` [PATCH 06/10] omap2+: Remove gptimer_wakekup for now Tony Lindgren
2011-03-31 22:09 ` Kevin Hilman
2011-04-01 16:26 ` Santosh Shilimkar
2011-03-28 22:21 ` [PATCH 07/10] omap2+: Reserve clocksource and timesource and initialize dmtimer later Tony Lindgren
2011-03-28 22:21 ` [PATCH 08/10] omap2+: Use dmtimer macros for clocksource Tony Lindgren
2011-03-28 22:21 ` [PATCH 09/10] omap2+: Remove omap2_gp_clockevent_set_gptimer Tony Lindgren
2011-03-28 22:21 ` [PATCH 10/10] omap2+: Rename timer-gp.c into timer.c to combine timer init functions Tony Lindgren
2011-03-29 18:16 ` [PATCH 00/10] omap init_early changes for irq and timer init Kevin Hilman
2011-03-30 7:56 ` Santosh Shilimkar
2011-03-30 18:22 ` Tony Lindgren
2011-03-31 8:16 ` Santosh Shilimkar
2011-03-31 17:32 ` Tony Lindgren
2011-04-01 8:39 ` Santosh Shilimkar
-- strict thread matches above, loose matches on Subject: below --
2011-06-20 9:23 [PATCH 00/10] init_early cleanup for omap init_irq and init_timer Tony Lindgren
2011-06-20 9:23 ` [PATCH 01/10] omap: Use separate init_irq functions to avoid cpu_is_omap tests early Tony Lindgren
2011-06-20 9:54 ` Russell King - ARM Linux
2011-06-20 10:14 ` Tony Lindgren
2011-06-27 17:08 ` Kevin Hilman
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=20110329171451.GI4016@atomide.com \
--to=tony@atomide.com \
--cc=linux-arm-kernel@lists.infradead.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).