From: robherring2@gmail.com (Rob Herring)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: gic: refactor irq_start assignment
Date: Tue, 17 Jan 2012 10:02:09 -0600 [thread overview]
Message-ID: <4F159B81.9080104@gmail.com> (raw)
In-Reply-To: <1326802195-11412-1-git-send-email-will.deacon@arm.com>
On 01/17/2012 06:09 AM, Will Deacon wrote:
> The irq_start and hwirq_base assignment code is fairly hairy and ended
> up being difficult to read following a conflict resolution for 3.2.
>
> This patch rearranges the code slightly to make it easier to read.
>
> Cc: Marc Zyngier <marc.zyngier@arm.com>
> Signed-off-by: Will Deacon <will.deacon@arm.com>
> ---
> arch/arm/common/gic.c | 13 ++++++-------
> 1 files changed, 6 insertions(+), 7 deletions(-)
>
> diff --git a/arch/arm/common/gic.c b/arch/arm/common/gic.c
> index c47d619..ca6b5dd 100644
> --- a/arch/arm/common/gic.c
> +++ b/arch/arm/common/gic.c
> @@ -694,13 +694,12 @@ void __init gic_init_bases(unsigned int gic_nr, int irq_start,
> * For primary GICs, skip over SGIs.
> * For secondary GICs, skip over PPIs, too.
> */
> - domain->hwirq_base = 32;
> - if (gic_nr == 0) {
> - if ((irq_start & 31) > 0) {
> - domain->hwirq_base = 16;
> - if (irq_start != -1)
> - irq_start = (irq_start & ~31) + 16;
> - }
> + if (gic_nr == 0 && (irq_start & 31) > 0) {
> + domain->hwirq_base = 16;
> + if (irq_start != -1)
> + irq_start = (irq_start & ~31) + 16;
> + } else {
> + domain->hwirq_base = 32;
> }
This should probably just be rolled into Grant's irqdomain work. In any
case, it's going to conflict with it.
Rob
next prev parent reply other threads:[~2012-01-17 16:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-17 12:09 [PATCH] ARM: gic: refactor irq_start assignment Will Deacon
2012-01-17 16:02 ` Rob Herring [this message]
2012-01-17 16:03 ` Will Deacon
2012-01-18 21:32 ` Grant Likely
2012-01-19 9:52 ` Will Deacon
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=4F159B81.9080104@gmail.com \
--to=robherring2@gmail.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).