Merge branch 'for-linus' of git://www.linux-m32r.org/git/takata/linux-2.6_dev
[pandora-kernel.git] / include / asm-cris / pgtable.h
index 417f711..829e7a7 100644 (file)
@@ -115,6 +115,7 @@ static inline int pte_write(pte_t pte)          { return pte_val(pte) & _PAGE_WR
 static inline int pte_dirty(pte_t pte)          { return pte_val(pte) & _PAGE_MODIFIED; }
 static inline int pte_young(pte_t pte)          { return pte_val(pte) & _PAGE_ACCESSED; }
 static inline int pte_file(pte_t pte)           { return pte_val(pte) & _PAGE_FILE; }
+static inline int pte_special(pte_t pte)       { return 0; }
 
 static inline pte_t pte_wrprotect(pte_t pte)
 {
@@ -162,6 +163,7 @@ static inline pte_t pte_mkyoung(pte_t pte)
         }
         return pte;
 }
+static inline pte_t pte_mkspecial(pte_t pte)   { return pte; }
 
 /*
  * Conversion functions: convert a page and protection to a page entry,
@@ -229,7 +231,7 @@ static inline void pmd_set(pmd_t * pmdp, pte_t * ptep)
 #define pgd_index(address) (((address) >> PGDIR_SHIFT) & (PTRS_PER_PGD-1))
 
 /* to find an entry in a page-table-directory */
-static inline pgd_t * pgd_offset(struct mm_struct * mm, unsigned long address)
+static inline pgd_t * pgd_offset(const struct mm_struct *mm, unsigned long address)
 {
        return mm->pgd + pgd_index(address);
 }
@@ -249,7 +251,7 @@ static inline pgd_t * pgd_offset(struct mm_struct * mm, unsigned long address)
 #define pte_unmap(pte) do { } while (0)
 #define pte_unmap_nested(pte) do { } while (0)
 #define pte_pfn(x)             ((unsigned long)(__va((x).pte)) >> PAGE_SHIFT)
-#define pfn_pte(pfn, prot)     __pte((__pa((pfn) << PAGE_SHIFT)) | pgprot_val(prot))
+#define pfn_pte(pfn, prot)     __pte(((pfn) << PAGE_SHIFT) | pgprot_val(prot))
 
 #define pte_ERROR(e) \
         printk("%s:%d: bad pte %p(%08lx).\n", __FILE__, __LINE__, &(e), pte_val(e))