diff options
-rw-r--r-- | arch/i386/kernel/io_apic.c | 5 | ||||
-rw-r--r-- | arch/x86_64/kernel/io_apic.c | 1 | ||||
-rw-r--r-- | drivers/pci/Kconfig | 1 | ||||
-rw-r--r-- | drivers/pci/Makefile | 4 | ||||
-rw-r--r-- | drivers/pci/htirq.c | 1 | ||||
-rw-r--r-- | include/linux/htirq.h | 15 | ||||
-rw-r--r-- | include/linux/pci.h | 11 |
7 files changed, 22 insertions, 16 deletions
diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index 5a1252753dbb..b7287fb499f3 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <linux/sysdev.h> | 33 | #include <linux/sysdev.h> |
34 | #include <linux/pci.h> | 34 | #include <linux/pci.h> |
35 | #include <linux/msi.h> | 35 | #include <linux/msi.h> |
36 | #include <linux/htirq.h> | ||
36 | 37 | ||
37 | #include <asm/io.h> | 38 | #include <asm/io.h> |
38 | #include <asm/smp.h> | 39 | #include <asm/smp.h> |
@@ -2409,9 +2410,8 @@ static int __init ioapic_init_sysfs(void) | |||
2409 | 2410 | ||
2410 | device_initcall(ioapic_init_sysfs); | 2411 | device_initcall(ioapic_init_sysfs); |
2411 | 2412 | ||
2412 | #ifdef CONFIG_PCI_MSI | ||
2413 | /* | 2413 | /* |
2414 | * Dynamic irq allocate and deallocation for MSI | 2414 | * Dynamic irq allocate and deallocation |
2415 | */ | 2415 | */ |
2416 | int create_irq(void) | 2416 | int create_irq(void) |
2417 | { | 2417 | { |
@@ -2450,7 +2450,6 @@ void destroy_irq(unsigned int irq) | |||
2450 | irq_vector[irq] = 0; | 2450 | irq_vector[irq] = 0; |
2451 | spin_unlock_irqrestore(&vector_lock, flags); | 2451 | spin_unlock_irqrestore(&vector_lock, flags); |
2452 | } | 2452 | } |
2453 | #endif /* CONFIG_PCI_MSI */ | ||
2454 | 2453 | ||
2455 | /* | 2454 | /* |
2456 | * MSI mesage composition | 2455 | * MSI mesage composition |
diff --git a/arch/x86_64/kernel/io_apic.c b/arch/x86_64/kernel/io_apic.c index e55028fba942..91728d9d3472 100644 --- a/arch/x86_64/kernel/io_apic.c +++ b/arch/x86_64/kernel/io_apic.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <linux/acpi.h> | 31 | #include <linux/acpi.h> |
32 | #include <linux/sysdev.h> | 32 | #include <linux/sysdev.h> |
33 | #include <linux/msi.h> | 33 | #include <linux/msi.h> |
34 | #include <linux/htirq.h> | ||
34 | #ifdef CONFIG_ACPI | 35 | #ifdef CONFIG_ACPI |
35 | #include <acpi/acpi_bus.h> | 36 | #include <acpi/acpi_bus.h> |
36 | #endif | 37 | #endif |
diff --git a/drivers/pci/Kconfig b/drivers/pci/Kconfig index 0af6d7288415..30294127a0aa 100644 --- a/drivers/pci/Kconfig +++ b/drivers/pci/Kconfig | |||
@@ -55,7 +55,6 @@ config PCI_DEBUG | |||
55 | config HT_IRQ | 55 | config HT_IRQ |
56 | bool "Interrupts on hypertransport devices" | 56 | bool "Interrupts on hypertransport devices" |
57 | default y | 57 | default y |
58 | depends on PCI_MSI | ||
59 | depends on X86_LOCAL_APIC && X86_IO_APIC | 58 | depends on X86_LOCAL_APIC && X86_IO_APIC |
60 | help | 59 | help |
61 | This allows native hypertransport devices to use interrupts. | 60 | This allows native hypertransport devices to use interrupts. |
diff --git a/drivers/pci/Makefile b/drivers/pci/Makefile index 04694ec7224b..e3beb784406f 100644 --- a/drivers/pci/Makefile +++ b/drivers/pci/Makefile | |||
@@ -17,6 +17,9 @@ obj-$(CONFIG_HOTPLUG_PCI) += hotplug/ | |||
17 | # Build the PCI MSI interrupt support | 17 | # Build the PCI MSI interrupt support |
18 | obj-$(CONFIG_PCI_MSI) += msi.o | 18 | obj-$(CONFIG_PCI_MSI) += msi.o |
19 | 19 | ||
20 | # Build the Hypertransport interrupt support | ||
21 | obj-$(CONFIG_HT_IRQ) += htirq.o | ||
22 | |||
20 | # | 23 | # |
21 | # Some architectures use the generic PCI setup functions | 24 | # Some architectures use the generic PCI setup functions |
22 | # | 25 | # |
@@ -29,7 +32,6 @@ obj-$(CONFIG_PPC32) += setup-irq.o | |||
29 | obj-$(CONFIG_PPC64) += setup-bus.o | 32 | obj-$(CONFIG_PPC64) += setup-bus.o |
30 | obj-$(CONFIG_MIPS) += setup-bus.o setup-irq.o | 33 | obj-$(CONFIG_MIPS) += setup-bus.o setup-irq.o |
31 | obj-$(CONFIG_X86_VISWS) += setup-irq.o | 34 | obj-$(CONFIG_X86_VISWS) += setup-irq.o |
32 | obj-$(CONFIG_HT_IRQ) += htirq.o | ||
33 | 35 | ||
34 | # | 36 | # |
35 | # ACPI Related PCI FW Functions | 37 | # ACPI Related PCI FW Functions |
diff --git a/drivers/pci/htirq.c b/drivers/pci/htirq.c index 4ba46359d367..0e27f2404a83 100644 --- a/drivers/pci/htirq.c +++ b/drivers/pci/htirq.c | |||
@@ -11,6 +11,7 @@ | |||
11 | #include <linux/spinlock.h> | 11 | #include <linux/spinlock.h> |
12 | #include <linux/slab.h> | 12 | #include <linux/slab.h> |
13 | #include <linux/gfp.h> | 13 | #include <linux/gfp.h> |
14 | #include <linux/htirq.h> | ||
14 | 15 | ||
15 | /* Global ht irq lock. | 16 | /* Global ht irq lock. |
16 | * | 17 | * |
diff --git a/include/linux/htirq.h b/include/linux/htirq.h new file mode 100644 index 000000000000..1f15ce279a23 --- /dev/null +++ b/include/linux/htirq.h | |||
@@ -0,0 +1,15 @@ | |||
1 | #ifndef LINUX_HTIRQ_H | ||
2 | #define LINUX_HTIRQ_H | ||
3 | |||
4 | /* Helper functions.. */ | ||
5 | void write_ht_irq_low(unsigned int irq, u32 data); | ||
6 | void write_ht_irq_high(unsigned int irq, u32 data); | ||
7 | u32 read_ht_irq_low(unsigned int irq); | ||
8 | u32 read_ht_irq_high(unsigned int irq); | ||
9 | void mask_ht_irq(unsigned int irq); | ||
10 | void unmask_ht_irq(unsigned int irq); | ||
11 | |||
12 | /* The arch hook for getting things started */ | ||
13 | int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev); | ||
14 | |||
15 | #endif /* LINUX_HTIRQ_H */ | ||
diff --git a/include/linux/pci.h b/include/linux/pci.h index 0da5a4a8940f..5c604f5fad67 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -615,20 +615,9 @@ extern void msi_remove_pci_irq_vectors(struct pci_dev *dev); | |||
615 | #endif | 615 | #endif |
616 | 616 | ||
617 | #ifdef CONFIG_HT_IRQ | 617 | #ifdef CONFIG_HT_IRQ |
618 | /* Helper functions.. */ | ||
619 | void write_ht_irq_low(unsigned int irq, u32 data); | ||
620 | void write_ht_irq_high(unsigned int irq, u32 data); | ||
621 | u32 read_ht_irq_low(unsigned int irq); | ||
622 | u32 read_ht_irq_high(unsigned int irq); | ||
623 | void mask_ht_irq(unsigned int irq); | ||
624 | void unmask_ht_irq(unsigned int irq); | ||
625 | |||
626 | /* The functions a driver should call */ | 618 | /* The functions a driver should call */ |
627 | int ht_create_irq(struct pci_dev *dev, int idx); | 619 | int ht_create_irq(struct pci_dev *dev, int idx); |
628 | void ht_destroy_irq(unsigned int irq); | 620 | void ht_destroy_irq(unsigned int irq); |
629 | |||
630 | /* The arch hook for getting things started */ | ||
631 | int arch_setup_ht_irq(unsigned int irq, struct pci_dev *dev); | ||
632 | #endif /* CONFIG_HT_IRQ */ | 621 | #endif /* CONFIG_HT_IRQ */ |
633 | 622 | ||
634 | extern void pci_block_user_cfg_access(struct pci_dev *dev); | 623 | extern void pci_block_user_cfg_access(struct pci_dev *dev); |