lkml.org 
[lkml]   [1998]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: test_and_set_bit() not atomic forever? [cli/sti in char/vt.c [patch]]
On Sun, 31 May 1998, Mike Ford Ditto wrote:

>There seems to be some terminology confusion here. There are two kinds
>of atomicicty... many CPUs provide an "atomic" test-and-set instruction
>which can not be interrupted (by interrupts, that is). These
>instructions usually are not atomic at the bus level, only at the CPU
>instruction level. Another bus master (a DMA device or another CPU) can
>access the same memory word inbetween the test and the set.

This is _not_ the needed atomicity for test_and_set_bit() I think...

>So another kind of atomicity is often provided which is guaranteed
>atomic even against other CPUs contending for the same word using the

I think this is the right atomicity for test_and_set_bit() (and i386
implement it in this way). Probably all ports are implementing
test_and_set_bit() in this way too just now so I think this is no more an
issue.

Andrea[s] Arcangeli


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

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