diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-10-27 20:36:18 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-10-27 20:36:18 +0000 |
commit | 9a1af8dfbf9ed47c3bc12802c7d670480d0666b7 (patch) | |
tree | 5d892875390fffb55e1f76abc666e974612f9ca8 /sys/arch/m88k/include/lock.h | |
parent | 46e1c801d7a9835e871c570047964806aa7e6485 (diff) |
Use the same assembly constraints for all inline assembler xmem constructs.
Diffstat (limited to 'sys/arch/m88k/include/lock.h')
-rw-r--r-- | sys/arch/m88k/include/lock.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/m88k/include/lock.h b/sys/arch/m88k/include/lock.h index baa0439d728..13bfc2d0960 100644 --- a/sys/arch/m88k/include/lock.h +++ b/sys/arch/m88k/include/lock.h @@ -1,6 +1,6 @@ #ifndef _M88K_LOCK_H_ #define _M88K_LOCK_H_ -/* $OpenBSD: lock.h,v 1.4 2007/10/27 20:35:21 miod Exp $ */ +/* $OpenBSD: lock.h,v 1.5 2007/10/27 20:36:17 miod Exp $ */ /* * Copyright (c) 2005, Miodrag Vallat. @@ -55,7 +55,7 @@ __cpu_simple_lock(__cpu_simple_lock_t *l) do { old = __SIMPLELOCK_LOCKED; __asm__ __volatile__ - ("xmem %0, %1, r0" : "+r" (old) : "r" (l)); + ("xmem %0, %2, r0" : "+r"(old), "+m"(*l) : "r"(l)); } while (old != __SIMPLELOCK_UNLOCKED); } @@ -70,7 +70,7 @@ __cpu_simple_lock_try(__cpu_simple_lock_t *l) u_int old = __SIMPLELOCK_LOCKED; __asm__ __volatile__ - ("xmem %0, %1, r0" : "+r" (old) : "r" (l)); + ("xmem %0, %2, r0" : "+r"(old), "+m"(*l) : "r"(l)); return (old == __SIMPLELOCK_UNLOCKED); } |