Sparc64: complete and test implementation
authorMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Thu, 22 Oct 2009 19:50:05 +0000 (15:50 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Thu, 22 Oct 2009 19:50:05 +0000 (15:50 -0400)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
README
configure.ac
urcu/uatomic_arch_sparc64.h

diff --git a/README b/README
index b96912e829fc7042d0e2101062ecc454f9c3bd1f..7cc8871398b4c0a8b255bf8ddabfcbb7a40ed846 100644 (file)
--- a/README
+++ b/README
@@ -21,9 +21,9 @@ BUILDING
 ARCHITECTURES SUPPORTED
 -----------------------
 
-Currently, x86 (i386, i486, i586, i686), x86 64-bit, PowerPC 32/64, S390 and
-S390x are supported. Only tested on Linux so far, but should theoretically work
-on other operating systems.
+Currently, x86 (i386, i486, i586, i686), x86 64-bit, PowerPC 32/64, S390, S390x
+and Sparc64 are supported. Only tested on Linux so far, but should
+theoretically work on other operating systems.
 
 QUICK START GUIDE
 -----------------
index a8de71d3dcd9fc74ad5ca7edfad2e8ba97ad92fa..4ece75d24df3378eec161e599fe2e5238a913b6e 100644 (file)
@@ -47,7 +47,7 @@ case $target_cpu in
        ppc) ARCHTYPE="ppc" ;;
        s390) ARCHTYPE="s390" ;;
        s390x) ARCHTYPE="s390" ;;
-       sparc) ARCHTYPE="sparc" ;;
+       sparc64) ARCHTYPE="sparc64" ;;
        *) ARCHTYPE="unknown";;
 esac
 
index 87deacd1a064366bceb799cf8620485c06ba6206..35b9ac269c11197b52eac7d55546a7d3479586ed 100644 (file)
@@ -90,9 +90,9 @@ unsigned long _uatomic_exchange(void *addr, unsigned long val, int len)
        switch (len) {
        case 4:
        {
-               unsigned int old;
+               unsigned int old, oldt;
 
-               oldt = uatomic_read(addr);
+               oldt = uatomic_read((unsigned int *)addr);
                do {
                        old = oldt;
                        oldt = _uatomic_cmpxchg(addr, old, val, 4);
@@ -103,9 +103,9 @@ unsigned long _uatomic_exchange(void *addr, unsigned long val, int len)
 #if (BITS_PER_LONG == 64)
        case 8:
        {
-               unsigned long old;
+               unsigned long old, oldt;
 
-               oldt = uatomic_read(addr);
+               oldt = uatomic_read((unsigned long *)addr);
                do {
                        old = oldt;
                        oldt = _uatomic_cmpxchg(addr, old, val, 8);
@@ -132,9 +132,9 @@ unsigned long _uatomic_add_return(void *addr, unsigned long val,
        switch (len) {
        case 4:
        {
-               unsigned int old;
+               unsigned int old, oldt;
 
-               oldt = uatomic_read(addr);
+               oldt = uatomic_read((unsigned int *)addr);
                do {
                        old = oldt;
                        oldt = _uatomic_cmpxchg(addr, old, old + val, 4);
@@ -145,9 +145,9 @@ unsigned long _uatomic_add_return(void *addr, unsigned long val,
 #if (BITS_PER_LONG == 64)
        case 8:
        {
-               unsigned long old;
+               unsigned long old, oldt;
 
-               oldt = uatomic_read(addr);
+               oldt = uatomic_read((unsigned long *)addr);
                do {
                        old = oldt;
                        oldt = _uatomic_cmpxchg(addr, old, old + val, 8);
This page took 0.02622 seconds and 4 git commands to generate.