diff options
-rw-r--r-- | arch/x86/pci/acpi.c | 26 |
1 files changed, 18 insertions, 8 deletions
diff --git a/arch/x86/pci/acpi.c b/arch/x86/pci/acpi.c index 68b89dc7d761..54db5a04b5e1 100644 --- a/arch/x86/pci/acpi.c +++ b/arch/x86/pci/acpi.c | |||
@@ -92,11 +92,12 @@ setup_resource(struct acpi_resource *acpi_res, void *data) | |||
92 | start = addr.minimum + addr.translation_offset; | 92 | start = addr.minimum + addr.translation_offset; |
93 | end = start + addr.address_length - 1; | 93 | end = start + addr.address_length - 1; |
94 | if (info->res_num >= max_root_bus_resources) { | 94 | if (info->res_num >= max_root_bus_resources) { |
95 | printk(KERN_WARNING "PCI: Failed to allocate 0x%lx-0x%lx " | 95 | if (pci_probe & PCI_USE__CRS) |
96 | "from %s for %s due to _CRS returning more than " | 96 | printk(KERN_WARNING "PCI: Failed to allocate " |
97 | "%d resource descriptors\n", (unsigned long) start, | 97 | "0x%lx-0x%lx from %s for %s due to _CRS " |
98 | (unsigned long) end, root->name, info->name, | 98 | "returning more than %d resource descriptors\n", |
99 | max_root_bus_resources); | 99 | (unsigned long) start, (unsigned long) end, |
100 | root->name, info->name, max_root_bus_resources); | ||
100 | return AE_OK; | 101 | return AE_OK; |
101 | } | 102 | } |
102 | 103 | ||
@@ -107,6 +108,12 @@ setup_resource(struct acpi_resource *acpi_res, void *data) | |||
107 | res->end = end; | 108 | res->end = end; |
108 | res->child = NULL; | 109 | res->child = NULL; |
109 | 110 | ||
111 | if (!(pci_probe & PCI_USE__CRS)) { | ||
112 | dev_printk(KERN_DEBUG, &info->bridge->dev, | ||
113 | "host bridge window %pR (ignored)\n", res); | ||
114 | return AE_OK; | ||
115 | } | ||
116 | |||
110 | if (insert_resource(root, res)) { | 117 | if (insert_resource(root, res)) { |
111 | dev_err(&info->bridge->dev, | 118 | dev_err(&info->bridge->dev, |
112 | "can't allocate host bridge window %pR\n", res); | 119 | "can't allocate host bridge window %pR\n", res); |
@@ -132,6 +139,11 @@ get_current_resources(struct acpi_device *device, int busnum, | |||
132 | struct pci_root_info info; | 139 | struct pci_root_info info; |
133 | size_t size; | 140 | size_t size; |
134 | 141 | ||
142 | if (!(pci_probe & PCI_USE__CRS)) | ||
143 | dev_info(&device->dev, | ||
144 | "ignoring host bridge windows from ACPI; " | ||
145 | "boot with \"pci=use_crs\" to use them\n"); | ||
146 | |||
135 | info.bridge = device; | 147 | info.bridge = device; |
136 | info.bus = bus; | 148 | info.bus = bus; |
137 | info.res_num = 0; | 149 | info.res_num = 0; |
@@ -220,9 +232,7 @@ struct pci_bus * __devinit pci_acpi_scan_root(struct acpi_device *device, int do | |||
220 | } else { | 232 | } else { |
221 | bus = pci_create_bus(NULL, busnum, &pci_root_ops, sd); | 233 | bus = pci_create_bus(NULL, busnum, &pci_root_ops, sd); |
222 | if (bus) { | 234 | if (bus) { |
223 | if (pci_probe & PCI_USE__CRS) | 235 | get_current_resources(device, busnum, domain, bus); |
224 | get_current_resources(device, busnum, domain, | ||
225 | bus); | ||
226 | bus->subordinate = pci_scan_child_bus(bus); | 236 | bus->subordinate = pci_scan_child_bus(bus); |
227 | } | 237 | } |
228 | } | 238 | } |