linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Nancy Isaac <nancy.isaac@pobox.com>
To: linuxppc-dev@ozlabs.org
Subject: 8544 external interrupt configuration problems
Date: Thu, 28 May 2009 12:05:52 -0700	[thread overview]
Message-ID: <1bcc666d0905281205p63ee8119td5578a749bce8377@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 2488 bytes --]

Hi,

I have a custom board that's using powerpc 8544. I am trying to setup the
external interrupts using the device tree and I am having no luck getting
the interrupt.  I think my problem is that I don't have the hwirq to virq
mapping correctly. We are using the freescale 8544ds as our base.  We have a
PCI bus but we are not using PCIE.  In my kernel configuration, I have
CONFIG_PCIEPORTBUS disabled.  The PCI interrupt is connected to IRQ0 and it
is working fine.  But, my FPGA has three interrupts, IRQ1, IRQ2 and IRQ3.  I
configure this in the device tree and I've tried many different numbers for
the interrupt.

In the KConfig for ppc85xx, the configuration is the following

config MPC85xx_DS
    bool "Freescale MPC8544 DS"
    #select PPC_I8259
    select DEFAULT_UIMAGE
    select FSL_PCIE

config MPC85xx
    bool
    select PPC_UDBG_16550
    select PPC_INDIRECT_PCI
    select FSL_PCIE
    select SERIAL_8250_SHARE_IRQ if SERIAL_8250
    default y if MPC8540_ADS || MPC85xx_CDS || MPC8560_ADS \
        || MPC85xx_MDS || MPC85xx_DS

My .config has the following configuration for PCI ( I am showing the PCI
configuration b/c 8544 seems to have different interrupt setup when PCIE is
configured)

CONFIG_ZONE_DMA=y
# CONFIG_MPIC_WEIRD is not set
# CONFIG_PPC_I8259 is not set
CONFIG_PPC_INDIRECT_PCI=y
CONFIG_FSL_SOC=y
CONFIG_FSL_PCIE=y
CONFIG_PCI=y
CONFIG_PCI_DOMAINS=y
# CONFIG_PCIEPORTBUS is not set
CONFIG_PCI_DEBUG=y

My device tree has the following entry for my fpga:

CpuCpld\@f0000000{
                        compatible = "MPC8544DS";
                        device_type = "CpuCpld";
                        reg = <f0000000 00000040>;
                        interrupts = <41 2 42 2 43 2>;
                        interrupt-parent = <&mpic>;
};

My driver does the mapping to the virq:

 np = of_find_node_by_type(NULL, "CpuCpld");
    if (!np) {
        ret = -ENODEV;
    }
    cpldCpuDrv->MateIntIrq = irq_of_parse_and_map(np, 0);
    cpldCpuDrv->FtaIrq =  irq_of_parse_and_map(np, 1);
    cpldCpuDrv->ExtractIrq =  irq_of_parse_and_map(np, 2);
    cpldCpuDrv->XauiIrq =  irq_of_parse_and_map(np, 0);

    of_node_put(np);

Does anyone know what the virq should be for these external interrupts?
I've tried specifying the actual irq numbers 1,2 and 3 and that doesn't work
either.
Is there some PCI configuration that's getting in the way?  I've tried
disabling the FSL_PCIE and I get the same behavior.

Any help or pointers will be appreciated.

Thanks
Nancy

[-- Attachment #2: Type: text/html, Size: 2814 bytes --]

             reply	other threads:[~2009-05-28 19:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-28 19:05 Nancy Isaac [this message]
2009-05-28 20:02 ` 8544 external interrupt configuration problems Scott Wood
2009-05-29  1:48   ` Nancy Isaac
2009-05-29 17:09     ` Scott Wood
2009-05-29 17:20       ` Nancy Isaac

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=1bcc666d0905281205p63ee8119td5578a749bce8377@mail.gmail.com \
    --to=nancy.isaac@pobox.com \
    --cc=linuxppc-dev@ozlabs.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).