linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: linuxppc-dev@lists.ozlabs.org
Subject: Re: kilauea/405ex external interrupts
Date: Mon, 22 Jun 2009 11:23:11 +0200	[thread overview]
Message-ID: <200906221123.11192.sr@denx.de> (raw)
In-Reply-To: <e35801cc0906190100i1a0429eahade975319b5246df@mail.gmail.com>

On Friday 19 June 2009 10:00:52 Lada Podivin wrote:
> I'm writing a linux driver that uses an external interrupt (ppc 405ex). I'm
> using GPIO pin 30 (external IRQ 1) connected to UIC1. I'm aware of the
> virtual interrupt stuff, so I added a new node to my device tree in order
> to get proper virtual IRQ number. This node describes an external event and
> its connection to UIC via the mentioned ext. int. Here is a sample of the
> divce-tree:

<snip>

> EXTEVENT: external_event {
>         device_type = "external";
>         #address-cells = <0>;
>         #size-cells = <0>;
>         #interrupt-cells = <2>;
>         interrupts = <0x1e 0x1>;
>         interrupt-parent = <&UIC1>;
> };
> ...
>
> Then I use function "irq_of_parse_and_map()" which returns the virtual IRQ
> number 22. So, "request_irq()" seems to be satisfied with this number. I
> can see this interrupt in the /proc/interrupts. But! When I connect a
> signal source to the pin 30, nothing happens - the interrupt service
> routine isn't called.
>
> Am I suppose to configure anything else? (e. g. pin multiplexing, further
> device-tree tuning...) Thank you!

Yes, this could very well be a problem of pin multiplexing. From looking at 
the Kilauea GPIO/Pin mux configuration in U-Boot, GPIO30 is configured as GPIO 
input and not as IRQ1. So this can't work. The easiest way to change this is 
in U-Boot (include/configs/kilauea.h).

BTW: Are you using Kilauea or a custom 405EX board?

Best regards,
Stefan

  parent reply	other threads:[~2009-06-22  9:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-19  8:00 kilauea/405ex external interrupts Lada Podivin
2009-06-19 18:51 ` Tirumala Reddy Marri
2009-06-22  9:23 ` Stefan Roese [this message]
2009-06-22 11:31   ` Lada Podivin

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=200906221123.11192.sr@denx.de \
    --to=sr@denx.de \
    --cc=linuxppc-dev@lists.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).