[Cbe-oss-dev] [PATCH] spufs: Fix use time accounting on SPE-overcommit

Andre Detsch adetsch at br.ibm.com
Tue Feb 26 05:07:42 EST 2008


From: Andre Detsch <adetsch at br.ibm.com>
Subject: spufs: Fix use time accounting on SPE-overcommit

The spu_runcntl_RW register is restored within spu_restore function.
So, at the end of spu_bind_context, the SPU context is not just loaded,
but running.

Signed-off-by: Andre Detsch <adetsch at br.ibm.com>

Index: linux-2.6.25-rc1/arch/powerpc/platforms/cell/spufs/sched.c
===================================================================
--- linux-2.6.25-rc1.orig/arch/powerpc/platforms/cell/spufs/sched.c
+++ linux-2.6.25-rc1/arch/powerpc/platforms/cell/spufs/sched.c
@@ -246,7 +246,7 @@ static void spu_bind_context(struct spu 
 	spu_switch_notify(spu, ctx);
 	ctx->state = SPU_STATE_RUNNABLE;
 
-	spuctx_switch_state(ctx, SPU_UTIL_IDLE_LOADED);
+	spuctx_switch_state(ctx, SPU_UTIL_USER);
 }
 
 /*



More information about the cbe-oss-dev mailing list