aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/pci_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sparc64/kernel/pci_common.c')
-rw-r--r--arch/sparc64/kernel/pci_common.c29
1 files changed, 10 insertions, 19 deletions
diff --git a/arch/sparc64/kernel/pci_common.c b/arch/sparc64/kernel/pci_common.c
index 7a59cc72c844..827ae30aa497 100644
--- a/arch/sparc64/kernel/pci_common.c
+++ b/arch/sparc64/kernel/pci_common.c
@@ -330,19 +330,6 @@ __init get_device_resource(struct linux_prom_pci_registers *ap,
330 return res; 330 return res;
331} 331}
332 332
333static int __init pdev_resource_collisions_expected(struct pci_dev *pdev)
334{
335 if (pdev->vendor != PCI_VENDOR_ID_SUN)
336 return 0;
337
338 if (pdev->device == PCI_DEVICE_ID_SUN_RIO_EBUS ||
339 pdev->device == PCI_DEVICE_ID_SUN_RIO_1394 ||
340 pdev->device == PCI_DEVICE_ID_SUN_RIO_USB)
341 return 1;
342
343 return 0;
344}
345
346static void __init pdev_record_assignments(struct pci_pbm_info *pbm, 333static void __init pdev_record_assignments(struct pci_pbm_info *pbm,
347 struct pci_dev *pdev) 334 struct pci_dev *pdev)
348{ 335{
@@ -400,19 +387,23 @@ static void __init pdev_record_assignments(struct pci_pbm_info *pbm,
400 pbm->parent->resource_adjust(pdev, res, root); 387 pbm->parent->resource_adjust(pdev, res, root);
401 388
402 if (request_resource(root, res) < 0) { 389 if (request_resource(root, res) < 0) {
390 int rnum;
391
403 /* OK, there is some conflict. But this is fine 392 /* OK, there is some conflict. But this is fine
404 * since we'll reassign it in the fixup pass. 393 * since we'll reassign it in the fixup pass.
405 * 394 *
406 * We notify the user that OBP made an error if it 395 * Do not print the warning for ROM resources
407 * is a case we don't expect. 396 * as such a conflict is quite common and
397 * harmless as the ROM bar is disabled.
408 */ 398 */
409 if (!pdev_resource_collisions_expected(pdev)) { 399 rnum = (res - &pdev->resource[0]);
410 printk(KERN_ERR "PCI: Address space collision on region %ld " 400 if (rnum != PCI_ROM_RESOURCE)
401 printk(KERN_ERR "PCI: Resource collision, "
402 "region %d "
411 "[%016lx:%016lx] of device %s\n", 403 "[%016lx:%016lx] of device %s\n",
412 (res - &pdev->resource[0]), 404 rnum,
413 res->start, res->end, 405 res->start, res->end,
414 pci_name(pdev)); 406 pci_name(pdev));
415 }
416 } 407 }
417 } 408 }
418} 409}