[PATCH 4/10] ppc64: Make stab_initialize() work on iSeries

Michael Ellerman michael at ellerman.id.au
Wed Aug 10 15:40:12 EST 2005


On Wed, 10 Aug 2005 14:33, David Gibson wrote:
> On Wed, Aug 10, 2005 at 02:18:36PM +1000, Michael Ellerman wrote:
> > We don't need to call stab_initialize() for the boot cpu on iSeries, so
> > we hack around it so that early_setup() can be called on iSeries.
>
> I'd suggest just folding the firmware_has_feature() logic into
> early_setup, rather than having the trivial function.

Yeah, duh. That evolved from a different hack which is why it's the way it
was, but I should have cleaned it up.

---
We don't need to call stab_initialize() for the boot cpu on iSeries, so
we hack around it so that early_setup() can be called on iSeries.

Signed-off-by: Michael Ellerman <michael at ellerman.id.au>
---

We don't need to call stab_initialize() for the boot cpu on iSeries, so
we hack around it so that early_setup() can be called on iSeries.

 arch/ppc64/kernel/setup.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletion(-)

Index: work/arch/ppc64/kernel/setup.c
===================================================================
--- work.orig/arch/ppc64/kernel/setup.c
+++ work/arch/ppc64/kernel/setup.c
@@ -58,6 +58,7 @@
 #include <asm/mmu.h>
 #include <asm/lmb.h>
 #include <asm/iSeries/ItLpNaca.h>
+#include <asm/firmware.h>

 #ifdef DEBUG
 #define DBG(fmt...) udbg_printf(fmt)
@@ -436,7 +437,8 @@ void __init early_setup(unsigned long dt
 	/*
 	 * Initialize stab / SLB management
 	 */
-	stab_initialize(lpaca->stab_real);
+	if (!firmware_has_feature(FW_FEATURE_ISERIES))
+		stab_initialize(lpaca->stab_real);

 	/*
 	 * Initialize the MMU Hash table and create the linear mapping




More information about the Linuxppc64-dev mailing list