Bug 22062 - hang in pci_bus_alloc_resource()
hang in pci_bus_alloc_resource()
Status: CLOSED CODE_FIX
Product: Drivers
Classification: Unclassified
Component: PCI
All Linux
: P1 normal
Assigned To: drivers_pci@kernel-bugs.osdl.org
:
: 22552 (view as bug list)
Depends on:
Blocks: 21782
  Show dependency treegraph
 
Reported: 2010-11-04 14:42 UTC by Bjorn Helgaas
Modified: 2010-11-19 13:41 UTC (History)
2 users (show)

See Also:
Kernel Version: 2.6.37-rc1
Tree: Mainline
Regression: Yes


Attachments

Description Bjorn Helgaas 2010-11-04 14:42:56 UTC
Borislav Petkov found a configuration where we hang when assigning resources to an option ROM, and bisected it to commit b126b4703afa.  Here's the relevant part of the dmesg log (this is with the commit reverted, and the point of hang marked):

ACPI: PCI Root Bridge [PCI0] (domain 0000 [bus 00-4f])
pci_root PNP0A08:00: host bridge window [io  0x03b0-0x03df]
pci_root PNP0A08:00: host bridge window [io  0x0d00-0x5fff]
pci_root PNP0A08:00: host bridge window [mem 0x000a0000-0x000bffff]
pci_root PNP0A08:00: host bridge window [mem 0xd0000000-0xd7ffffff]
pci_root PNP0A08:00: host bridge window [mem 0xc8000000-0xce0fffff]
pci_root PNP0A08:00: host bridge window [mem 0x000c0000-0x000cafff]
pci_root PNP0A08:00: host bridge window [mem 0xfed40000-0xfed45000]
pci_root PNP0A08:00: host bridge window [io  0x0000-0x03af]
pci_root PNP0A08:00: host bridge window [io  0x03e0-0x0cf7]

pci 0000:04:06.0: [xxxx:xxxx] type 0 class 0x000300
pci 0000:04:06.0: reg 10: [mem 0xd0000000-0xd7ffffff pref]
pci 0000:04:06.0: reg 14: [io  0x5000-0x50ff]
pci 0000:04:06.0: reg 18: [mem 0xce000000-0xce00ffff]
pci 0000:04:06.0: reg 30: [mem 0x00000000-0x0001ffff pref]
pci 0000:00:14.4: PCI bridge to [bus 04-04] (subtractive decode)
pci 0000:00:14.4:   bridge window [io  0x5000-0x5fff]
pci 0000:00:14.4:   bridge window [mem 0xce000000-0xce0fffff]
pci 0000:00:14.4:   bridge window [mem 0xd0000000-0xd7ffffff pref]
pci 0000:00:14.4:   bridge window [io  0x03b0-0x03df] (subtractive decode)
pci 0000:00:14.4:   bridge window [io  0x0d00-0x5fff] (subtractive decode)
pci 0000:00:14.4:   bridge window [mem 0x000a0000-0x000bffff] (subtractive decod
e)
pci 0000:00:14.4:   bridge window [mem 0xd0000000-0xd7ffffff] (subtractive decode)
pci 0000:00:14.4:   bridge window [mem 0xc8000000-0xce0fffff] (subtractive decode)
pci 0000:00:14.4:   bridge window [mem 0x000c0000-0x000cafff] (subtractive decode)
pci 0000:00:14.4:   bridge window [mem 0xfed40000-0xfed45000] (subtractive decode)
pci 0000:00:14.4:   bridge window [io  0x0000-0x03af] (subtractive decode)
pci 0000:00:14.4:   bridge window [io  0x03e0-0x0cf7] (subtractive decode)

** hangs here unless b126b4703afa is reverted **
pci 0000:04:06.0: BAR 6: assigned [mem 0xce0e0000-0xce0fffff pref]

pci 0000:00:14.4: PCI bridge to [bus 04-04]
pci 0000:00:14.4:   bridge window [io  0x5000-0x5fff]
pci 0000:00:14.4:   bridge window [mem 0xce000000-0xce0fffff]
pci 0000:00:14.4:   bridge window [mem 0xd0000000-0xd7ffffff pref]

pci_bus 0000:04: resource 0 [io  0x5000-0x5fff]
pci_bus 0000:04: resource 1 [mem 0xce000000-0xce0fffff]
pci_bus 0000:04: resource 2 [mem 0xd0000000-0xd7ffffff pref]
pci_bus 0000:04: resource 4 [io  0x03b0-0x03df]
pci_bus 0000:04: resource 5 [io  0x0d00-0x5fff]
pci_bus 0000:04: resource 6 [mem 0x000a0000-0x000bffff]
pci_bus 0000:04: resource 7 [mem 0xd0000000-0xd7ffffff]
pci_bus 0000:04: resource 8 [mem 0xc8000000-0xce0fffff]
pci_bus 0000:04: resource 9 [mem 0x000c0000-0x000cafff]
pci_bus 0000:04: resource 10 [mem 0xfed40000-0xfed45000]
pci_bus 0000:04: resource 11 [io  0x0000-0x03af]
pci_bus 0000:04: resource 12 [io  0x03e0-0x0cf7]
Comment 1 Florian Mickler 2010-11-19 13:39:11 UTC
*** Bug 22552 has been marked as a duplicate of this bug. ***
Comment 2 Florian Mickler 2010-11-19 13:41:06 UTC
fixed by:

commit 82e3e767c21fef2b1b38868e20eb4e470a1e38e3
Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
Date:   Wed Nov 10 10:26:07 2010 -0700

    PCI: fix pci_bus_alloc_resource() hang, prefer positive decode

Note You need to log in before you can comment on or make changes to this bug.