Changes in kernel/arch/ia32/include/atomic.h [228666c:ba371e1] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/ia32/include/atomic.h
r228666c rba371e1 101 101 static inline atomic_count_t test_and_set(atomic_t *val) 102 102 { 103 atomic_count_t v ;103 atomic_count_t v = 1; 104 104 105 105 asm volatile ( 106 "movl $1, %[v]\n"107 106 "xchgl %[v], %[count]\n" 108 : [v] " =r" (v),107 : [v] "+r" (v), 109 108 [count] "+m" (val->count) 110 109 );
Note:
See TracChangeset
for help on using the changeset viewer.