diff options
Diffstat (limited to 'include/arch/x86_64/page.h')
-rw-r--r-- | include/arch/x86_64/page.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/arch/x86_64/page.h b/include/arch/x86_64/page.h index 99bc691..4460720 100644 --- a/include/arch/x86_64/page.h +++ b/include/arch/x86_64/page.h @@ -4,6 +4,11 @@ #include <stdint.h> #include "include/object.h" +#define PAGE_PRESENT (1ULL << 0) +#define PAGE_RW (1ULL << 1) +#define PAGE_US (1ULL << 2) +#define PAGE_XD (1ULL << 63) + typedef union jove_PageMapLevelEntry { struct { @@ -16,7 +21,7 @@ typedef union jove_PageMapLevelEntry uint8_t d : 1; /* Dirty */ uint8_t ps_pat : 1; uint8_t g : 1; /* Global */ - uint8_t _r0 : 2; + uint8_t osflg : 2; uint8_t r : 1; uint64_t paddr : 35; uint8_t _r1; @@ -35,6 +40,7 @@ uintptr_t vmem_ident_tophys(void *vptr); void *vmem_phys_tovirt(uintptr_t pptr); void *pmle_get_page(pmle_t entry); +uint8_t pmle_level(pmle_t entry); int untyped_retype_page(objdir_entry_t *untyped_entry, void **dest_ptr); |