diff options
author | Andi Kleen <ak@suse.de> | 2006-10-05 12:47:22 -0400 |
---|---|---|
committer | Andi Kleen <andi@basil.nowhere.org> | 2006-10-05 12:47:22 -0400 |
commit | f015c6c4d733f68cbc1c5d231bb158abaa5c9606 (patch) | |
tree | 9ffa7a284f8265723bf46cb19557443bf1e68ea2 /arch | |
parent | 70d666d6ae9724c0a08434c20f8830c90a635bd3 (diff) |
[PATCH] i386: Fix PCI BIOS config space access
Got broken by a earlier change.
Also add a printk when no pci config method could be found.
Cc: gregkh@suse.de
Signed-off-by: Andi Kleen <ak@suse.de>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/i386/pci/direct.c | 2 | ||||
-rw-r--r-- | arch/i386/pci/init.c | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/arch/i386/pci/direct.c b/arch/i386/pci/direct.c index 5acf0b4743cf..431c9a51b157 100644 --- a/arch/i386/pci/direct.c +++ b/arch/i386/pci/direct.c | |||
@@ -256,6 +256,8 @@ static int __init pci_check_type2(void) | |||
256 | 256 | ||
257 | void __init pci_direct_init(int type) | 257 | void __init pci_direct_init(int type) |
258 | { | 258 | { |
259 | if (type == 0) | ||
260 | return; | ||
259 | printk(KERN_INFO "PCI: Using configuration type %d\n", type); | 261 | printk(KERN_INFO "PCI: Using configuration type %d\n", type); |
260 | if (type == 1) | 262 | if (type == 1) |
261 | raw_pci_ops = &pci_direct_conf1; | 263 | raw_pci_ops = &pci_direct_conf1; |
diff --git a/arch/i386/pci/init.c b/arch/i386/pci/init.c index d028e1b05c36..b21b6da8ab1d 100644 --- a/arch/i386/pci/init.c +++ b/arch/i386/pci/init.c | |||
@@ -28,6 +28,10 @@ static __init int pci_access_init(void) | |||
28 | #ifdef CONFIG_PCI_DIRECT | 28 | #ifdef CONFIG_PCI_DIRECT |
29 | pci_direct_init(type); | 29 | pci_direct_init(type); |
30 | #endif | 30 | #endif |
31 | if (!raw_pci_ops) | ||
32 | printk(KERN_ERR | ||
33 | "PCI: Fatal: No config space access function found\n"); | ||
34 | |||
31 | return 0; | 35 | return 0; |
32 | } | 36 | } |
33 | arch_initcall(pci_access_init); | 37 | arch_initcall(pci_access_init); |