I read the booting_without_of.txt document and the Interrupt Mapping
docucument from <a href="http://playground.sun.com/1275">http://playground.sun.com/1275</a>. But I don't understand
all parameters. Can somebody help me to create my device tree about
interrupt part ?<br>
<br>
I have an interrupt controller at the adresse 0x20006000. The irq_id range is 1 to 63.<br>
I would like to try UART interrupt, which have ids : 0x18 (tranmission fifo empty,<br>
0x19 (reception fifo full), 0x1a (reception error), 0x1b (break emission).<br>
What other informations are needed ?<br>
<br>
<br>
Nothing is cascaded.<br>
<br>
Thanks<br>
<br>
<br>
<br><br><div><span class="gmail_quote">2008/9/4, Benjamin Herrenschmidt <<a href="mailto:benh@kernel.crashing.org">benh@kernel.crashing.org</a>>:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On Wed, 2008-09-03 at 23:02 +0200, Sébastien Chrétien wrote:<br> <br> > irq_of_parse_and_map is equivalent to ioremap in the MMU case ?<br> <br> <br>On the powerpc architecture, we use virtualized IRQ numbers in order to<br>
deal with the wide range of interrupt controllers around and multiple<br> of them cascaded.<br> <br> The base function to "map" a physical interrupt to a virtual interrupt<br> is irq_create_mapping(). It takes an irq_host argument which represent<br>
the IRQ "domain" (typically irq controller) off which the interrupt you<br> are trying to map hangs.<br> <br> If you pass NULL, it will use the "default" controller, which doesn't<br> always exist, it depends on the platform. Usually, platforms set that<br>
to the toplevel PIC.<br> <br> However, normally, that function shouldn't be used directly. Instead,<br> you should create a representation of your device in the device-tree<br> along with the appropriate interrupt mapping, and then use the<br>
irq_of_parse_and_map() function to obtain a mapped virtual irq based<br> on the device-tree information. This will take care of finding the<br> right irq_host but will also properly setup the polarity of the<br> interrupt etc...<br>
<br> Now, as to how you should represent the interrupt in the device-tree,<br> this should be explained in Documentation/booting-without-of.txt<br> <br> Cheers,<br> Ben.<br> <br> </blockquote></div><br>