From patchwork Sun Apr 1 22:12:53 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Max Filippov X-Patchwork-Id: 10319343 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id BCFCE60532 for ; Sun, 1 Apr 2018 22:14:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9CD4828D6B for ; Sun, 1 Apr 2018 22:14:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9133C28D96; Sun, 1 Apr 2018 22:14:02 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, FROM_LOCAL_NOVOWEL, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 2895E28D6B for ; Sun, 1 Apr 2018 22:14:01 +0000 (UTC) Received: from localhost ([::1]:39261 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f2lEe-0004vL-Mj for patchwork-qemu-devel@patchwork.kernel.org; Sun, 01 Apr 2018 18:14:00 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57539) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f2lDp-0004NR-1n for qemu-devel@nongnu.org; Sun, 01 Apr 2018 18:13:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f2lDo-0007jy-72 for qemu-devel@nongnu.org; Sun, 01 Apr 2018 18:13:09 -0400 Received: from mail-lf0-x244.google.com ([2a00:1450:4010:c07::244]:39547) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f2lDo-0007j9-0Y for qemu-devel@nongnu.org; Sun, 01 Apr 2018 18:13:08 -0400 Received: by mail-lf0-x244.google.com with SMTP id p142-v6so18411504lfd.6 for ; Sun, 01 Apr 2018 15:13:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=5nGuRctqcRIQddzppZK2xmbEPwQNsAZwTJj5VF9LCWI=; b=q7CVAaBYTVYTB0BJTY4Iah5O76PY/OEHEyfbN6Kl4DIuTPnB3nVNx55C8ERbcJnjqQ Md58yCzNH7BqsfGJ3rxDwBY6X/Q+owKOStDn7/YiJIPwiNdeeZ9t/GsK+lGnV+mUaCqe SDq3H968cOAOubBt0Iv6QMxCQMCkRcWsriDL7bHqQ31IRGkWONTcjOwVjC+FfdqQXIc/ CHDeGegY486sgt9zypqq1BGL/gpDHKmXlJOBZ3MWOepKjK9giZik6AYXk6RTLCcdJ6KV eYTzCQ7nunH7iAIPd7IM54hCPCKdTLg6nzBftorTfomMcOpRrEUgN8bfESnt0fMacJt4 0YIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=5nGuRctqcRIQddzppZK2xmbEPwQNsAZwTJj5VF9LCWI=; b=qGTUJffuEnN7xXb2D8Gv4ZKG+ZAawECUipsdyr4fh6922Hx8BOEHUHgLPSVa+vk7c2 OQbhv/yXSI5EOF9kizxvTVGQwy0dJvje+u+7AjDrBOAVR7Ruu1Cd4pd6XkQ9X0M9EoIm T4Kn031vbQ/y+vjiR/fQi/fNflzQM7dep4iZSXTc6ksOowZXifeuXRickXGCSVHm+b8P l3OKArojCNryzhSyjYlglJqc28nqQc5MdfN4eVX72ha1rWuXpyovkQG/4ThmTS3lf+9S peZX1kOsEo02zXoiQuGXhR22ZGZUj/BtwV2sl1xv6TFk6nbQd/vDlOmn3BsR5Cezcjhg UeRw== X-Gm-Message-State: ALQs6tCzsr7LhOc1HGxyY1EXZBcKHzxjZSdmLccGpRbREkNLfWtehBD8 6swTwRyIeWh8K5JjqBlKMKMR4w== X-Google-Smtp-Source: AIpwx49HfNsvOCXHC704H09/JjUj4G98W7FmuGOCrTcsf8eoN4l9qFnL5PcSImpArMnhHSkD5f3BYg== X-Received: by 10.46.25.134 with SMTP id 6mr4301484ljz.14.1522620786580; Sun, 01 Apr 2018 15:13:06 -0700 (PDT) Received: from octofox.hsd1.ca.comcast.net. (jcmvbkbc-1-pt.tunnel.tserv24.sto1.ipv6.he.net. [2001:470:27:1fa::2]) by smtp.gmail.com with ESMTPSA id s26-v6sm2713290lfi.15.2018.04.01.15.13.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 01 Apr 2018 15:13:05 -0700 (PDT) From: Max Filippov To: qemu-devel@nongnu.org Date: Sun, 1 Apr 2018 15:12:53 -0700 Message-Id: <20180401221253.1382-1-jcmvbkbc@gmail.com> X-Mailer: git-send-email 2.11.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4010:c07::244 Subject: [Qemu-devel] [PATCH] target/xtensa: linux-user: fix fadvise64 call X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Max Filippov , Riku Voipio , Laurent Vivier Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP fadvise64_64 on xtensa passes advice as the second argument and so must be handled similar to PPC. This fixes glibc testsuite tests posix/tst-posix_fadvise and posix/tst-posix_fadvise64. Signed-off-by: Max Filippov Reviewed-by: Laurent Vivier --- linux-user/syscall.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 924fd68efcdd..5ef517613577 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -11509,7 +11509,7 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1, #ifdef TARGET_NR_fadvise64_64 case TARGET_NR_fadvise64_64: -#if defined(TARGET_PPC) +#if defined(TARGET_PPC) || defined(TARGET_XTENSA) /* 6 args: fd, advice, offset (high, low), len (high, low) */ ret = arg2; arg2 = arg3;