diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-09-13 17:47:33 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-09-13 17:47:33 -0400 |
commit | 0cb60efd03ed82d02f44a14594714367e59e8abc (patch) | |
tree | 23d9443331673a75e296781031f652e3e87687cc | |
parent | c19e80808b34b3de5c20884f11f58c3b6988daff (diff) | |
parent | 395a125c6237802b19bf22b41017c99ff57f1024 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6:
PCI: re-add debug prints for unmodified BARs
PCI: fix pciehp_free_irq()
PCI Hotplug: fakephp: fix deadlock... again
PCI: Fix printk warnings in setup-bus.c
PCI: Fix printk warnings in probe.c
PCI/iommu: blacklist DMAR on Intel G31/G33 chipsets
-rw-r--r-- | drivers/pci/hotplug/fakephp.c | 6 | ||||
-rw-r--r-- | drivers/pci/hotplug/pciehp_hpc.c | 2 | ||||
-rw-r--r-- | drivers/pci/intel-iommu.c | 23 | ||||
-rw-r--r-- | drivers/pci/probe.c | 18 | ||||
-rw-r--r-- | drivers/pci/setup-bus.c | 6 |
5 files changed, 47 insertions, 8 deletions
diff --git a/drivers/pci/hotplug/fakephp.c b/drivers/pci/hotplug/fakephp.c index 40337a06c18a..146ca9cd1567 100644 --- a/drivers/pci/hotplug/fakephp.c +++ b/drivers/pci/hotplug/fakephp.c | |||
@@ -320,15 +320,15 @@ static int disable_slot(struct hotplug_slot *slot) | |||
320 | return -ENODEV; | 320 | return -ENODEV; |
321 | } | 321 | } |
322 | 322 | ||
323 | /* remove the device from the pci core */ | ||
324 | pci_remove_bus_device(dev); | ||
325 | |||
323 | /* queue work item to blow away this sysfs entry and other | 326 | /* queue work item to blow away this sysfs entry and other |
324 | * parts. | 327 | * parts. |
325 | */ | 328 | */ |
326 | INIT_WORK(&dslot->remove_work, remove_slot_worker); | 329 | INIT_WORK(&dslot->remove_work, remove_slot_worker); |
327 | queue_work(dummyphp_wq, &dslot->remove_work); | 330 | queue_work(dummyphp_wq, &dslot->remove_work); |
328 | 331 | ||
329 | /* blow away this sysfs entry and other parts. */ | ||
330 | remove_slot(dslot); | ||
331 | |||
332 | pci_dev_put(dev); | 332 | pci_dev_put(dev); |
333 | } | 333 | } |
334 | return 0; | 334 | return 0; |
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c index ab31f5ba665d..9d934ddee956 100644 --- a/drivers/pci/hotplug/pciehp_hpc.c +++ b/drivers/pci/hotplug/pciehp_hpc.c | |||
@@ -258,7 +258,7 @@ static int pcie_poll_cmd(struct controller *ctrl) | |||
258 | return 1; | 258 | return 1; |
259 | } | 259 | } |
260 | } | 260 | } |
261 | while (timeout > 1000) { | 261 | while (timeout > 0) { |
262 | msleep(10); | 262 | msleep(10); |
263 | timeout -= 10; | 263 | timeout -= 10; |
264 | if (!pciehp_readw(ctrl, SLOTSTATUS, &slot_status)) { | 264 | if (!pciehp_readw(ctrl, SLOTSTATUS, &slot_status)) { |
diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c index 8d0e60ac849c..c3edcdc08e72 100644 --- a/drivers/pci/intel-iommu.c +++ b/drivers/pci/intel-iommu.c | |||
@@ -2348,11 +2348,34 @@ static void __init iommu_exit_mempool(void) | |||
2348 | 2348 | ||
2349 | } | 2349 | } |
2350 | 2350 | ||
2351 | static int blacklist_iommu(const struct dmi_system_id *id) | ||
2352 | { | ||
2353 | printk(KERN_INFO "%s detected; disabling IOMMU\n", | ||
2354 | id->ident); | ||
2355 | dmar_disabled = 1; | ||
2356 | return 0; | ||
2357 | } | ||
2358 | |||
2359 | static struct dmi_system_id __initdata intel_iommu_dmi_table[] = { | ||
2360 | { /* Some DG33BU BIOS revisions advertised non-existent VT-d */ | ||
2361 | .callback = blacklist_iommu, | ||
2362 | .ident = "Intel DG33BU", | ||
2363 | { DMI_MATCH(DMI_BOARD_VENDOR, "Intel Corporation"), | ||
2364 | DMI_MATCH(DMI_BOARD_NAME, "DG33BU"), | ||
2365 | } | ||
2366 | }, | ||
2367 | { } | ||
2368 | }; | ||
2369 | |||
2370 | |||
2351 | void __init detect_intel_iommu(void) | 2371 | void __init detect_intel_iommu(void) |
2352 | { | 2372 | { |
2353 | if (swiotlb || no_iommu || iommu_detected || dmar_disabled) | 2373 | if (swiotlb || no_iommu || iommu_detected || dmar_disabled) |
2354 | return; | 2374 | return; |
2355 | if (early_dmar_detect()) { | 2375 | if (early_dmar_detect()) { |
2376 | dmi_check_system(intel_iommu_dmi_table); | ||
2377 | if (dmar_disabled) | ||
2378 | return; | ||
2356 | iommu_detected = 1; | 2379 | iommu_detected = 1; |
2357 | } | 2380 | } |
2358 | } | 2381 | } |
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index cce2f4cb1fbf..36698e57b97f 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c | |||
@@ -304,6 +304,9 @@ static int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, | |||
304 | } else { | 304 | } else { |
305 | res->start = l64; | 305 | res->start = l64; |
306 | res->end = l64 + sz64; | 306 | res->end = l64 + sz64; |
307 | printk(KERN_DEBUG "PCI: %s reg %x 64bit mmio: [%llx, %llx]\n", | ||
308 | pci_name(dev), pos, (unsigned long long)res->start, | ||
309 | (unsigned long long)res->end); | ||
307 | } | 310 | } |
308 | } else { | 311 | } else { |
309 | sz = pci_size(l, sz, mask); | 312 | sz = pci_size(l, sz, mask); |
@@ -313,6 +316,9 @@ static int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, | |||
313 | 316 | ||
314 | res->start = l; | 317 | res->start = l; |
315 | res->end = l + sz; | 318 | res->end = l + sz; |
319 | printk(KERN_DEBUG "PCI: %s reg %x %s: [%llx, %llx]\n", pci_name(dev), | ||
320 | pos, (res->flags & IORESOURCE_IO) ? "io port":"32bit mmio", | ||
321 | (unsigned long long)res->start, (unsigned long long)res->end); | ||
316 | } | 322 | } |
317 | 323 | ||
318 | out: | 324 | out: |
@@ -383,7 +389,9 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child) | |||
383 | res->start = base; | 389 | res->start = base; |
384 | if (!res->end) | 390 | if (!res->end) |
385 | res->end = limit + 0xfff; | 391 | res->end = limit + 0xfff; |
386 | printk(KERN_INFO "PCI: bridge %s io port: [%llx, %llx]\n", pci_name(dev), res->start, res->end); | 392 | printk(KERN_DEBUG "PCI: bridge %s io port: [%llx, %llx]\n", |
393 | pci_name(dev), (unsigned long long) res->start, | ||
394 | (unsigned long long) res->end); | ||
387 | } | 395 | } |
388 | 396 | ||
389 | res = child->resource[1]; | 397 | res = child->resource[1]; |
@@ -395,7 +403,9 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child) | |||
395 | res->flags = (mem_base_lo & PCI_MEMORY_RANGE_TYPE_MASK) | IORESOURCE_MEM; | 403 | res->flags = (mem_base_lo & PCI_MEMORY_RANGE_TYPE_MASK) | IORESOURCE_MEM; |
396 | res->start = base; | 404 | res->start = base; |
397 | res->end = limit + 0xfffff; | 405 | res->end = limit + 0xfffff; |
398 | printk(KERN_INFO "PCI: bridge %s 32bit mmio: [%llx, %llx]\n", pci_name(dev), res->start, res->end); | 406 | printk(KERN_DEBUG "PCI: bridge %s 32bit mmio: [%llx, %llx]\n", |
407 | pci_name(dev), (unsigned long long) res->start, | ||
408 | (unsigned long long) res->end); | ||
399 | } | 409 | } |
400 | 410 | ||
401 | res = child->resource[2]; | 411 | res = child->resource[2]; |
@@ -431,7 +441,9 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child) | |||
431 | res->flags = (mem_base_lo & PCI_MEMORY_RANGE_TYPE_MASK) | IORESOURCE_MEM | IORESOURCE_PREFETCH; | 441 | res->flags = (mem_base_lo & PCI_MEMORY_RANGE_TYPE_MASK) | IORESOURCE_MEM | IORESOURCE_PREFETCH; |
432 | res->start = base; | 442 | res->start = base; |
433 | res->end = limit + 0xfffff; | 443 | res->end = limit + 0xfffff; |
434 | printk(KERN_INFO "PCI: bridge %s %sbit mmio pref: [%llx, %llx]\n", pci_name(dev), (res->flags & PCI_PREF_RANGE_TYPE_64)?"64":"32",res->start, res->end); | 444 | printk(KERN_DEBUG "PCI: bridge %s %sbit mmio pref: [%llx, %llx]\n", |
445 | pci_name(dev), (res->flags & PCI_PREF_RANGE_TYPE_64) ? "64" : "32", | ||
446 | (unsigned long long) res->start, (unsigned long long) res->end); | ||
435 | } | 447 | } |
436 | } | 448 | } |
437 | 449 | ||
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c index 1aad599816f7..3abbfad9ddab 100644 --- a/drivers/pci/setup-bus.c +++ b/drivers/pci/setup-bus.c | |||
@@ -540,7 +540,11 @@ static void pci_bus_dump_res(struct pci_bus *bus) | |||
540 | if (!res) | 540 | if (!res) |
541 | continue; | 541 | continue; |
542 | 542 | ||
543 | printk(KERN_INFO "bus: %02x index %x %s: [%llx, %llx]\n", bus->number, i, (res->flags & IORESOURCE_IO)? "io port":"mmio", res->start, res->end); | 543 | printk(KERN_INFO "bus: %02x index %x %s: [%llx, %llx]\n", |
544 | bus->number, i, | ||
545 | (res->flags & IORESOURCE_IO) ? "io port" : "mmio", | ||
546 | (unsigned long long) res->start, | ||
547 | (unsigned long long) res->end); | ||
544 | } | 548 | } |
545 | } | 549 | } |
546 | 550 | ||