diff options
| author | Andy Lutomirski <luto@kernel.org> | 2017-12-12 10:56:44 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2017-12-23 15:13:00 -0500 |
| commit | 9f449772a3106bcdd4eb8fdeb281147b0e99fb30 (patch) | |
| tree | 42d799c62d5414452f2d9b1581cc01d3dbb9553c | |
| parent | c1961a4631daef4aeabee8e368b1b13e8f173c91 (diff) | |
x86/mm/64: Make a full PGD-entry size hole in the memory map
Shrink vmalloc space from 16384TiB to 12800TiB to enlarge the hole starting
at 0xff90000000000000 to be a full PGD entry.
A subsequent patch will use this hole for the pagetable isolation LDT
alias.
Signed-off-by: Andy Lutomirski <luto@kernel.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: David Laight <David.Laight@aculab.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Juergen Gross <jgross@suse.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: Kirill A. Shutemov <kirill@shutemov.name>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
| -rw-r--r-- | Documentation/x86/x86_64/mm.txt | 4 | ||||
| -rw-r--r-- | arch/x86/include/asm/pgtable_64_types.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/Documentation/x86/x86_64/mm.txt b/Documentation/x86/x86_64/mm.txt index 51101708a03a..496a1dbf139d 100644 --- a/Documentation/x86/x86_64/mm.txt +++ b/Documentation/x86/x86_64/mm.txt | |||
| @@ -29,8 +29,8 @@ Virtual memory map with 5 level page tables: | |||
| 29 | hole caused by [56:63] sign extension | 29 | hole caused by [56:63] sign extension |
| 30 | ff00000000000000 - ff0fffffffffffff (=52 bits) guard hole, reserved for hypervisor | 30 | ff00000000000000 - ff0fffffffffffff (=52 bits) guard hole, reserved for hypervisor |
| 31 | ff10000000000000 - ff8fffffffffffff (=55 bits) direct mapping of all phys. memory | 31 | ff10000000000000 - ff8fffffffffffff (=55 bits) direct mapping of all phys. memory |
| 32 | ff90000000000000 - ff91ffffffffffff (=49 bits) hole | 32 | ff90000000000000 - ff9fffffffffffff (=52 bits) hole |
| 33 | ff92000000000000 - ffd1ffffffffffff (=54 bits) vmalloc/ioremap space | 33 | ffa0000000000000 - ffd1ffffffffffff (=54 bits) vmalloc/ioremap space (12800 TB) |
| 34 | ffd2000000000000 - ffd3ffffffffffff (=49 bits) hole | 34 | ffd2000000000000 - ffd3ffffffffffff (=49 bits) hole |
| 35 | ffd4000000000000 - ffd5ffffffffffff (=49 bits) virtual memory map (512TB) | 35 | ffd4000000000000 - ffd5ffffffffffff (=49 bits) virtual memory map (512TB) |
| 36 | ... unused hole ... | 36 | ... unused hole ... |
diff --git a/arch/x86/include/asm/pgtable_64_types.h b/arch/x86/include/asm/pgtable_64_types.h index 3d27831bc58d..83e9489ae944 100644 --- a/arch/x86/include/asm/pgtable_64_types.h +++ b/arch/x86/include/asm/pgtable_64_types.h | |||
| @@ -79,8 +79,8 @@ typedef struct { pteval_t pte; } pte_t; | |||
| 79 | #define MAXMEM _AC(__AC(1, UL) << MAX_PHYSMEM_BITS, UL) | 79 | #define MAXMEM _AC(__AC(1, UL) << MAX_PHYSMEM_BITS, UL) |
| 80 | 80 | ||
| 81 | #ifdef CONFIG_X86_5LEVEL | 81 | #ifdef CONFIG_X86_5LEVEL |
| 82 | # define VMALLOC_SIZE_TB _AC(16384, UL) | 82 | # define VMALLOC_SIZE_TB _AC(12800, UL) |
| 83 | # define __VMALLOC_BASE _AC(0xff92000000000000, UL) | 83 | # define __VMALLOC_BASE _AC(0xffa0000000000000, UL) |
| 84 | # define __VMEMMAP_BASE _AC(0xffd4000000000000, UL) | 84 | # define __VMEMMAP_BASE _AC(0xffd4000000000000, UL) |
| 85 | #else | 85 | #else |
| 86 | # define VMALLOC_SIZE_TB _AC(32, UL) | 86 | # define VMALLOC_SIZE_TB _AC(32, UL) |
