qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Laurent Vivier <laurent@vivier.eu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Cc: qemu-devel@nongnu.org, "Riku Voipio" <riku.voipio@iki.fi>,
	"Guido Günther" <agx@sigxcpu.org>
Subject: Re: [Qemu-devel] [PATCH v2 04/12] linux-user/strace: Improve gettimeofday() and settimeofday() output
Date: Sun, 1 Jul 2018 21:52:42 +0200	[thread overview]
Message-ID: <a7baf500-bfe7-6720-700c-8a39e5ea7ebc@vivier.eu> (raw)
In-Reply-To: <20180628034652.24152-5-f4bug@amsat.org>

Le 28/06/2018 à 05:46, Philippe Mathieu-Daudé a écrit :
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> Tested-By: Guido Günther <agx@sigxcpu.org>
> ---
>  linux-user/strace.c    | 13 +++++++++++++
>  linux-user/strace.list |  4 ++--
>  2 files changed, 15 insertions(+), 2 deletions(-)
> 
> diff --git a/linux-user/strace.c b/linux-user/strace.c
> index b43a21f48b..955fe80ef2 100644
> --- a/linux-user/strace.c
> +++ b/linux-user/strace.c
> @@ -1499,6 +1499,19 @@ print_futimesat(const struct syscallname *name,
>  }
>  #endif
>  
> +#if defined(TARGET_NR_gettimeofday) || defined(TARGET_NR_settimeofday)
> +static void
> +print_timeofday(const struct syscallname *name,
> +                abi_long arg0, abi_long arg1, abi_long arg2,
> +                abi_long arg3, abi_long arg4, abi_long arg5)
> +{
> +    print_syscall_prologue(name);
> +    print_timeval(arg0, 0);
> +    print_timezone(arg1, 1);
> +    print_syscall_epilogue(name);
> +}
> +#endif
> +
>  #ifdef TARGET_NR_link
>  static void
>  print_link(const struct syscallname *name,
> diff --git a/linux-user/strace.list b/linux-user/strace.list
> index afe4db07f3..9b477b7730 100644
> --- a/linux-user/strace.list
> +++ b/linux-user/strace.list
> @@ -384,7 +384,7 @@
>  { TARGET_NR_gettid, "gettid" , "%s()", NULL, NULL },
>  #endif
>  #ifdef TARGET_NR_gettimeofday
> -{ TARGET_NR_gettimeofday, "gettimeofday" , NULL, NULL, NULL },
> +{ TARGET_NR_gettimeofday, "gettimeofday" , NULL, print_timeofday, NULL },

print_timeofday() will be called before the call of gettimeofday() so I
don't think the values you will print here have any meaning.

Thanks,
Laurent

  reply	other threads:[~2018-07-01 19:52 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-28  3:46 [Qemu-devel] [PATCH v2 00/12] linux-user: strace improvements Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 01/12] linux-user/syscall: Verify recvfrom(addr) is user-writable Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 02/12] linux-user/strace: Improve capget()/capset() output Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 04/12] linux-user/strace: Improve gettimeofday() and settimeofday() output Philippe Mathieu-Daudé
2018-07-01 19:52   ` Laurent Vivier [this message]
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 05/12] linux-user/strace: Dump AF_NETLINK sockaddr content Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 06/12] linux-user/strace: Improve recvmsg() output Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 09/12] linux-user/strace: Let print_sockaddr() have a 'last' argument Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [RFC PATCH v2 10/12] linux-user/strace: Add print_sockaddr_ptr() to handle plain/pointer addrlen Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 11/12] linux-user/strace: Improve getsockname() output Philippe Mathieu-Daudé
2018-06-28  3:46 ` [Qemu-devel] [PATCH v2 12/12] linux-user/strace: Improve recvfrom() output Philippe Mathieu-Daudé
     [not found] ` <20180628034652.24152-4-f4bug@amsat.org>
2018-07-01 19:44   ` [Qemu-devel] [PATCH v2 03/12] linux-user/strace: Add print_timezone() Laurent Vivier
2018-07-02 17:37     ` Philippe Mathieu-Daudé

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=a7baf500-bfe7-6720-700c-8a39e5ea7ebc@vivier.eu \
    --to=laurent@vivier.eu \
    --cc=agx@sigxcpu.org \
    --cc=f4bug@amsat.org \
    --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).