powerpc: Only print PACATMSCRATCH in oops when TM is active
authorAnton Blanchard <anton@samba.org>
Mon, 18 Nov 2013 02:19:17 +0000 (13:19 +1100)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 20 Nov 2013 23:33:40 +0000 (10:33 +1100)
If TM is not active there is no need to print PACATMSCRATCH
so we can save ourselves a line.

Signed-off-by: Anton Blanchard <anton@samba.org>
Acked-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/process.c

index 373980ae52ad50ce92bc09731d0c3871457a258e..6cd50ac12219fcada4174de1ff7691a3c011e882 100644 (file)
@@ -871,7 +871,8 @@ void show_regs(struct pt_regs * regs)
        printk("SOFTE: %ld ", regs->softe);
 #endif
 #ifdef CONFIG_PPC_TRANSACTIONAL_MEM
-       printk("\nPACATMSCRATCH: %016llx ", get_paca()->tm_scratch);
+       if (MSR_TM_ACTIVE(regs->msr))
+               printk("\nPACATMSCRATCH: %016llx ", get_paca()->tm_scratch);
 #endif
 
        for (i = 0;  i < 32;  i++) {