|
@@ -115,7 +115,12 @@
|
|
|
#define _KERNPG_TABLE (_PAGE_PRESENT | _PAGE_RW | _PAGE_ACCESSED | \
|
|
|
_PAGE_DIRTY)
|
|
|
|
|
|
-/* Set of bits not changed in pte_modify */
|
|
|
+/*
|
|
|
+ * Set of bits not changed in pte_modify. The pte's
|
|
|
+ * protection key is treated like _PAGE_RW, for
|
|
|
+ * instance, and is *not* included in this mask since
|
|
|
+ * pte_modify() does modify it.
|
|
|
+ */
|
|
|
#define _PAGE_CHG_MASK (PTE_PFN_MASK | _PAGE_PCD | _PAGE_PWT | \
|
|
|
_PAGE_SPECIAL | _PAGE_ACCESSED | _PAGE_DIRTY | \
|
|
|
_PAGE_SOFT_DIRTY)
|
|
@@ -231,7 +236,10 @@ enum page_cache_mode {
|
|
|
/* Extracts the PFN from a (pte|pmd|pud|pgd)val_t of a 4KB page */
|
|
|
#define PTE_PFN_MASK ((pteval_t)PHYSICAL_PAGE_MASK)
|
|
|
|
|
|
-/* Extracts the flags from a (pte|pmd|pud|pgd)val_t of a 4KB page */
|
|
|
+/*
|
|
|
+ * Extracts the flags from a (pte|pmd|pud|pgd)val_t
|
|
|
+ * This includes the protection key value.
|
|
|
+ */
|
|
|
#define PTE_FLAGS_MASK (~PTE_PFN_MASK)
|
|
|
|
|
|
typedef struct pgprot { pgprotval_t pgprot; } pgprot_t;
|