diff options
author | Andreas Schwab <schwab@linux-m68k.org> | 2012-08-08 10:39:05 +0200 |
---|---|---|
committer | Andreas Schwab <schwab@linux-m68k.org> | 2012-08-08 12:13:56 +0200 |
commit | 3b7d2b398e49a0661d0a8663c75e2cc7b8e52560 (patch) | |
tree | 0b7525d131c5eaca50975029fd78d0c7725fd911 /ports | |
parent | bf9b740a119eecf01499b4de0dc8cbd27b7c47bd (diff) | |
download | glibc-3b7d2b398e49a0661d0a8663c75e2cc7b8e52560.tar.gz glibc-3b7d2b398e49a0661d0a8663c75e2cc7b8e52560.tar.xz glibc-3b7d2b398e49a0661d0a8663c75e2cc7b8e52560.zip |
m68k/cf: avoid warning in non-shared atomic_compare_and_exchange_val_acq
Diffstat (limited to 'ports')
-rw-r--r-- | ports/ChangeLog.m68k | 6 | ||||
-rw-r--r-- | ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h | 12 |
2 files changed, 12 insertions, 6 deletions
diff --git a/ports/ChangeLog.m68k b/ports/ChangeLog.m68k index cf3d251460..e4fccd2115 100644 --- a/ports/ChangeLog.m68k +++ b/ports/ChangeLog.m68k @@ -1,3 +1,9 @@ +2012-08-08 Andreas Schwab <schwab@linux-m68k.org> + + * sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h + (atomic_compare_and_exchange_val_acq) [!SHARED]: Add cast to avoid + warning. + 2012-08-07 Joseph Myers <joseph@codesourcery.com> * sysdeps/unix/sysv/linux/m68k/configure.in (arch_minimum_kernel): diff --git a/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h b/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h index b088a7247c..23ef447ff3 100644 --- a/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h +++ b/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/bits/atomic.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2010 Free Software Foundation, Inc. +/* Copyright (C) 2010-2012 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Maxim Kuvyrkov <maxim@codesourcery.com>, 2010. @@ -42,8 +42,8 @@ typedef uintmax_t uatomic_max_t; #ifdef SHARED # define atomic_compare_and_exchange_val_acq(mem, newval, oldval) \ ({ \ - /* Use temporary variables to workaround call-clobberness of */ \ - /* the registers. */ \ + /* Use temporary variables to workaround call-clobberness of \ + the registers. */ \ __typeof (mem) _mem = mem; \ __typeof (oldval) _oldval = oldval; \ __typeof (newval) _newval = newval; \ @@ -65,13 +65,13 @@ typedef uintmax_t uatomic_max_t; #else # define atomic_compare_and_exchange_val_acq(mem, newval, oldval) \ ({ \ - /* Use temporary variables to workaround call-clobberness of */ \ - /* the registers. */ \ + /* Use temporary variables to workaround call-clobberness of \ + the registers. */ \ __typeof (mem) _mem = mem; \ __typeof (oldval) _oldval = oldval; \ __typeof (newval) _newval = newval; \ register __typeof (oldval) _d0 asm ("d0") \ - = SYS_ify (atomic_cmpxchg_32); \ + = (__typeof (oldval)) SYS_ify (atomic_cmpxchg_32); \ register __typeof (mem) _a0 asm ("a0") = _mem; \ register __typeof (oldval) _d2 asm ("d2") = _oldval; \ register __typeof (newval) _d1 asm ("d1") = _newval; \ |