]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
[POWERPC] pasemi: Configure DMA controller interrupts
authorOlof Johansson <olof@lixom.net>
Sun, 4 Feb 2007 22:36:54 +0000 (16:36 -0600)
committerPaul Mackerras <paulus@samba.org>
Wed, 7 Feb 2007 03:03:22 +0000 (14:03 +1100)
The DMA controller on PWRficient is somewhat special -- has a PCI header
so it looks like it's on the root PCI (-Express) root bus, but it uses
more than the default number of interrupts (and they are hardwired).

We need to wire up all interrupts for the DMA controller. The generic
IRQ code will only map the primary interrupt from the PCI header (128),
so add 129->211 by hand.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/platforms/pasemi/pasemi.h
arch/powerpc/platforms/pasemi/pci.c
arch/powerpc/platforms/pasemi/setup.c

index 94fd00cc6a10fdf023e270bf144b00bf5717ddd5..8391e31d47336700ddf4ebd856fb6895974d56bf 100644 (file)
@@ -3,6 +3,7 @@
 
 extern unsigned long pas_get_boot_time(void);
 extern void pas_pci_init(void);
+extern void __devinit pas_pci_irq_fixup(struct pci_dev *dev);
 
 extern void __init pasemi_idle_init(void);
 
index faa618e0404767217430eaa86d5a03f075efc8b8..7ecb2ba24db9cd26c0b0c80fe13c61a57caa5641 100644 (file)
@@ -163,6 +163,19 @@ static void __init pas_fixup_phb_resources(void)
 }
 
 
+void __devinit pas_pci_irq_fixup(struct pci_dev *dev)
+{
+       /* DMA is special, 84 interrupts (128 -> 211), all but 128
+        * need to be mapped by hand here.
+        */
+       if (dev->vendor == 0x1959 && dev->device == 0xa007) {
+               int i;
+               for (i = 129; i < 212; i++)
+                       irq_create_mapping(NULL, i);
+       }
+}
+
+
 void __init pas_pci_init(void)
 {
        struct device_node *np, *root;
index 2d9652b6acb352b3e744e1af9b8e37905436c784..9096aac1c622c177d259bee9dfac434f4e15af55 100644 (file)
@@ -235,4 +235,5 @@ define_machine(pas) {
        .check_legacy_ioport    = pas_check_legacy_ioport,
        .progress               = pas_progress,
        .machine_check_exception = pas_machine_check_handler,
+       .pci_irq_fixup          = pas_pci_irq_fixup,
 };