|
@@ -161,22 +161,6 @@ pfn_pte(unsigned long pfn, pgprot_t prot)
|
|
|
#define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) })
|
|
|
#define __swp_entry_to_pte(x) ((pte_t) { (x).val })
|
|
|
|
|
|
-/*
|
|
|
- * Encode and decode a nonlinear file mapping entry
|
|
|
- */
|
|
|
-#define pte_to_pgoff(_pte) ((((_pte).pte >> 1 ) & 0x07) | \
|
|
|
- (((_pte).pte >> 2 ) & 0x38) | \
|
|
|
- (((_pte).pte >> 10) << 6 ))
|
|
|
-
|
|
|
-#define pgoff_to_pte(off) ((pte_t) { (((off) & 0x07) << 1 ) | \
|
|
|
- (((off) & 0x38) << 2 ) | \
|
|
|
- (((off) >> 6 ) << 10) | \
|
|
|
- _PAGE_FILE })
|
|
|
-
|
|
|
-/*
|
|
|
- * Bits 0, 4, 8, and 9 are taken, split up 28 bits of offset into this range:
|
|
|
- */
|
|
|
-#define PTE_FILE_MAX_BITS 28
|
|
|
#else
|
|
|
|
|
|
#if defined(CONFIG_PHYS_ADDR_T_64BIT) && defined(CONFIG_CPU_MIPS32)
|
|
@@ -188,13 +172,6 @@ pfn_pte(unsigned long pfn, pgprot_t prot)
|
|
|
#define __pte_to_swp_entry(pte) ((swp_entry_t) { (pte).pte_high })
|
|
|
#define __swp_entry_to_pte(x) ((pte_t) { 0, (x).val })
|
|
|
|
|
|
-/*
|
|
|
- * Bits 0 and 1 of pte_high are taken, use the rest for the page offset...
|
|
|
- */
|
|
|
-#define pte_to_pgoff(_pte) ((_pte).pte_high >> 2)
|
|
|
-#define pgoff_to_pte(off) ((pte_t) { _PAGE_FILE, (off) << 2 })
|
|
|
-
|
|
|
-#define PTE_FILE_MAX_BITS 30
|
|
|
#else
|
|
|
/*
|
|
|
* Constraints:
|
|
@@ -209,19 +186,6 @@ pfn_pte(unsigned long pfn, pgprot_t prot)
|
|
|
#define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) })
|
|
|
#define __swp_entry_to_pte(x) ((pte_t) { (x).val })
|
|
|
|
|
|
-/*
|
|
|
- * Encode and decode a nonlinear file mapping entry
|
|
|
- */
|
|
|
-#define pte_to_pgoff(_pte) ((((_pte).pte >> 1) & 0x7) | \
|
|
|
- (((_pte).pte >> 2) & 0x8) | \
|
|
|
- (((_pte).pte >> 8) << 4))
|
|
|
-
|
|
|
-#define pgoff_to_pte(off) ((pte_t) { (((off) & 0x7) << 1) | \
|
|
|
- (((off) & 0x8) << 2) | \
|
|
|
- (((off) >> 4) << 8) | \
|
|
|
- _PAGE_FILE })
|
|
|
-
|
|
|
-#define PTE_FILE_MAX_BITS 28
|
|
|
#endif /* defined(CONFIG_PHYS_ADDR_T_64BIT) && defined(CONFIG_CPU_MIPS32) */
|
|
|
|
|
|
#endif /* defined(CONFIG_CPU_R3000) || defined(CONFIG_CPU_TX39XX) */
|