linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Josh Boyer <jwboyer@linux.vnet.ibm.com>
To: Grant Erickson <gerickson@nuovations.com>
Cc: linuxppc-dev@ozlabs.org, Stefan Roese <sr@denx.de>,
	bluesmoke-devel@lists.sourceforge.net
Subject: Re: [PATCH v2] powerpc/4xx: DTS: Add Add'l SDRAM0 Compatible and Interrupt Info
Date: Thu, 18 Dec 2008 13:34:02 -0500	[thread overview]
Message-ID: <20081218183402.GC23637@localhost.localdomain> (raw)
In-Reply-To: <C56FD0C0.1386E%gerickson@nuovations.com>

On Thu, Dec 18, 2008 at 10:04:48AM -0800, Grant Erickson wrote:
>On 12/18/08 9:56 AM, Josh Boyer wrote:
>> On Thu, Dec 18, 2008 at 09:04:23AM +0100, Stefan Roese wrote:
>>> On Thursday 18 December 2008, Grant Erickson wrote:
>>>> diff --git a/arch/powerpc/boot/dts/haleakala.dts
>>>> b/arch/powerpc/boot/dts/haleakala.dts index 513bc43..64880ab 100644
>>>> --- a/arch/powerpc/boot/dts/haleakala.dts
>>>> +++ b/arch/powerpc/boot/dts/haleakala.dts
>>>> @@ -89,8 +89,14 @@
>>>> clock-frequency = <0>; /* Filled in by U-Boot */
>>>> 
>>>> SDRAM0: memory-controller {
>>>> -   compatible = "ibm,sdram-405exr";
>>>> +   compatible = "ibm,sdram-405exr", "ibm,sdram-4xx-ddr2";
>>>> dcr-reg = <0x010 0x002>;
>>>> +   #interrupt-cells = <1>;
>>>> +   interrupt-parent = <&SDRAM0>;
>>>> +   interrupts = <0x0 0x1>;
>>>> +   interrupt-map = </* ECCDED Error */ 0x0 &UIC2 0x5 0x4
>>>> +      /* ECCSEC Error */ 0x1 &UIC2 0x6 0x4>;
>>>> +   interrupt-map-mask = <0xffffffff>;
>>> 
>>> When all interrupts are mapped the same parent, this should do as well:
>>> 
>>> interrupt-parent = <&UIC2>;
>>> interrupts = <0x5 0x4 /* ECCDED Error */
>>>      0x6 0x4>; /* ECCSEC Error */
>>> 
>>> Other than this:
>>> 
>>> Acked-by: Stefan Roese <sr@denx.de>
>> 
>> Yeah, I agree.  Adding an interrupt map when it's not needed is
>> just complexity that doesn't need to be there.
>
>Stefan and Josh:
>
>From a programmatic perspective, does the above still allow the code to
>index virtual interrupt indices 0 and 1 rather than 5 and 6 when calling
>irq_of_parse_and_map()?

Yes.  The index parameter to irq_of_parse_and_map is just an index into
the interrupts property.  So index 0 will use the first set of numbers
that matches the required #interrupt-cells.  In this case it's two, one
for the hardware irq number and one for the level/edge/polarity settings.

josh

      reply	other threads:[~2008-12-18 18:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-18  1:31 [PATCH v2] powerpc/4xx: DTS: Add Add'l SDRAM0 Compatible and Interrupt Info Grant Erickson
2008-12-18  1:54 ` David Gibson
2008-12-18  8:04 ` Stefan Roese
2008-12-18 17:56   ` Josh Boyer
2008-12-18 18:04     ` Grant Erickson
2008-12-18 18:34       ` Josh Boyer [this message]

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=20081218183402.GC23637@localhost.localdomain \
    --to=jwboyer@linux.vnet.ibm.com \
    --cc=bluesmoke-devel@lists.sourceforge.net \
    --cc=gerickson@nuovations.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=sr@denx.de \
    /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).