@@ -282,6 +282,12 @@ static inline int pmd_special(pmd_t pmd)
return (pmd_val(pmd) & (_PAGE_SPECIAL | _PAGE_DMEM)) ==
(_PAGE_SPECIAL | _PAGE_DMEM);
}
+
+static inline int pud_special(pud_t pud)
+{
+ return (pud_val(pud) & (_PAGE_SPECIAL | _PAGE_DMEM)) ==
+ (_PAGE_SPECIAL | _PAGE_DMEM);
+}
#endif
#ifdef CONFIG_ARCH_HAS_PTE_DEVMAP
@@ -517,6 +523,13 @@ static inline pud_t pud_mkdirty(pud_t pud)
return pud_set_flags(pud, _PAGE_DIRTY | _PAGE_SOFT_DIRTY);
}
+#ifdef CONFIG_ARCH_HAS_PTE_DMEM
+static inline pud_t pud_mkdmem(pud_t pud)
+{
+ return pud_set_flags(pud, _PAGE_SPECIAL | _PAGE_DMEM);
+}
+#endif
+
static inline pud_t pud_mkdevmap(pud_t pud)
{
return pud_set_flags(pud, _PAGE_DEVMAP);
@@ -1139,6 +1139,16 @@ static inline int pmd_special(pmd_t pmd)
{
return 0;
}
+
+static inline pud_t pud_mkdmem(pud_t pud)
+{
+ return pud;
+}
+
+static inline int pud_special(pud_t pud)
+{
+ return 0;
+}
#endif
#ifndef pmd_read_atomic