diff options
Diffstat (limited to 'nptl/pthread_spin_init.c')
-rw-r--r-- | nptl/pthread_spin_init.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/nptl/pthread_spin_init.c b/nptl/pthread_spin_init.c index 01dec5eea4..fe3091377e 100644 --- a/nptl/pthread_spin_init.c +++ b/nptl/pthread_spin_init.c @@ -22,6 +22,7 @@ int pthread_spin_init (pthread_spinlock_t *lock, int pshared) { - *lock = 0; + /* Relaxed MO is fine because this is an initializing store. */ + atomic_store_relaxed (lock, 0); return 0; } |