aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86/pgtable-2level.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86/pgtable-2level.h')
-rw-r--r--include/asm-x86/pgtable-2level.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/asm-x86/pgtable-2level.h b/include/asm-x86/pgtable-2level.h
index d3171c0cb157..f949bb083089 100644
--- a/include/asm-x86/pgtable-2level.h
+++ b/include/asm-x86/pgtable-2level.h
@@ -72,13 +72,13 @@ static inline int pte_exec_kernel(pte_t pte)
72 ((((pte).pte_low >> 1) & 0x1f ) + (((pte).pte_low >> 8) << 5 )) 72 ((((pte).pte_low >> 1) & 0x1f ) + (((pte).pte_low >> 8) << 5 ))
73 73
74#define pgoff_to_pte(off) \ 74#define pgoff_to_pte(off) \
75 ((pte_t) { (((off) & 0x1f) << 1) + (((off) >> 5) << 8) + _PAGE_FILE }) 75 ((pte_t) { .pte_low = (((off) & 0x1f) << 1) + (((off) >> 5) << 8) + _PAGE_FILE })
76 76
77/* Encode and de-code a swap entry */ 77/* Encode and de-code a swap entry */
78#define __swp_type(x) (((x).val >> 1) & 0x1f) 78#define __swp_type(x) (((x).val >> 1) & 0x1f)
79#define __swp_offset(x) ((x).val >> 8) 79#define __swp_offset(x) ((x).val >> 8)
80#define __swp_entry(type, offset) ((swp_entry_t) { ((type) << 1) | ((offset) << 8) }) 80#define __swp_entry(type, offset) ((swp_entry_t) { ((type) << 1) | ((offset) << 8) })
81#define __pte_to_swp_entry(pte) ((swp_entry_t) { (pte).pte_low }) 81#define __pte_to_swp_entry(pte) ((swp_entry_t) { (pte).pte_low })
82#define __swp_entry_to_pte(x) ((pte_t) { (x).val }) 82#define __swp_entry_to_pte(x) ((pte_t) { .pte = (x).val })
83 83
84#endif /* _I386_PGTABLE_2LEVEL_H */ 84#endif /* _I386_PGTABLE_2LEVEL_H */