|
@@ -659,7 +659,7 @@ static struct spu *find_victim(struct spu_context *ctx)
|
|
|
|
|
|
victim->stats.invol_ctx_switch++;
|
|
victim->stats.invol_ctx_switch++;
|
|
spu->stats.invol_ctx_switch++;
|
|
spu->stats.invol_ctx_switch++;
|
|
- if (test_bit(SPU_SCHED_SPU_RUN, &ctx->sched_flags))
|
|
|
|
|
|
+ if (test_bit(SPU_SCHED_SPU_RUN, &victim->sched_flags))
|
|
spu_add_to_rq(victim);
|
|
spu_add_to_rq(victim);
|
|
|
|
|
|
mutex_unlock(&victim->state_mutex);
|
|
mutex_unlock(&victim->state_mutex);
|