[Cbe-oss-dev] [PATCH] fix physical spu utilization statistics
André Detsch
adetsch at br.ibm.com
Sat Jul 7 06:01:09 EST 2007
Luke Browning wrote:
> Index: linux-2.6.22-rc5/arch/powerpc/platforms/cell/spufs/sched.c
(...)
> +
> + spuctx_switch_state(ctx, SPUCTX_UTIL_USER);
> + ctx->spu = NULL;
> + ctx->state = SPU_STATE_SAVED;
> }
There is a problem that I've confirmed experimentally here:
no matter what switch_state we call on ctx after the above lines (end of
spu_unbind_context function), ctx->spu will be NULL, and the utilization
state for the SPU will be kept in SPUCTX_UTIL_USER state.
One simple solution would be to change this switch to
spuctx_switch_state(ctx, SPUCTX_UTIL_LOADED);
(which maps the spu utilization to 'IDLE'), but I'm not sure if this
fits in your states model.
--
Andre Detsch
More information about the cbe-oss-dev
mailing list