pgalloc.h (762f99f4f3cb41a775b5157dd761217beba65873) | pgalloc.h (ea4654e0885348f0faa47f6d7b44a08d75ad16e9) |
---|---|
1/* SPDX-License-Identifier: GPL-2.0 */ 2#ifndef _ASM_X86_PGALLOC_H 3#define _ASM_X86_PGALLOC_H 4 5#include <linux/threads.h> 6#include <linux/mm.h> /* for struct page */ 7#include <linux/pagemap.h> 8 --- 20 unchanged lines hidden (view full) --- 29static inline void paravirt_release_p4d(unsigned long pfn) {} 30#endif 31 32/* 33 * Flags to use when allocating a user page table page. 34 */ 35extern gfp_t __userpte_alloc_gfp; 36 | 1/* SPDX-License-Identifier: GPL-2.0 */ 2#ifndef _ASM_X86_PGALLOC_H 3#define _ASM_X86_PGALLOC_H 4 5#include <linux/threads.h> 6#include <linux/mm.h> /* for struct page */ 7#include <linux/pagemap.h> 8 --- 20 unchanged lines hidden (view full) --- 29static inline void paravirt_release_p4d(unsigned long pfn) {} 30#endif 31 32/* 33 * Flags to use when allocating a user page table page. 34 */ 35extern gfp_t __userpte_alloc_gfp; 36 |
37#ifdef CONFIG_PAGE_TABLE_ISOLATION | 37#ifdef CONFIG_MITIGATION_PAGE_TABLE_ISOLATION |
38/* 39 * Instead of one PGD, we acquire two PGDs. Being order-1, it is 40 * both 8k in size and 8k-aligned. That lets us just flip bit 12 41 * in a pointer to swap between the two 4k halves. 42 */ 43#define PGD_ALLOCATION_ORDER 1 44#else 45#define PGD_ALLOCATION_ORDER 0 --- 136 unchanged lines hidden --- | 38/* 39 * Instead of one PGD, we acquire two PGDs. Being order-1, it is 40 * both 8k in size and 8k-aligned. That lets us just flip bit 12 41 * in a pointer to swap between the two 4k halves. 42 */ 43#define PGD_ALLOCATION_ORDER 1 44#else 45#define PGD_ALLOCATION_ORDER 0 --- 136 unchanged lines hidden --- |