Thread (4 messages) flat view 4 messages, 4 authors, 2016-11-16

Re: [PATCH v2] powerpc/mm/radix: Invalidate ERAT on tlbiel for POWER9 DD1

From: Balbir Singh <bsingharora@gmail.com>
Date: 2016-11-16 11:02:22


On 16/11/16 21:51, Michael Ellerman wrote:
Michael Neuling [off-list ref] writes:
quoted
diff --git a/arch/powerpc/mm/tlb-radix.c b/arch/powerpc/mm/tlb-radix.c
index bda8c43be7..4a19cdd8a0 100644
--- a/arch/powerpc/mm/tlb-radix.c
+++ b/arch/powerpc/mm/tlb-radix.c
@@ -50,6 +50,9 @@ static inline void _tlbiel_pid(unsigned long pid, unsigned long ric)
 	for (set = 0; set < POWER9_TLB_SETS_RADIX ; set++) {
 		__tlbiel_pid(pid, set, ric);
 	}
+	if (cpu_has_feature(CPU_FTR_POWER9_DD1))
+		asm volatile(PPC_SLBIA(0x7)
+			     : : :"memory");
Ah of course I'll use slbia to invalidate the ERAT.

How about we do:

#define PPC_INVALIDATE_ERAT	PPC_SLBIA(0x7)
While you are at it, could you also add a TODO
to use a HCALL when LPCR_GTSE is not set
(when running in guest mode)

Balbir Singh.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help