struct mmu_gather;
 extern void hash__tlb_flush(struct mmu_gather *tlb);
 /* Private function for use by PCI IO mapping code */
-extern void __flush_hash_table_range(struct mm_struct *mm, unsigned long start,
-                                    unsigned long end);
+extern void __flush_hash_table_range(unsigned long start, unsigned long end);
 extern void flush_tlb_pmd_range(struct mm_struct *mm, pmd_t *pmd,
                                unsigned long addr);
 #endif /*  _ASM_POWERPC_BOOK3S_64_TLBFLUSH_HASH_H */
 
  *                            from the hash table (and the TLB). But keeps
  *                            the linux PTEs intact.
  *
- * @mm         : mm_struct of the target address space (generally init_mm)
  * @start      : starting address
  * @end         : ending address (not included in the flush)
  *
  * Because of that usage pattern, it is implemented for small size rather
  * than speed.
  */
-void __flush_hash_table_range(struct mm_struct *mm, unsigned long start,
-                             unsigned long end)
+void __flush_hash_table_range(unsigned long start, unsigned long end)
 {
-       bool is_thp;
        int hugepage_shift;
        unsigned long flags;
 
        start = _ALIGN_DOWN(start, PAGE_SIZE);
        end = _ALIGN_UP(end, PAGE_SIZE);
 
-       BUG_ON(!mm->pgd);
 
        /*
         * Note: Normally, we should only ever use a batch within a
        local_irq_save(flags);
        arch_enter_lazy_mmu_mode();
        for (; start < end; start += PAGE_SIZE) {
-               pte_t *ptep = find_current_mm_pte(mm->pgd, start, &is_thp,
-                                                 &hugepage_shift);
+               pte_t *ptep = find_init_mm_pte(start, &hugepage_shift);
                unsigned long pte;
 
                if (ptep == NULL)
                        continue;
                pte = pte_val(*ptep);
-               if (is_thp)
-                       trace_hugepage_invalidate(start, pte);
                if (!(pte & H_PAGE_HASHPTE))
                        continue;
-               if (unlikely(is_thp))
-                       hpte_do_hugepage_flush(mm, start, (pmd_t *)ptep, pte);
-               else
-                       hpte_need_flush(mm, start, ptep, pte, hugepage_shift);
+               hpte_need_flush(&init_mm, start, ptep, pte, hugepage_shift);
        }
        arch_leave_lazy_mmu_mode();
        local_irq_restore(flags);