linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] powerpc/e5500: Set r5 to point to cpu spec in setup_cpu_e5500()
@ 2011-09-16 15:37 Kumar Gala
  2011-09-16 18:36 ` Scott Wood
  0 siblings, 1 reply; 2+ messages in thread
From: Kumar Gala @ 2011-09-16 15:37 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Laurentiu Tudor

From: Laurentiu Tudor <Laurentiu.Tudor@freescale.com>

e500mc and e5500 share some eary setup code that need r5 to point to the
cpu spec structure.  setup_cpu_e500mc() sets it but setup_cpu_e5500()
didn't.

This caused a crash on 32 bit e5500 running under hypervisor, when
__setup_e500mc_ivors() tried to access the cpu features field.

Signed-off-by: Laurentiu Tudor <Laurentiu.Tudor@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
 arch/powerpc/kernel/cpu_setup_fsl_booke.S |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
index 8053db0..f9f6a6f 100644
--- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
+++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
@@ -1,7 +1,7 @@
 /*
  * This file contains low level CPU setup functions.
  * Kumar Gala <galak@kernel.crashing.org>
- * Copyright 2009 Freescale Semiconductor, Inc.
+ * Copyright 2009,2011 Freescale Semiconductor, Inc.
  *
  * Based on cpu_setup_6xx code by
  * Benjamin Herrenschmidt <benh@kernel.crashing.org>
@@ -83,6 +83,7 @@ _GLOBAL(__setup_cpu_e500mc)
 /* Right now, restore and setup are the same thing */
 _GLOBAL(__restore_cpu_e5500)
 _GLOBAL(__setup_cpu_e5500)
+	mr	r5, r4
 	mflr	r4
 	bl	__e500_icache_setup
 	bl	__e500_dcache_setup
-- 
1.7.3.4

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

end of thread, other threads:[~2011-09-16 18:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-16 15:37 [PATCH] powerpc/e5500: Set r5 to point to cpu spec in setup_cpu_e5500() Kumar Gala
2011-09-16 18:36 ` Scott Wood

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).