diff options
author | Jake Moilanen <moilanen@austin.ibm.com> | 2006-06-07 17:15:10 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-06-15 05:31:25 -0400 |
commit | 204face4fb3ba2ca09a4073e7debc595e14c2388 (patch) | |
tree | c98c1b576d249b392669a0d534598718af40478d /arch/powerpc/kernel | |
parent | bb53bb3dcb12d79efdee3d82bff46a204af377f3 (diff) |
[POWERPC] MSI abstraction
Instead of trying to make PPC64 MSI fit in a Intel-centric MSI layer, a
simple short-term solution is to hook the pci_{en/dis}able_msi() calls
and make a machdep call.
The rest of the MSI functions are superfluous for what is needed at this
time. Many of which can have machdep calls added as needed.
Ben and Michael Ellerman are looking into rewrite the MSI layer to be
more generic. However, in the meantime this works as a interim
solution.
Signed-off-by: Jake Moilanen <moilanen@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/irq.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c index 57d560c68897..bfcec4cc70a7 100644 --- a/arch/powerpc/kernel/irq.c +++ b/arch/powerpc/kernel/irq.c | |||
@@ -47,6 +47,7 @@ | |||
47 | #include <linux/cpumask.h> | 47 | #include <linux/cpumask.h> |
48 | #include <linux/profile.h> | 48 | #include <linux/profile.h> |
49 | #include <linux/bitops.h> | 49 | #include <linux/bitops.h> |
50 | #include <linux/pci.h> | ||
50 | 51 | ||
51 | #include <asm/uaccess.h> | 52 | #include <asm/uaccess.h> |
52 | #include <asm/system.h> | 53 | #include <asm/system.h> |
@@ -436,6 +437,30 @@ void do_softirq(void) | |||
436 | } | 437 | } |
437 | EXPORT_SYMBOL(do_softirq); | 438 | EXPORT_SYMBOL(do_softirq); |
438 | 439 | ||
440 | #ifdef CONFIG_PCI_MSI | ||
441 | int pci_enable_msi(struct pci_dev * pdev) | ||
442 | { | ||
443 | if (ppc_md.enable_msi) | ||
444 | return ppc_md.enable_msi(pdev); | ||
445 | else | ||
446 | return -1; | ||
447 | } | ||
448 | |||
449 | void pci_disable_msi(struct pci_dev * pdev) | ||
450 | { | ||
451 | if (ppc_md.disable_msi) | ||
452 | ppc_md.disable_msi(pdev); | ||
453 | } | ||
454 | |||
455 | void pci_scan_msi_device(struct pci_dev *dev) {} | ||
456 | int pci_enable_msix(struct pci_dev* dev, struct msix_entry *entries, int nvec) {return -1;} | ||
457 | void pci_disable_msix(struct pci_dev *dev) {} | ||
458 | void msi_remove_pci_irq_vectors(struct pci_dev *dev) {} | ||
459 | void disable_msi_mode(struct pci_dev *dev, int pos, int type) {} | ||
460 | void pci_no_msi(void) {} | ||
461 | |||
462 | #endif | ||
463 | |||
439 | #ifdef CONFIG_PPC64 | 464 | #ifdef CONFIG_PPC64 |
440 | static int __init setup_noirqdistrib(char *str) | 465 | static int __init setup_noirqdistrib(char *str) |
441 | { | 466 | { |