Commit 7a4a76cc authored by Andi Kleen's avatar Andi Kleen Committed by Linus Torvalds
Browse files

[PATCH] x86_64: Fix off by one in acpi table mapping

And fix the test to include the size

Noticed by Vivek Goyal
Signed-off-by: default avatarAndi Kleen <>
Signed-off-by: default avatarLinus Torvalds <>
parent 7180d4fb
......@@ -108,7 +108,7 @@ char *__acpi_map_table(unsigned long phys_addr, unsigned long size)
if (!phys_addr || !size)
return NULL;
if (phys_addr < (end_pfn_map << PAGE_SHIFT))
if (phys_addr+size <= (end_pfn_map << PAGE_SHIFT) + PAGE_SIZE)
return __va(phys_addr);
return NULL;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment