Skip to content

Commit

Permalink
[POWERPC] spu_base: move spu_init_channels out of spu_mutex
Browse files Browse the repository at this point in the history
There is no reason to execute spu_init_channels under spu_mutex
after the spu has been taken off the freelist it's ours.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
  • Loading branch information
Christoph Hellwig authored and Arnd Bergmann committed Apr 23, 2007
1 parent 4e0f4ed commit 62c05d5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/powerpc/platforms/cell/spu_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -431,10 +431,11 @@ struct spu *spu_alloc_node(int node)
spu = list_entry(spu_list[node].next, struct spu, list);
list_del_init(&spu->list);
pr_debug("Got SPU %d %d\n", spu->number, spu->node);
spu_init_channels(spu);
}
mutex_unlock(&spu_mutex);

if (spu)
spu_init_channels(spu);
return spu;
}
EXPORT_SYMBOL_GPL(spu_alloc_node);
Expand Down

0 comments on commit 62c05d5

Please sign in to comment.