powerpc/book3s: Flush SLB/TLBs if we get SLB/TLB machine check errors on power7.
If we get a machine check exception due to SLB or TLB errors, then flush SLBs/TLBs and reload SLBs to recover. We do this in real mode before turning on MMU. Otherwise we would run into nested machine checks. If we get a machine check when we are in guest, then just flush the SLBs and continue. This patch handles errors for power7. The next patch will handle errors for power8 Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
This commit is contained in:

committed by
Benjamin Herrenschmidt

parent
0440705049
commit
e22a22740c
@@ -73,6 +73,7 @@ extern void __restore_cpu_power8(void);
|
||||
extern void __restore_cpu_a2(void);
|
||||
extern void __flush_tlb_power7(unsigned long inval_selector);
|
||||
extern void __flush_tlb_power8(unsigned long inval_selector);
|
||||
extern long __machine_check_early_realmode_p7(struct pt_regs *regs);
|
||||
#endif /* CONFIG_PPC64 */
|
||||
#if defined(CONFIG_E500)
|
||||
extern void __setup_cpu_e5500(unsigned long offset, struct cpu_spec* spec);
|
||||
@@ -443,6 +444,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
|
||||
.cpu_setup = __setup_cpu_power7,
|
||||
.cpu_restore = __restore_cpu_power7,
|
||||
.flush_tlb = __flush_tlb_power7,
|
||||
.machine_check_early = __machine_check_early_realmode_p7,
|
||||
.platform = "power7",
|
||||
},
|
||||
{ /* 2.07-compliant processor, i.e. Power8 "architected" mode */
|
||||
@@ -479,6 +481,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
|
||||
.cpu_setup = __setup_cpu_power7,
|
||||
.cpu_restore = __restore_cpu_power7,
|
||||
.flush_tlb = __flush_tlb_power7,
|
||||
.machine_check_early = __machine_check_early_realmode_p7,
|
||||
.platform = "power7",
|
||||
},
|
||||
{ /* Power7+ */
|
||||
@@ -498,6 +501,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
|
||||
.cpu_setup = __setup_cpu_power7,
|
||||
.cpu_restore = __restore_cpu_power7,
|
||||
.flush_tlb = __flush_tlb_power7,
|
||||
.machine_check_early = __machine_check_early_realmode_p7,
|
||||
.platform = "power7+",
|
||||
},
|
||||
{ /* Power8E */
|
||||
|
Reference in New Issue
Block a user