From patchwork Tue Jul 23 15:49:06 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Riku Voipio X-Patchwork-Id: 261120 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id CF3C42C0084 for ; Wed, 24 Jul 2013 01:57:07 +1000 (EST) Received: from localhost ([::1]:39196 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V1exU-0007x9-QC for incoming@patchwork.ozlabs.org; Tue, 23 Jul 2013 11:57:04 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57631) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V1eqE-0005Of-Jp for qemu-devel@nongnu.org; Tue, 23 Jul 2013 11:50:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V1epz-0001b6-IO for qemu-devel@nongnu.org; Tue, 23 Jul 2013 11:49:34 -0400 Received: from afflict.kos.to ([92.243.29.197]:45183) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V1epz-0001Yq-Co for qemu-devel@nongnu.org; Tue, 23 Jul 2013 11:49:19 -0400 Received: from kos.to (a91-156-63-85.elisa-laajakaista.fi [91.156.63.85]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by afflict.kos.to (Postfix) with ESMTPSA id BF1522655C for ; Tue, 23 Jul 2013 17:49:17 +0200 (CEST) Received: from voipio (uid 1000) (envelope-from voipio@kos.to) id 5e081a by kos.to (DragonFly Mail Agent); Tue, 23 Jul 2013 18:49:14 +0300 From: riku.voipio@linaro.org To: qemu-devel@nongnu.org Date: Tue, 23 Jul 2013 18:49:06 +0300 Message-Id: <82f05b69e6b701157b4a2e7d76ae6cf5542d66c9.1374593203.git.riku.voipio@linaro.org> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 92.243.29.197 Cc: Peter Maydell Subject: [Qemu-devel] [PULL 16/21] linux-user: Fix pipe syscall return for SPARC X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Peter Maydell SPARC is one of the CPUs which has a funny syscall ABI for the pipe syscall; add it to the set of special cases in do_pipe(). Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/syscall.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 5bd57d0..a797afc 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -1032,6 +1032,9 @@ static abi_long do_pipe(void *cpu_env, abi_ulong pipedes, #elif defined(TARGET_SH4) ((CPUSH4State*)cpu_env)->gregs[1] = host_pipe[1]; return host_pipe[0]; +#elif defined(TARGET_SPARC) + ((CPUSPARCState*)cpu_env)->regwptr[1] = host_pipe[1]; + return host_pipe[0]; #endif }