aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/pci
diff options
context:
space:
mode:
authorYinghai Lu <yinghai@kernel.org>2010-02-10 04:20:12 -0500
committerH. Peter Anvin <hpa@zytor.com>2010-02-10 20:47:17 -0500
commit284f933d45a1e60404328440910bc2651c0fb51d (patch)
tree50bf34ca469aa4d56c102a5c5b69edf0ba85c261 /arch/x86/pci
parent9ad3f2c7c69659c343843393944d739fec1f2e73 (diff)
x86/pci: Enable pci root res read out for 32bit too
Should be good for 32bit too. -v3: cast res->start -v4: according to Linus, to use %pR instead of cast Signed-off-by: Yinghai Lu <yinghai@kernel.org> LKML-Reference: <1265793639-15071-9-git-send-email-yinghai@kernel.org> Acked-by: Jesse Barnes <jbarnes@virtuousgeek.org> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/pci')
-rw-r--r--arch/x86/pci/Makefile3
-rw-r--r--arch/x86/pci/amd_bus.c18
-rw-r--r--arch/x86/pci/bus_numa.h4
-rw-r--r--arch/x86/pci/i386.c4
4 files changed, 5 insertions, 24 deletions
diff --git a/arch/x86/pci/Makefile b/arch/x86/pci/Makefile
index 39fba37f702f..0b7d3e9593e1 100644
--- a/arch/x86/pci/Makefile
+++ b/arch/x86/pci/Makefile
@@ -14,8 +14,7 @@ obj-$(CONFIG_X86_VISWS) += visws.o
14obj-$(CONFIG_X86_NUMAQ) += numaq_32.o 14obj-$(CONFIG_X86_NUMAQ) += numaq_32.o
15 15
16obj-y += common.o early.o 16obj-y += common.o early.o
17obj-y += amd_bus.o 17obj-y += amd_bus.o bus_numa.o
18obj-$(CONFIG_X86_64) += bus_numa.o
19 18
20ifeq ($(CONFIG_PCI_DEBUG),y) 19ifeq ($(CONFIG_PCI_DEBUG),y)
21EXTRA_CFLAGS += -DDEBUG 20EXTRA_CFLAGS += -DDEBUG
diff --git a/arch/x86/pci/amd_bus.c b/arch/x86/pci/amd_bus.c
index f7e13b63154e..ea6072fcf3d4 100644
--- a/arch/x86/pci/amd_bus.c
+++ b/arch/x86/pci/amd_bus.c
@@ -6,9 +6,7 @@
6 6
7#include <asm/pci_x86.h> 7#include <asm/pci_x86.h>
8 8
9#ifdef CONFIG_X86_64
10#include <asm/pci-direct.h> 9#include <asm/pci-direct.h>
11#endif
12 10
13#include "bus_numa.h" 11#include "bus_numa.h"
14 12
@@ -17,8 +15,6 @@
17 * also get peer root bus resource for io,mmio 15 * also get peer root bus resource for io,mmio
18 */ 16 */
19 17
20#ifdef CONFIG_X86_64
21
22struct pci_hostbridge_probe { 18struct pci_hostbridge_probe {
23 u32 bus; 19 u32 bus;
24 u32 slot; 20 u32 slot;
@@ -339,24 +335,14 @@ static int __init early_fill_mp_bus_info(void)
339 info->bus_min, info->bus_max, info->node, info->link); 335 info->bus_min, info->bus_max, info->node, info->link);
340 for (j = 0; j < res_num; j++) { 336 for (j = 0; j < res_num; j++) {
341 res = &info->res[j]; 337 res = &info->res[j];
342 printk(KERN_DEBUG "bus: %02x index %x %s: [%llx, %llx]\n", 338 printk(KERN_DEBUG "bus: %02x index %x %pR\n",
343 busnum, j, 339 busnum, j, res);
344 (res->flags & IORESOURCE_IO)?"io port":"mmio",
345 res->start, res->end);
346 } 340 }
347 } 341 }
348 342
349 return 0; 343 return 0;
350} 344}
351 345
352#else /* !CONFIG_X86_64 */
353
354static int __init early_fill_mp_bus_info(void) { return 0; }
355
356#endif /* !CONFIG_X86_64 */
357
358/* common 32/64 bit code */
359
360#define ENABLE_CF8_EXT_CFG (1ULL << 46) 346#define ENABLE_CF8_EXT_CFG (1ULL << 46)
361 347
362static void enable_pci_io_ecs(void *unused) 348static void enable_pci_io_ecs(void *unused)
diff --git a/arch/x86/pci/bus_numa.h b/arch/x86/pci/bus_numa.h
index f63e80294f22..08d8e1576240 100644
--- a/arch/x86/pci/bus_numa.h
+++ b/arch/x86/pci/bus_numa.h
@@ -1,5 +1,5 @@
1#ifdef CONFIG_X86_64 1#ifndef __BUS_NUMA_H
2 2#define __BUS_NUMA_H
3/* 3/*
4 * sub bus (transparent) will use entres from 3 to store extra from 4 * sub bus (transparent) will use entres from 3 to store extra from
5 * root, so need to make sure we have enough slot there, Should we 5 * root, so need to make sure we have enough slot there, Should we
diff --git a/arch/x86/pci/i386.c b/arch/x86/pci/i386.c
index 5dc9e8c63fcd..f4e8481970bd 100644
--- a/arch/x86/pci/i386.c
+++ b/arch/x86/pci/i386.c
@@ -257,10 +257,6 @@ void __init pcibios_resource_survey(void)
257 */ 257 */
258fs_initcall(pcibios_assign_resources); 258fs_initcall(pcibios_assign_resources);
259 259
260void __weak x86_pci_root_bus_res_quirks(struct pci_bus *b)
261{
262}
263
264/* 260/*
265 * If we set up a device for bus mastering, we need to check the latency 261 * If we set up a device for bus mastering, we need to check the latency
266 * timer as certain crappy BIOSes forget to set it properly. 262 * timer as certain crappy BIOSes forget to set it properly.