From ba4f680586db72ab9476988c60d0f2e7a429c9a2 Mon Sep 17 00:00:00 2001 From: Justus Winter <4winter@informatik.uni-hamburg.de> Date: Tue, 8 Sep 2015 12:37:08 +0200 Subject: [PATCH hurd 2/2] libshouldbeinlibc/maptime: use memory fences * libshouldbeinlibc/maptime.h (maptime_read): Use memory fences. --- libshouldbeinlibc/maptime.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libshouldbeinlibc/maptime.h b/libshouldbeinlibc/maptime.h index 947ad64..04ce035 100644 --- a/libshouldbeinlibc/maptime.h +++ b/libshouldbeinlibc/maptime.h @@ -51,7 +51,9 @@ maptime_read (volatile struct mapped_time_value *mtime, struct timeval *tv) do { tv->tv_sec = mtime->seconds; + __sync_synchronize (); tv->tv_usec = mtime->microseconds; + __sync_synchronize (); } while (tv->tv_sec != mtime->check_seconds); } -- 2.1.4