lkml.org 
[lkml]   [2003]   [Aug]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Race condition in 2.4 tasklet handling

Hi,

> Adding smp_mb__after_test_and_set_bit() at the end of
> tasklet_trylock() should remedy the situation. As
> smp_mb__{before|after}_test_and_set_bit() don't exist yet, I'm
> attaching a patch which adds smp_mb__after_clear_bit(). The patch is
> against 2.4.21.

No, the atomic and bitop operations that return values (like
test_and_set_bit) must have barriers. Is x86 missing these?

> P.S. Please comment on the addition of
> smp_mb__{before|after}_test_and_set_bit().

Only the atomic and bitops that dont return values (set_bit, atomic_inc
etc) might require ordering depending on use.

Anton
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:48    [W:0.075 / U:0.836 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site