]> git.karo-electronics.de Git - karo-tx-linux.git/commit
tile: include: asm: use 'long long' instead of 'u64' for atomic64_t and its related...
authorChen Gang <gang.chen@asianux.com>
Wed, 25 Sep 2013 04:14:08 +0000 (12:14 +0800)
committerChris Metcalf <cmetcalf@tilera.com>
Fri, 27 Sep 2013 20:08:56 +0000 (16:08 -0400)
commitb924a69067b00d3121debae5a738fb0bcbbbb03c
tree574ab34819b91df7e7b4eb9cf750d3c6853033f3
parent4a10c2ac2f368583138b774ca41fac4207911983
tile: include: asm: use 'long long' instead of 'u64' for atomic64_t and its related functions

atomic* value is signed value, and atomic* functions need also process
signed value (parameter value, and return value), so use 'long long'
instead of 'u64'.

After replacement, it will also fix a bug for atomic64_add_negative():
"u64 is never less than 0".

The modifications are:

  in vim, use "1,% s/\<u64\>/long long/g" command.
  remove redundant '__aligned(8)'.
  be sure of 80 (and macro '\') columns limitation after replacement.

Signed-off-by: Chen Gang <gang.chen@asianux.com>
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com> [re-instated const cast]
arch/tile/include/asm/atomic.h
arch/tile/include/asm/atomic_32.h
arch/tile/include/asm/cmpxchg.h
arch/tile/lib/atomic_32.c