Skip to content

Commit 27a98fe

Browse files
committed
Merge branch 'acpi-x86'
Merge a revert of a problematic commit for 5.17-rc4. * acpi-x86: x86/PCI: revert "Ignore E820 reservations for bridge windows on newer systems"
2 parents cb1f65c + 3eb616b commit 27a98fe

File tree

1 file changed

+1
-22
lines changed

1 file changed

+1
-22
lines changed

arch/x86/kernel/resource.c

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// SPDX-License-Identifier: GPL-2.0
2-
#include <linux/dmi.h>
32
#include <linux/ioport.h>
43
#include <asm/e820/api.h>
54

@@ -24,31 +23,11 @@ static void resource_clip(struct resource *res, resource_size_t start,
2423
res->start = end + 1;
2524
}
2625

27-
/*
28-
* Some BIOS-es contain a bug where they add addresses which map to
29-
* system RAM in the PCI host bridge window returned by the ACPI _CRS
30-
* method, see commit 4dc2287c1805 ("x86: avoid E820 regions when
31-
* allocating address space"). To avoid this Linux by default excludes
32-
* E820 reservations when allocating addresses since 2010.
33-
* In 2019 some systems have shown-up with E820 reservations which cover
34-
* the entire _CRS returned PCI host bridge window, causing all attempts
35-
* to assign memory to PCI BARs to fail if Linux uses E820 reservations.
36-
*
37-
* Ideally Linux would fully stop using E820 reservations, but then
38-
* the old systems this was added for will regress.
39-
* Instead keep the old behavior for old systems, while ignoring the
40-
* E820 reservations for any systems from now on.
41-
*/
4226
static void remove_e820_regions(struct resource *avail)
4327
{
44-
int i, year = dmi_get_bios_year();
28+
int i;
4529
struct e820_entry *entry;
4630

47-
if (year >= 2018)
48-
return;
49-
50-
pr_info_once("PCI: Removing E820 reservations from host bridge windows\n");
51-
5231
for (i = 0; i < e820_table->nr_entries; i++) {
5332
entry = &e820_table->entries[i];
5433

0 commit comments

Comments
 (0)