On 12/12/15 11:39, Paolo Bonzini wrote:
> "Unimplemented" messages go to stderr, everything else goes to tracepoints
> 
> Signed-off-by: Paolo Bonzini <pbonz...@redhat.com>
> ---
[...]
> diff --git a/linux-user/signal.c b/linux-user/signal.c
> index 9d62e02..919aa83 100644
> --- a/linux-user/signal.c
> +++ b/linux-user/signal.c
[...]
> @@ -3972,14 +3974,15 @@ give_sigsegv:
>  
>  long do_sigreturn(CPUOpenRISCState *env)
>  {
> -
> -    qemu_log("do_sigreturn: not implemented\n");
> +    trace_user_do_sigreturn(env, 0);
> +    fprintf(stderr, "do_sigreturn: not implemented\n");
>      return -TARGET_ENOSYS;
>  }
>  
>  long do_rt_sigreturn(CPUOpenRISCState *env)
>  {
> -    qemu_log("do_rt_sigreturn: not implemented\n");
> +    trace_user_do_rt_sigreturn(env, 0);
> +    fprintf(stderr, "do_rt_sigreturn: not implemented\n");
>      return -TARGET_ENOSYS;
>  }

Why not simply using qemu_log_mask(LOG_UNIMP, ...) instead? Isn't that
what the LOG_UNIMP flag is good for?

 Thomas


Reply via email to