diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2015-06-09 18:31:38 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-07-10 12:49:35 -0400 |
commit | 9dc6d43528e147f9d243df8da6ccf54c7ee244de (patch) | |
tree | 14a82982678609514511cc4753080229cd26bd78 | |
parent | f6707abd213039644950edb760d5c46503f065fa (diff) |
x86/PCI: Use host bridge _CRS info on systems with >32 bit addressing
commit 3d9fecf6bfb8b12bc2f9a4c7109895a2a2bb9436 upstream.
We enable _CRS on all systems from 2008 and later. On older systems, we
ignore _CRS and assume the whole physical address space (excluding RAM and
other devices) is available for PCI devices, but on systems that support
physical address spaces larger than 4GB, it's doubtful that the area above
4GB is really available for PCI.
After d56dbf5bab8c ("PCI: Allocate 64-bit BARs above 4G when possible"), we
try to use that space above 4GB *first*, so we're more likely to put a
device there.
On Juan's Toshiba Satellite Pro U200, BIOS left the graphics, sound, 1394,
and card reader devices unassigned (but only after Windows had been
booted). Only the sound device had a 64-bit BAR, so it was the only device
placed above 4GB, and hence the only device that didn't work.
Keep _CRS enabled even on pre-2008 systems if they support physical address
space larger than 4GB.
Fixes: d56dbf5bab8c ("PCI: Allocate 64-bit BARs above 4G when possible")
Reported-and-tested-by: Juan Dayer <jdayer@outlook.com>
Reported-and-tested-by: Alan Horsfield <alan@hazelgarth.co.uk>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=99221
Link: https://bugzilla.opensuse.org/show_bug.cgi?id=907092
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | arch/x86/pci/acpi.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/x86/pci/acpi.c b/arch/x86/pci/acpi.c index 14a63ed6fe09..546f18ad09f0 100644 --- a/arch/x86/pci/acpi.c +++ b/arch/x86/pci/acpi.c | |||
@@ -121,8 +121,10 @@ void __init pci_acpi_crs_quirks(void) | |||
121 | { | 121 | { |
122 | int year; | 122 | int year; |
123 | 123 | ||
124 | if (dmi_get_date(DMI_BIOS_DATE, &year, NULL, NULL) && year < 2008) | 124 | if (dmi_get_date(DMI_BIOS_DATE, &year, NULL, NULL) && year < 2008) { |
125 | pci_use_crs = false; | 125 | if (iomem_resource.end <= 0xffffffff) |
126 | pci_use_crs = false; | ||
127 | } | ||
126 | 128 | ||
127 | dmi_check_system(pci_crs_quirks); | 129 | dmi_check_system(pci_crs_quirks); |
128 | 130 | ||