summaryrefslogtreecommitdiff
path: root/arch/powerpc/mm/mmu_context_book3s64.c
diff options
context:
space:
mode:
authorAlexey Kardashevskiy <aik@ozlabs.ru>2016-11-30 17:51:59 +1100
committerMichael Ellerman <mpe@ellerman.id.au>2016-12-02 14:38:27 +1100
commit88f54a3581eb9deaa3bd1aade40aef266d782385 (patch)
tree0881b300b6c4876e07faceebc1706feea78e47c9 /arch/powerpc/mm/mmu_context_book3s64.c
parentf6853eb561fb9bfd56dfe0009f0ea27540937bd5 (diff)
powerpc/iommu: Pass mm_struct to init/cleanup helpers
We are going to get rid of @current references in mmu_context_boos3s64.c and cache mm_struct in the VFIO container. Since mm_context_t does not have reference counting, we will be using mm_struct which does have the reference counter. This changes mm_iommu_init/mm_iommu_cleanup to receive mm_struct rather than mm_context_t (which is embedded into mm). This should not cause any behavioral change. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/mm/mmu_context_book3s64.c')
-rw-r--r--arch/powerpc/mm/mmu_context_book3s64.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/mm/mmu_context_book3s64.c b/arch/powerpc/mm/mmu_context_book3s64.c
index b114f8b93ec9..ad8273590975 100644
--- a/arch/powerpc/mm/mmu_context_book3s64.c
+++ b/arch/powerpc/mm/mmu_context_book3s64.c
@@ -115,7 +115,7 @@ int init_new_context(struct task_struct *tsk, struct mm_struct *mm)
mm->context.pte_frag = NULL;
#endif
#ifdef CONFIG_SPAPR_TCE_IOMMU
- mm_iommu_init(&mm->context);
+ mm_iommu_init(mm);
#endif
return 0;
}
@@ -160,7 +160,7 @@ static inline void destroy_pagetable_page(struct mm_struct *mm)
void destroy_context(struct mm_struct *mm)
{
#ifdef CONFIG_SPAPR_TCE_IOMMU
- mm_iommu_cleanup(&mm->context);
+ mm_iommu_cleanup(mm);
#endif
#ifdef CONFIG_PPC_ICSWX