aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/page_64.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-powerpc/page_64.h')
-rw-r--r--include/asm-powerpc/page_64.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/asm-powerpc/page_64.h b/include/asm-powerpc/page_64.h
index 25af4fc8daf4..043bfdfe4f73 100644
--- a/include/asm-powerpc/page_64.h
+++ b/include/asm-powerpc/page_64.h
@@ -90,6 +90,7 @@ extern unsigned int HPAGE_SHIFT;
90#define HPAGE_SIZE ((1UL) << HPAGE_SHIFT) 90#define HPAGE_SIZE ((1UL) << HPAGE_SHIFT)
91#define HPAGE_MASK (~(HPAGE_SIZE - 1)) 91#define HPAGE_MASK (~(HPAGE_SIZE - 1))
92#define HUGETLB_PAGE_ORDER (HPAGE_SHIFT - PAGE_SHIFT) 92#define HUGETLB_PAGE_ORDER (HPAGE_SHIFT - PAGE_SHIFT)
93#define HUGE_MAX_HSTATE 3
93 94
94#endif /* __ASSEMBLY__ */ 95#endif /* __ASSEMBLY__ */
95 96
@@ -126,16 +127,22 @@ extern unsigned int get_slice_psize(struct mm_struct *mm,
126 127
127extern void slice_init_context(struct mm_struct *mm, unsigned int psize); 128extern void slice_init_context(struct mm_struct *mm, unsigned int psize);
128extern void slice_set_user_psize(struct mm_struct *mm, unsigned int psize); 129extern void slice_set_user_psize(struct mm_struct *mm, unsigned int psize);
130extern void slice_set_range_psize(struct mm_struct *mm, unsigned long start,
131 unsigned long len, unsigned int psize);
132
129#define slice_mm_new_context(mm) ((mm)->context.id == 0) 133#define slice_mm_new_context(mm) ((mm)->context.id == 0)
130 134
131#endif /* __ASSEMBLY__ */ 135#endif /* __ASSEMBLY__ */
132#else 136#else
133#define slice_init() 137#define slice_init()
138#define get_slice_psize(mm, addr) ((mm)->context.user_psize)
134#define slice_set_user_psize(mm, psize) \ 139#define slice_set_user_psize(mm, psize) \
135do { \ 140do { \
136 (mm)->context.user_psize = (psize); \ 141 (mm)->context.user_psize = (psize); \
137 (mm)->context.sllp = SLB_VSID_USER | mmu_psize_defs[(psize)].sllp; \ 142 (mm)->context.sllp = SLB_VSID_USER | mmu_psize_defs[(psize)].sllp; \
138} while (0) 143} while (0)
144#define slice_set_range_psize(mm, start, len, psize) \
145 slice_set_user_psize((mm), (psize))
139#define slice_mm_new_context(mm) 1 146#define slice_mm_new_context(mm) 1
140#endif /* CONFIG_PPC_MM_SLICES */ 147#endif /* CONFIG_PPC_MM_SLICES */
141 148