linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] powerpc/64s/radix: remove unused flush_tlb_lpid variants
@ 2018-02-03  6:58 Nicholas Piggin
  2018-02-05  5:21 ` Aneesh Kumar K.V
  0 siblings, 1 reply; 2+ messages in thread
From: Nicholas Piggin @ 2018-02-03  6:58 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Nicholas Piggin, Aneesh Kumar K . V

These were intended for use by KVM, but it has its own LPID
flushing code and never used these.

Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
 .../powerpc/include/asm/book3s/64/tlbflush-radix.h |  3 --
 arch/powerpc/mm/tlb-radix.c                        | 40 ----------------------
 2 files changed, 43 deletions(-)

diff --git a/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h b/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
index 8eea90f80e45..19b45ba6caf9 100644
--- a/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
+++ b/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
@@ -47,9 +47,6 @@ extern void radix__flush_tlb_page_psize(struct mm_struct *mm, unsigned long vmad
 #endif
 extern void radix__flush_tlb_pwc(struct mmu_gather *tlb, unsigned long addr);
 extern void radix__flush_tlb_collapsed_pmd(struct mm_struct *mm, unsigned long addr);
-extern void radix__flush_tlb_lpid_va(unsigned long lpid, unsigned long gpa,
-				     unsigned long page_size);
-extern void radix__flush_tlb_lpid(unsigned long lpid);
 extern void radix__flush_tlb_all(void);
 extern void radix__flush_tlb_pte_p9_dd1(unsigned long old_pte, struct mm_struct *mm,
 					unsigned long address);
diff --git a/arch/powerpc/mm/tlb-radix.c b/arch/powerpc/mm/tlb-radix.c
index 71d1b19ad1c0..8ce858ec59e1 100644
--- a/arch/powerpc/mm/tlb-radix.c
+++ b/arch/powerpc/mm/tlb-radix.c
@@ -603,46 +603,6 @@ void radix__flush_tlb_collapsed_pmd(struct mm_struct *mm, unsigned long addr)
 }
 #endif /* CONFIG_TRANSPARENT_HUGEPAGE */
 
-void radix__flush_tlb_lpid_va(unsigned long lpid, unsigned long gpa,
-			      unsigned long page_size)
-{
-	unsigned long rb,rs,prs,r;
-	unsigned long ap;
-	unsigned long ric = RIC_FLUSH_TLB;
-
-	ap = mmu_get_ap(radix_get_mmu_psize(page_size));
-	rb = gpa & ~(PPC_BITMASK(52, 63));
-	rb |= ap << PPC_BITLSHIFT(58);
-	rs = lpid & ((1UL << 32) - 1);
-	prs = 0; /* process scoped */
-	r = 1;   /* raidx format */
-
-	asm volatile("ptesync": : :"memory");
-	asm volatile(PPC_TLBIE_5(%0, %4, %3, %2, %1)
-		     : : "r"(rb), "i"(r), "i"(prs), "i"(ric), "r"(rs) : "memory");
-	asm volatile("eieio; tlbsync; ptesync": : :"memory");
-	trace_tlbie(lpid, 0, rb, rs, ric, prs, r);
-}
-EXPORT_SYMBOL(radix__flush_tlb_lpid_va);
-
-void radix__flush_tlb_lpid(unsigned long lpid)
-{
-	unsigned long rb,rs,prs,r;
-	unsigned long ric = RIC_FLUSH_ALL;
-
-	rb = 0x2 << PPC_BITLSHIFT(53); /* IS = 2 */
-	rs = lpid & ((1UL << 32) - 1);
-	prs = 0; /* partition scoped */
-	r = 1;   /* raidx format */
-
-	asm volatile("ptesync": : :"memory");
-	asm volatile(PPC_TLBIE_5(%0, %4, %3, %2, %1)
-		     : : "r"(rb), "i"(r), "i"(prs), "i"(ric), "r"(rs) : "memory");
-	asm volatile("eieio; tlbsync; ptesync": : :"memory");
-	trace_tlbie(lpid, 0, rb, rs, ric, prs, r);
-}
-EXPORT_SYMBOL(radix__flush_tlb_lpid);
-
 void radix__flush_pmd_tlb_range(struct vm_area_struct *vma,
 				unsigned long start, unsigned long end)
 {
-- 
2.15.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] powerpc/64s/radix: remove unused flush_tlb_lpid variants
  2018-02-03  6:58 [PATCH] powerpc/64s/radix: remove unused flush_tlb_lpid variants Nicholas Piggin
@ 2018-02-05  5:21 ` Aneesh Kumar K.V
  0 siblings, 0 replies; 2+ messages in thread
From: Aneesh Kumar K.V @ 2018-02-05  5:21 UTC (permalink / raw)
  To: Nicholas Piggin, linuxppc-dev; +Cc: Nicholas Piggin

Nicholas Piggin <npiggin@gmail.com> writes:

> These were intended for use by KVM, but it has its own LPID
> flushing code and never used these.
>

Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>

> Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
> ---
>  .../powerpc/include/asm/book3s/64/tlbflush-radix.h |  3 --
>  arch/powerpc/mm/tlb-radix.c                        | 40 ----------------------
>  2 files changed, 43 deletions(-)
>
> diff --git a/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h b/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
> index 8eea90f80e45..19b45ba6caf9 100644
> --- a/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
> +++ b/arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
> @@ -47,9 +47,6 @@ extern void radix__flush_tlb_page_psize(struct mm_struct *mm, unsigned long vmad
>  #endif
>  extern void radix__flush_tlb_pwc(struct mmu_gather *tlb, unsigned long addr);
>  extern void radix__flush_tlb_collapsed_pmd(struct mm_struct *mm, unsigned long addr);
> -extern void radix__flush_tlb_lpid_va(unsigned long lpid, unsigned long gpa,
> -				     unsigned long page_size);
> -extern void radix__flush_tlb_lpid(unsigned long lpid);
>  extern void radix__flush_tlb_all(void);
>  extern void radix__flush_tlb_pte_p9_dd1(unsigned long old_pte, struct mm_struct *mm,
>  					unsigned long address);
> diff --git a/arch/powerpc/mm/tlb-radix.c b/arch/powerpc/mm/tlb-radix.c
> index 71d1b19ad1c0..8ce858ec59e1 100644
> --- a/arch/powerpc/mm/tlb-radix.c
> +++ b/arch/powerpc/mm/tlb-radix.c
> @@ -603,46 +603,6 @@ void radix__flush_tlb_collapsed_pmd(struct mm_struct *mm, unsigned long addr)
>  }
>  #endif /* CONFIG_TRANSPARENT_HUGEPAGE */
>  
> -void radix__flush_tlb_lpid_va(unsigned long lpid, unsigned long gpa,
> -			      unsigned long page_size)
> -{
> -	unsigned long rb,rs,prs,r;
> -	unsigned long ap;
> -	unsigned long ric = RIC_FLUSH_TLB;
> -
> -	ap = mmu_get_ap(radix_get_mmu_psize(page_size));
> -	rb = gpa & ~(PPC_BITMASK(52, 63));
> -	rb |= ap << PPC_BITLSHIFT(58);
> -	rs = lpid & ((1UL << 32) - 1);
> -	prs = 0; /* process scoped */
> -	r = 1;   /* raidx format */
> -
> -	asm volatile("ptesync": : :"memory");
> -	asm volatile(PPC_TLBIE_5(%0, %4, %3, %2, %1)
> -		     : : "r"(rb), "i"(r), "i"(prs), "i"(ric), "r"(rs) : "memory");
> -	asm volatile("eieio; tlbsync; ptesync": : :"memory");
> -	trace_tlbie(lpid, 0, rb, rs, ric, prs, r);
> -}
> -EXPORT_SYMBOL(radix__flush_tlb_lpid_va);
> -
> -void radix__flush_tlb_lpid(unsigned long lpid)
> -{
> -	unsigned long rb,rs,prs,r;
> -	unsigned long ric = RIC_FLUSH_ALL;
> -
> -	rb = 0x2 << PPC_BITLSHIFT(53); /* IS = 2 */
> -	rs = lpid & ((1UL << 32) - 1);
> -	prs = 0; /* partition scoped */
> -	r = 1;   /* raidx format */
> -
> -	asm volatile("ptesync": : :"memory");
> -	asm volatile(PPC_TLBIE_5(%0, %4, %3, %2, %1)
> -		     : : "r"(rb), "i"(r), "i"(prs), "i"(ric), "r"(rs) : "memory");
> -	asm volatile("eieio; tlbsync; ptesync": : :"memory");
> -	trace_tlbie(lpid, 0, rb, rs, ric, prs, r);
> -}
> -EXPORT_SYMBOL(radix__flush_tlb_lpid);
> -
>  void radix__flush_pmd_tlb_range(struct vm_area_struct *vma,
>  				unsigned long start, unsigned long end)
>  {
> -- 
> 2.15.1

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-05  5:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-03  6:58 [PATCH] powerpc/64s/radix: remove unused flush_tlb_lpid variants Nicholas Piggin
2018-02-05  5:21 ` Aneesh Kumar K.V

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).