Skip to contentSkip to conversation

powerpc/mm/slice: Remove slice_mm_new_context

PATCH Applied Aneesh Kumar K.V 2 participants 2 messages May 2, 2016 – May 4, 2016 PowerPC

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 powerpc/mm/slice: Remove slice_mm_new_context

The existing usage is bogus, because we set the context.id value in the same function. The book3s 64 got removed in the old patch. Hence remove the redundant definition.

---
 arch/powerpc/include/asm/page_64.h   | 3 ---
 arch/powerpc/mm/mmu_context_nohash.c | 3 +--
 2 files changed, 1 insertion(+), 5 deletions(-)
arch/powerpc/include/asm/page_64.h +0 -3
index 77488857c26d..dd5f0712afa2 100644
@@ -128,8 +128,6 @@ extern void slice_set_user_psize(struct mm_struct *mm, unsigned int psize);
 extern void slice_set_range_psize(struct mm_struct *mm, unsigned long start,
 				  unsigned long len, unsigned int psize);
 
-#define slice_mm_new_context(mm)	((mm)->context.id == MMU_NO_CONTEXT)
-
 #endif /* __ASSEMBLY__ */
 #else
 #define slice_init()
@@ -151,7 +149,6 @@ do {						\
 
 #define slice_set_range_psize(mm, start, len, psize)	\
 	slice_set_user_psize((mm), (psize))
-#define slice_mm_new_context(mm)	1
 #endif /* CONFIG_PPC_MM_SLICES */
 
 #ifdef CONFIG_HUGETLB_PAGE
arch/powerpc/mm/mmu_context_nohash.c +1 -2
index a36c43a27893..7d95bc402dba 100644
@@ -335,8 +335,7 @@ int init_new_context(struct task_struct *t, struct mm_struct *mm)
 	mm->context.active = 0;
 
 #ifdef CONFIG_PPC_MM_SLICES
-	if (slice_mm_new_context(mm))
-		slice_set_user_psize(mm, mmu_virtual_psize);
+	slice_set_user_psize(mm, mmu_virtual_psize);
 #endif
 
 	return 0;
Signature · 1 line
2.7.4