Device Tree & PCI

Benjamin Herrenschmidt benh at kernel.crashing.org
Sat Jan 12 19:27:39 EST 2008


>         pci_bridge at 12 {
>     		interrupt-map-mask = <0f800 0 0 7>;
>     		interrupt-map = <
>     		                /* IDSEL 0x10 */
>     		                00008000 0 0 1 &PCI_INT 1
> 
>     		                /* IDSEL 0x11 */
>     		                00008800 0 0 1 &PCI_INT 2
>     		                
>     		                /* IDSEL 0x12 */
>     		                00009000 0 0 1 &PCI_INT 3
>     		                
>     		                /* IDSEL 0x13 */
>     		                00009800 0 0 1 &PCI_INT 4>;
>         };

Your PCI bridge node needs more than those 2 properties. At the very
least it needs device_type "pci" and name "pci" (rather than pci-bridge)
to make the kernel parser happier, it also needs a proper class code and
a "reg" property providing its configuration address (devfn) so that the
kernel can do the matching between what it finds on the PCI bus and that
node.

Basically, you need to make sure the function pci_device_to_OF_node()
works for your bridge or the interrupt resolution will not work. I'd
suggest you add debugging to that function to dump what it's doing so
you can get your tree in order.

Cheers,
Ben.





More information about the Linuxppc-dev mailing list