]> git.baikalelectronics.ru Git - kernel.git/commit
[SPARC64]: Rewrite pci_intmap_match().
authorDavid S. Miller <davem@sunset.davemloft.net>
Fri, 17 Feb 2006 07:01:10 +0000 (23:01 -0800)
committerDavid S. Miller <davem@sunset.davemloft.net>
Mon, 20 Mar 2006 09:13:20 +0000 (01:13 -0800)
commit0f7a047d8bc1c5dbb7b9cd8addd8bf80bf0ee8f6
tree8abc4d83ed8ddef986de2c0593f55d3e879c7c78
parentf2fe168ace1bee14690153a0c3718c58c51df486
[SPARC64]: Rewrite pci_intmap_match().

The whole algorithm was wrong.  What we need to do is:

1) Walk each PCI bus above this device on the path to the
   PCI controller nexus, and for each:
      a) If interrupt-map exists, apply it, record IRQ controller node
      b) Else, swivel interrupt number using PCI_SLOT(), use PCI bus
 parent OBP node as controller node
      c) Walk up to "controller node" until we hit the first PCI bus
 in this domain, or "controller node" is the PCI controller
 OBP node
2) If we walked to PCI controller OBP node, we're done.
3) Else, apply PCI controller interrupt-map to interrupt.

There is some stuff that needs to be checked out for ebus and
isa, but the PCI part is good to go.

Signed-off-by: David S. Miller <davem@davemloft.net>
arch/sparc64/kernel/pci_common.c