x86_64: all intermediate page table entries now have PTE_USR set
this allows user-accessible page mappings to be created. for kernel memory mappings, PTE_USR will only be cleared on the lowest-level table entry.
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
#define C_2GiB (2 * C_1GiB)
|
#define C_2GiB (2 * C_1GiB)
|
||||||
|
|
||||||
#define BAD_INDEX ((unsigned int)-1)
|
#define BAD_INDEX ((unsigned int)-1)
|
||||||
#define PTR_TO_ENTRY(x) (((x) & ~VM_PAGE_MASK) | PTE_PRESENT | PTE_RW)
|
#define PTR_TO_ENTRY(x) (((x) & ~VM_PAGE_MASK) | PTE_PRESENT | PTE_RW | PTE_USR)
|
||||||
#define ENTRY_TO_PTR(x) ((x) & ~VM_PAGE_MASK)
|
#define ENTRY_TO_PTR(x) ((x) & ~VM_PAGE_MASK)
|
||||||
|
|
||||||
#define PFN(x) ((x) >> VM_PAGE_SHIFT)
|
#define PFN(x) ((x) >> VM_PAGE_SHIFT)
|
||||||
|
|||||||
Reference in New Issue
Block a user