Skip to content

Commit 4894e2f

Browse files
riteshharjanimaddy-kerneldev
authored andcommitted
powerpc/64s: Kill the unused argument of exit_lazy_flush_tlb
In previous patch we removed the only caller of exit_lazy_flush_tlb() which was passing always_flush = false in it's second argument. With that gone, all the callers of exit_lazy_flush_tlb() are local to radix_pgtable.c and there is no need of an additional argument. This patch does the required cleanup. There should not be any functionality change in this patch. Reviewed-by: Christophe Leroy (CS GROUP) <chleroy@kernel.org> Signed-off-by: Ritesh Harjani (IBM) <ritesh.list@gmail.com> Tested-by: Venkat Rao Bagalkote <venkat88@linux.ibm.com> Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com> Link: https://patch.msgid.link/6f96ea53588034312ae84f74b1e2fa9c4ce7cfd5.1773078178.git.ritesh.list@gmail.com
1 parent bf7c149 commit 4894e2f

3 files changed

Lines changed: 5 additions & 13 deletions

File tree

arch/powerpc/mm/book3s64/internal.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,4 @@ static inline bool slb_preload_disabled(void)
3131

3232
void hpt_do_stress(unsigned long ea, unsigned long hpte_group);
3333

34-
void exit_lazy_flush_tlb(struct mm_struct *mm, bool always_flush);
35-
3634
#endif /* ARCH_POWERPC_MM_BOOK3S64_INTERNAL_H */

arch/powerpc/mm/book3s64/pgtable.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@
2323
#include <mm/mmu_decl.h>
2424
#include <trace/events/thp.h>
2525

26-
#include "internal.h"
27-
2826
struct mmu_psize_def mmu_psize_defs[MMU_PAGE_COUNT];
2927
EXPORT_SYMBOL_GPL(mmu_psize_defs);
3028

arch/powerpc/mm/book3s64/radix_tlb.c

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@
1919
#include <asm/cputhreads.h>
2020
#include <asm/plpar_wrappers.h>
2121

22-
#include "internal.h"
23-
2422
/*
2523
* tlbiel instruction for radix, set invalidation
2624
* i.e., r=1 and is=01 or is=10 or is=11
@@ -660,7 +658,7 @@ static bool mm_needs_flush_escalation(struct mm_struct *mm)
660658
* If always_flush is true, then flush even if this CPU can't be removed
661659
* from mm_cpumask.
662660
*/
663-
void exit_lazy_flush_tlb(struct mm_struct *mm, bool always_flush)
661+
static void exit_lazy_flush_tlb(struct mm_struct *mm)
664662
{
665663
unsigned long pid = mm->context.id;
666664
int cpu = smp_processor_id();
@@ -703,19 +701,17 @@ void exit_lazy_flush_tlb(struct mm_struct *mm, bool always_flush)
703701
if (cpumask_test_cpu(cpu, mm_cpumask(mm))) {
704702
dec_mm_active_cpus(mm);
705703
cpumask_clear_cpu(cpu, mm_cpumask(mm));
706-
always_flush = true;
707704
}
708705

709706
out:
710-
if (always_flush)
711-
_tlbiel_pid(pid, RIC_FLUSH_ALL);
707+
_tlbiel_pid(pid, RIC_FLUSH_ALL);
712708
}
713709

714710
#ifdef CONFIG_SMP
715711
static void do_exit_flush_lazy_tlb(void *arg)
716712
{
717713
struct mm_struct *mm = arg;
718-
exit_lazy_flush_tlb(mm, true);
714+
exit_lazy_flush_tlb(mm);
719715
}
720716

721717
static void exit_flush_lazy_tlbs(struct mm_struct *mm)
@@ -777,7 +773,7 @@ static enum tlb_flush_type flush_type_needed(struct mm_struct *mm, bool fullmm)
777773
* to trim.
778774
*/
779775
if (tick_and_test_trim_clock()) {
780-
exit_lazy_flush_tlb(mm, true);
776+
exit_lazy_flush_tlb(mm);
781777
return FLUSH_TYPE_NONE;
782778
}
783779
}
@@ -823,7 +819,7 @@ static enum tlb_flush_type flush_type_needed(struct mm_struct *mm, bool fullmm)
823819
if (current->mm == mm)
824820
return FLUSH_TYPE_LOCAL;
825821
if (cpumask_test_cpu(cpu, mm_cpumask(mm)))
826-
exit_lazy_flush_tlb(mm, true);
822+
exit_lazy_flush_tlb(mm);
827823
return FLUSH_TYPE_NONE;
828824
}
829825

0 commit comments

Comments
 (0)