Skip to content

Commit 84b06ca

Browse files
Aleksey Makarovrafaeljw
authored andcommitted
ACPI / tables: move arch-specific symbol to asm/acpi.h
The constant that defines max phys address where the new upgraded ACPI table should be allocated is arch-specific. Move it to <asm/acpi.h> Signed-off-by: Aleksey Makarov <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent da3d3f9 commit 84b06ca

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

arch/x86/include/asm/acpi.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,4 +170,6 @@ static inline pgprot_t arch_apei_get_mem_attribute(phys_addr_t addr)
170170
}
171171
#endif
172172

173+
#define ACPI_TABLE_UPGRADE_MAX_PHYS (max_low_pfn_mapped << PAGE_SHIFT)
174+
173175
#endif /* _ASM_X86_ACPI_H */

drivers/acpi/tables.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
#include <linux/earlycpio.h>
3636
#include <linux/memblock.h>
3737
#include <linux/initrd.h>
38+
#include <linux/acpi.h>
3839
#include "internal.h"
3940

4041
#ifdef CONFIG_ACPI_CUSTOM_DSDT
@@ -543,7 +544,7 @@ void __init acpi_table_upgrade(void)
543544
return;
544545

545546
acpi_tables_addr =
546-
memblock_find_in_range(0, max_low_pfn_mapped << PAGE_SHIFT,
547+
memblock_find_in_range(0, ACPI_TABLE_UPGRADE_MAX_PHYS,
547548
all_tables_size, PAGE_SIZE);
548549
if (!acpi_tables_addr) {
549550
WARN_ON(1);

0 commit comments

Comments
 (0)