diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-07-11 15:22:18 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-11 15:22:18 -0400 |
commit | 6c82a000a29b93541b5b7db597a083c069755cc9 (patch) | |
tree | b9e49724f56b47e4b3d0bd6c6fa3be88dac3a9e6 /arch/x86/pci | |
parent | 5b4d2386c23e5de553fce002892c7691a989b350 (diff) | |
parent | 39415a440ecceb0a5bd3c23686f18f83bb8368c6 (diff) |
Merge branch 'x86/generalize-visws' into x86/core
Diffstat (limited to 'arch/x86/pci')
-rw-r--r-- | arch/x86/pci/Makefile | 4 | ||||
-rw-r--r-- | arch/x86/pci/legacy.c | 5 | ||||
-rw-r--r-- | arch/x86/pci/numa.c | 10 | ||||
-rw-r--r-- | arch/x86/pci/pci.h | 1 | ||||
-rw-r--r-- | arch/x86/pci/visws.c | 19 |
5 files changed, 22 insertions, 17 deletions
diff --git a/arch/x86/pci/Makefile b/arch/x86/pci/Makefile index 99d9f095e4d4..e515e8db842a 100644 --- a/arch/x86/pci/Makefile +++ b/arch/x86/pci/Makefile | |||
@@ -9,9 +9,7 @@ pci-y := fixup.o | |||
9 | pci-$(CONFIG_ACPI) += acpi.o | 9 | pci-$(CONFIG_ACPI) += acpi.o |
10 | pci-y += legacy.o irq.o | 10 | pci-y += legacy.o irq.o |
11 | 11 | ||
12 | # Careful: VISWS overrule the pci-y above. The colons are | 12 | pci-$(CONFIG_X86_VISWS) += visws.o |
13 | # therefor correct. This needs a proper fix by distangling the code. | ||
14 | pci-$(CONFIG_X86_VISWS) := visws.o fixup.o | ||
15 | 13 | ||
16 | pci-$(CONFIG_X86_NUMAQ) += numa.o | 14 | pci-$(CONFIG_X86_NUMAQ) += numa.o |
17 | 15 | ||
diff --git a/arch/x86/pci/legacy.c b/arch/x86/pci/legacy.c index 3c1d795cbbe9..132876cc6fca 100644 --- a/arch/x86/pci/legacy.c +++ b/arch/x86/pci/legacy.c | |||
@@ -62,6 +62,11 @@ int __init pci_subsys_init(void) | |||
62 | #endif | 62 | #endif |
63 | pci_legacy_init(); | 63 | pci_legacy_init(); |
64 | pcibios_irq_init(); | 64 | pcibios_irq_init(); |
65 | #ifdef CONFIG_X86_NUMAQ | ||
66 | pci_numa_init(); | ||
67 | #endif | ||
65 | pcibios_init(); | 68 | pcibios_init(); |
69 | |||
70 | return 0; | ||
66 | } | 71 | } |
67 | subsys_initcall(pci_subsys_init); | 72 | subsys_initcall(pci_subsys_init); |
diff --git a/arch/x86/pci/numa.c b/arch/x86/pci/numa.c index e1620dc8649a..8b5ca1966731 100644 --- a/arch/x86/pci/numa.c +++ b/arch/x86/pci/numa.c | |||
@@ -151,7 +151,7 @@ static void __devinit pci_fixup_i450nx(struct pci_dev *d) | |||
151 | } | 151 | } |
152 | DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82451NX, pci_fixup_i450nx); | 152 | DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82451NX, pci_fixup_i450nx); |
153 | 153 | ||
154 | static int __init pci_numa_init(void) | 154 | int __init pci_numa_init(void) |
155 | { | 155 | { |
156 | int quad; | 156 | int quad; |
157 | 157 | ||
@@ -176,11 +176,3 @@ static int __init pci_numa_init(void) | |||
176 | } | 176 | } |
177 | return 0; | 177 | return 0; |
178 | } | 178 | } |
179 | |||
180 | static __init int pci_subsys_init(void) | ||
181 | { | ||
182 | pci_numa_init(); | ||
183 | pcibios_irq_init(); | ||
184 | pcibios_init(); | ||
185 | } | ||
186 | subsys_initcall(pci_subsys_init); | ||
diff --git a/arch/x86/pci/pci.h b/arch/x86/pci/pci.h index 58241748470f..b2270a55b0cf 100644 --- a/arch/x86/pci/pci.h +++ b/arch/x86/pci/pci.h | |||
@@ -107,6 +107,7 @@ extern void __init dmi_check_skip_isa_align(void); | |||
107 | /* some common used subsys_initcalls */ | 107 | /* some common used subsys_initcalls */ |
108 | extern int __init pci_acpi_init(void); | 108 | extern int __init pci_acpi_init(void); |
109 | extern int __init pcibios_irq_init(void); | 109 | extern int __init pcibios_irq_init(void); |
110 | extern int __init pci_numa_init(void); | ||
110 | extern int __init pcibios_init(void); | 111 | extern int __init pcibios_init(void); |
111 | 112 | ||
112 | /* pci-mmconfig.c */ | 113 | /* pci-mmconfig.c */ |
diff --git a/arch/x86/pci/visws.c b/arch/x86/pci/visws.c index 16e52063ecb3..1a7bed492bb1 100644 --- a/arch/x86/pci/visws.c +++ b/arch/x86/pci/visws.c | |||
@@ -8,18 +8,19 @@ | |||
8 | #include <linux/pci.h> | 8 | #include <linux/pci.h> |
9 | #include <linux/init.h> | 9 | #include <linux/init.h> |
10 | 10 | ||
11 | #include "cobalt.h" | 11 | #include <asm/setup.h> |
12 | #include "lithium.h" | 12 | #include <asm/visws/cobalt.h> |
13 | #include <asm/visws/lithium.h> | ||
13 | 14 | ||
14 | #include "pci.h" | 15 | #include "pci.h" |
15 | 16 | ||
16 | static int pci_visws_enable_irq(struct pci_dev *dev) { return 0; } | 17 | static int pci_visws_enable_irq(struct pci_dev *dev) { return 0; } |
17 | static void pci_visws_disable_irq(struct pci_dev *dev) { } | 18 | static void pci_visws_disable_irq(struct pci_dev *dev) { } |
18 | 19 | ||
19 | int (*pcibios_enable_irq)(struct pci_dev *dev) = &pci_visws_enable_irq; | 20 | /* int (*pcibios_enable_irq)(struct pci_dev *dev) = &pci_visws_enable_irq; */ |
20 | void (*pcibios_disable_irq)(struct pci_dev *dev) = &pci_visws_disable_irq; | 21 | /* void (*pcibios_disable_irq)(struct pci_dev *dev) = &pci_visws_disable_irq; */ |
21 | 22 | ||
22 | void __init pcibios_penalize_isa_irq(int irq, int active) {} | 23 | /* void __init pcibios_penalize_isa_irq(int irq, int active) {} */ |
23 | 24 | ||
24 | 25 | ||
25 | unsigned int pci_bus0, pci_bus1; | 26 | unsigned int pci_bus0, pci_bus1; |
@@ -107,7 +108,15 @@ static int __init pci_visws_init(void) | |||
107 | 108 | ||
108 | static __init int pci_subsys_init(void) | 109 | static __init int pci_subsys_init(void) |
109 | { | 110 | { |
111 | if (!is_visws_box()) | ||
112 | return -1; | ||
113 | |||
114 | pcibios_enable_irq = &pci_visws_enable_irq; | ||
115 | pcibios_disable_irq = &pci_visws_disable_irq; | ||
116 | |||
110 | pci_visws_init(); | 117 | pci_visws_init(); |
111 | pcibios_init(); | 118 | pcibios_init(); |
119 | |||
120 | return 0; | ||
112 | } | 121 | } |
113 | subsys_initcall(pci_subsys_init); | 122 | subsys_initcall(pci_subsys_init); |