summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorAndre Detsch <adetsch@br.ibm.com>2007-09-19 04:38:12 (GMT)
committerPaul Mackerras <paulus@samba.org>2007-09-19 05:12:16 (GMT)
commit36ddbb1380f282b4280c57efdb646dd8647a789f (patch)
treefbae61d4f858f31ef41631f54d2ab3982f02efb4 /kernel
parent8b0d3121a0b2cf91768ecef635e241b6abc3f1da (diff)
downloadlinux-36ddbb1380f282b4280c57efdb646dd8647a789f.tar.xz
[POWERPC] spufs: Fix race condition on gang->aff_ref_spu
Affinity reference point location (gang->aff_ref_spu) is reset when the whole gang is descheduled. However, the last member of a gang can be descheduled while we are trying to schedule another member of the gang. This was leading to a race condition, and the code was using gang->aff_ref_spu in an unsafe manner. By holding the gang->aff_mutex a little bit longer, and increment gang->aff_sched_count (which controls when gang->aff_ref_spu should be reset) a little bit earlier, the problem is fixed. Signed-off-by: Andre Detsch <adetsch@br.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions