---
 qemu-lock.h |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/qemu-lock.h b/qemu-lock.h
index 5c8eb34..23e3442 100644
--- a/qemu-lock.h
+++ b/qemu-lock.h
@@ -34,7 +34,7 @@
 #else
 
 #ifdef CONFIG_GCC_ATOMIC_BUILTINS
-typedef int spinlock_t;
+typedef volatile int spinlock_t;
 
 #define SPIN_LOCK_UNLOCKED 0
 
@@ -43,7 +43,7 @@ typedef int spinlock_t;
 
 #if defined(__hppa__)
 
-typedef int spinlock_t[4];
+typedef volatile int spinlock_t[4];
 
 #define SPIN_LOCK_UNLOCKED { 1, 1, 1, 1 }
 
@@ -54,7 +54,7 @@ static inline void resetlock (spinlock_t *p)
 
 #else
 
-typedef int spinlock_t;
+typedef volatile int spinlock_t;
 
 #define SPIN_LOCK_UNLOCKED 0
 
-- 
1.7.0



Reply via email to