]> xenbits.xensource.com Git - qemu-xen-4.4-testing.git/commitdiff
sparc64 syscall fix (Blue Swirl)
authorbellard <bellard>
Mon, 23 Oct 2006 21:31:01 +0000 (21:31 +0000)
committerbellard <bellard>
Mon, 23 Oct 2006 21:31:01 +0000 (21:31 +0000)
linux-user/main.c

index 53bf1bb92e1f453542b542bc6f16ba58ef1d04ba..38e94d27b5d8412a5ad849ec4219fcc559a827b6 100644 (file)
@@ -559,10 +559,18 @@ void cpu_loop (CPUSPARCState *env)
                               env->regwptr[2], env->regwptr[3], 
                               env->regwptr[4], env->regwptr[5]);
             if ((unsigned int)ret >= (unsigned int)(-515)) {
+#ifdef TARGET_SPARC64
+                env->xcc |= PSR_CARRY;
+#else
                 env->psr |= PSR_CARRY;
+#endif
                 ret = -ret;
             } else {
+#ifdef TARGET_SPARC64
+                env->xcc &= ~PSR_CARRY;
+#else
                 env->psr &= ~PSR_CARRY;
+#endif
             }
             env->regwptr[0] = ret;
             /* next instruction */