Commit e840cfe6 authored by Jeremy Kerr's avatar Jeremy Kerr Committed by Arnd Bergmann

[CELL] spufs: Remove spurious WARN_ON for spu_deactivate for NOSCHED contexts

In 6cbf93960e64f313f6e247cbca7afaa50e3ee2c we added a WARN_ON for
calling spu_deactivate on contexts created with the SPU_CREATE_NOSCHED
flag. However, all NOSCHED contexts will need to be deactivated when
the context is destroyed, so this gives a spurious warning when any
NOSCHED context is closed.

This change removes the WARN_ON.
Signed-off-by: default avatarJeremy Kerr <jk@ozlabs.org>
Signed-off-by: default avatarArnd Bergmann <arnd.bergmann@de.ibm.com>
parent d054b36f
...@@ -550,15 +550,6 @@ static int __spu_deactivate(struct spu_context *ctx, int force, int max_prio) ...@@ -550,15 +550,6 @@ static int __spu_deactivate(struct spu_context *ctx, int force, int max_prio)
*/ */
void spu_deactivate(struct spu_context *ctx) void spu_deactivate(struct spu_context *ctx)
{ {
/*
* We must never reach this for a nosched context,
* but handle the case gracefull instead of panicing.
*/
if (ctx->flags & SPU_CREATE_NOSCHED) {
WARN_ON(1);
return;
}
__spu_deactivate(ctx, 1, MAX_PRIO); __spu_deactivate(ctx, 1, MAX_PRIO);
spuctx_switch_state(ctx, SPUCTX_UTIL_USER); spuctx_switch_state(ctx, SPUCTX_UTIL_USER);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment