diff options
author | Kirill A. Shutemov <kirill.shutemov@linux.intel.com> | 2018-05-18 12:35:24 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2018-05-19 11:56:57 +0200 |
commit | ed7588d5dc6f5e7202fb9bbeb14d94706ba225d7 (patch) | |
tree | 359a4e804f7d677e83b0283975bb1bc39ae3ca56 /arch/x86/kernel/head64.c | |
parent | x86/mm: Unify pgtable_l5_enabled usage in early boot code (diff) | |
download | linux-ed7588d5dc6f5e7202fb9bbeb14d94706ba225d7.tar.xz linux-ed7588d5dc6f5e7202fb9bbeb14d94706ba225d7.zip |
x86/mm: Stop pretending pgtable_l5_enabled is a variable
pgtable_l5_enabled is defined using cpu_feature_enabled() but we refer
to it as a variable. This is misleading.
Make pgtable_l5_enabled() a function.
We cannot literally define it as a function due to circular dependencies
between header files. Function-alike macros is close enough.
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Hugh Dickins <hughd@google.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20180518103528.59260-4-kirill.shutemov@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/kernel/head64.c')
-rw-r--r-- | arch/x86/kernel/head64.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c index 494fea1dbd6e..8d372d1c266d 100644 --- a/arch/x86/kernel/head64.c +++ b/arch/x86/kernel/head64.c @@ -279,7 +279,7 @@ again: * critical -- __PAGE_OFFSET would point us back into the dynamic * range and we might end up looping forever... */ - if (!pgtable_l5_enabled) + if (!pgtable_l5_enabled()) p4d_p = pgd_p; else if (pgd) p4d_p = (p4dval_t *)((pgd & PTE_PFN_MASK) + __START_KERNEL_map - phys_base); |