From: Laurent Vivier <laurent@vivier.eu>
To: Riku Voipio <riku.voipio@iki.fi>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] linux-user: fix fadvise64_64() on ppc
Date: Tue, 25 Apr 2017 18:33:14 +0200 [thread overview]
Message-ID: <c49f8bbe-aa67-27a4-4654-3d8830d17232@vivier.eu> (raw)
In-Reply-To: <20170302001145.6879-1-laurent@vivier.eu>
Ping?
Laurent
Le 02/03/2017 à 01:11, Laurent Vivier a écrit :
> On ppc, advice is arg2, not arg6:
>
> long ppc_fadvise64_64(int fd, int advice, u32 offset_high, u32 offset_low,
> u32 len_high, u32 len_low)
>
> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
> ---
> linux-user/syscall.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/linux-user/syscall.c b/linux-user/syscall.c
> index 2da8426..671b13a 100644
> --- a/linux-user/syscall.c
> +++ b/linux-user/syscall.c
> @@ -11261,6 +11261,15 @@ 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)
> + /* 6 args: fd, advice, offset (high, low), len (high, low) */
> + ret = arg2;
> + arg2 = arg3;
> + arg3 = arg4;
> + arg4 = arg5;
> + arg5 = arg6;
> + arg6 = ret;
> +#else
> /* 6 args: fd, offset (high, low), len (high, low), advice */
> if (regpairs_aligned(cpu_env)) {
> /* offset is in (3,4), len in (5,6) and advice in 7 */
> @@ -11270,6 +11279,7 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1,
> arg5 = arg6;
> arg6 = arg7;
> }
> +#endif
> ret = -host_to_target_errno(posix_fadvise(arg1,
> target_offset64(arg2, arg3),
> target_offset64(arg4, arg5),
>
prev parent reply other threads:[~2017-04-25 16:33 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-02 0:11 [Qemu-devel] [PATCH] linux-user: fix fadvise64_64() on ppc Laurent Vivier
2017-04-25 16:33 ` Laurent Vivier [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c49f8bbe-aa67-27a4-4654-3d8830d17232@vivier.eu \
--to=laurent@vivier.eu \
--cc=qemu-devel@nongnu.org \
--cc=riku.voipio@iki.fi \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).