qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: Alistair Francis <alistair.francis@xilinx.com>, qemu-devel@nongnu.org
Cc: alistair23@gmail.com, Stafford Horne <shorne@gmail.com>,
	armbru@redhat.com, Jia Liu <proljc@gmail.com>
Subject: Re: [Qemu-devel] [PATCH v2 30/47] hw/openrisc: Replace fprintf(stderr, "*\n" with error_report()
Date: Mon, 16 Oct 2017 13:50:12 +0200	[thread overview]
Message-ID: <331996a3-60ef-52b4-97b0-a8ef24c91cc2@redhat.com> (raw)
In-Reply-To: <9056bbcdb0d8fe7f0dbb1a050cacacb0ed508204.1506730372.git.alistair.francis@xilinx.com>

On 30.09.2017 02:16, Alistair Francis wrote:
> Replace a large number of the fprintf(stderr, "*\n" calls with
> error_report(). The functions were renamed with these commands and then
> compiler issues where manually fixed.
> 
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N;N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N;N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> find ./* -type f -exec sed -i \
>     'N; {s|fprintf(stderr, "\(.*\)\\n"\(.*\));|error_report("\1"\2);|Ig}' \
>     {} +
> 
> Some lines where then manually tweaked to pass checkpatch.
> 
> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> Cc: Jia Liu <proljc@gmail.com>
> Cc: Stafford Horne <shorne@gmail.com>
> ---
> V2:
>  - Split hw patch into individual directories
> 
>  hw/openrisc/openrisc_sim.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/openrisc/openrisc_sim.c b/hw/openrisc/openrisc_sim.c
> index 86bf2849c4..44a6d115dd 100644
> --- a/hw/openrisc/openrisc_sim.c
> +++ b/hw/openrisc/openrisc_sim.c
> @@ -19,6 +19,7 @@
>   */
>  
>  #include "qemu/osdep.h"
> +#include "qemu/error-report.h"
>  #include "qapi/error.h"
>  #include "qemu-common.h"
>  #include "cpu.h"
> @@ -87,7 +88,7 @@ static void cpu_openrisc_load_kernel(ram_addr_t ram_size,
>          }
>  
>          if (kernel_size < 0) {
> -            fprintf(stderr, "QEMU: couldn't load the kernel '%s'\n",
> +            error_report("QEMU: couldn't load the kernel '%s'",
>                      kernel_filename);

Please remove the "QEMU:" prefix here as well.

 Thomas

  parent reply	other threads:[~2017-10-16 11:50 UTC|newest]

Thread overview: 99+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-30  0:14 [Qemu-devel] [PATCH v2 00/47] Remove some of the fprintf(stderr, "* Alistair Francis
2017-09-30  0:14 ` [Qemu-devel] [PATCH v2 01/47] Replace all occurances of __FUNCTION__ with __func__ Alistair Francis
2017-10-02 14:11   ` Stefan Hajnoczi
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 02/47] Fixes after renaming __FUNCTION__ to __func__ Alistair Francis
2017-09-30  6:31   ` Thomas Huth
2017-10-02 14:00   ` Eric Blake
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 03/47] audio: Replace AUDIO_FUNC with __func__ Alistair Francis
2017-09-30  6:35   ` Thomas Huth
2017-10-02 14:08   ` Eric Blake
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 04/47] tests: Replace fprintf(stderr, "*\n" with error_report() Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 05/47] hw/arm: " Alistair Francis
2017-09-30  2:46   ` [Qemu-devel] [Qemu-arm] " Philippe Mathieu-Daudé
2017-10-16 11:41   ` [Qemu-devel] " Thomas Huth
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 06/47] hw/block: " Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 07/47] hw/bt: " Alistair Francis
2017-10-01 14:06   ` Thomas Huth
2017-10-17 18:32     ` Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 08/47] hw/char: " Alistair Francis
2017-10-01 14:09   ` Thomas Huth
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 09/47] hw/core: " Alistair Francis
2017-10-01  1:56   ` Philippe Mathieu-Daudé
2017-10-01 14:11   ` Thomas Huth
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 10/47] hw/cris: " Alistair Francis
2017-10-01 14:13   ` Thomas Huth
2017-10-16 11:42     ` Thomas Huth
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 11/47] hw/display: " Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 12/47] hw/dma: " Alistair Francis
2017-10-01  1:55   ` Philippe Mathieu-Daudé
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 13/47] hw/gpio: " Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 14/47] hw/i2c: " Alistair Francis
2017-10-01  1:52   ` Philippe Mathieu-Daudé
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 16/47] hw/ide: " Alistair Francis
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 17/47] hw/input: " Alistair Francis
2017-10-16 11:43   ` Thomas Huth
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 18/47] hw/intc: " Alistair Francis
2017-10-04  7:34   ` Cornelia Huck
2017-09-30  0:15 ` [Qemu-devel] [PATCH v2 19/47] hw/ipmi: " Alistair Francis
2017-10-01  1:50   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 20/47] hw/isa: " Alistair Francis
2017-10-01  1:48   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 21/47] hw/lm32: " Alistair Francis
2017-10-01  1:48   ` Philippe Mathieu-Daudé
2017-10-16 11:45   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 22/47] hw/m68k: " Alistair Francis
2017-09-30  6:42   ` Thomas Huth
2017-10-16 11:25   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 23/47] hw/microblaze: " Alistair Francis
2017-09-30  2:43   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 24/47] hw/mips: " Alistair Francis
2017-09-30  2:36   ` Philippe Mathieu-Daudé
2017-10-16 11:46   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 25/47] hw/misc: " Alistair Francis
2017-10-01  1:47   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 26/47] hw/moxie: " Alistair Francis
2017-10-01  1:46   ` Philippe Mathieu-Daudé
2017-10-16 11:47   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 27/47] hw/net: " Alistair Francis
2017-10-01  1:46   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 28/47] hw/nios2: " Alistair Francis
2017-09-30  2:39   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 29/47] hw/nvram: " Alistair Francis
2017-09-30  6:50   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 30/47] hw/openrisc: " Alistair Francis
2017-09-30 19:05   ` Stafford Horne
2017-10-16 11:50   ` Thomas Huth [this message]
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 31/47] hw/pci*: " Alistair Francis
2017-10-01  1:43   ` Philippe Mathieu-Daudé
2017-10-01  8:11   ` Marcel Apfelbaum
2017-10-02 18:15     ` Alistair Francis
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 32/47] hw/ppc: " Alistair Francis
2017-10-04  6:11   ` David Gibson
2017-10-16 11:53   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 33/47] hw/s390x: " Alistair Francis
2017-10-16 11:55   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 34/47] hw/scsi: " Alistair Francis
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 35/47] hw/sd: " Alistair Francis
2017-10-01  1:41   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 36/47] hw/sh4: " Alistair Francis
2017-10-16 11:56   ` Thomas Huth
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 37/47] hw/sparc*: " Alistair Francis
2017-09-30  2:40   ` Philippe Mathieu-Daudé
2017-09-30  0:16 ` [Qemu-devel] [PATCH v2 38/47] hw/ssi: " Alistair Francis
2017-10-01  1:38   ` Philippe Mathieu-Daudé
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 39/47] hw/timer: " Alistair Francis
2017-10-01  1:37   ` Philippe Mathieu-Daudé
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 40/47] hw/usb: " Alistair Francis
2017-10-01  1:36   ` Philippe Mathieu-Daudé
2017-10-01 14:16     ` Thomas Huth
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 41/47] hw/watchdog: " Alistair Francis
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 42/47] hw/xen*: " Alistair Francis
2017-10-10 15:13   ` Anthony PERARD
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 43/47] util: " Alistair Francis
2017-09-30  2:43   ` Philippe Mathieu-Daudé
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 44/47] ui: " Alistair Francis
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 45/47] tcg: " Alistair Francis
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 46/47] target: Use qemu_log() instead of fprintf(stderr, ...) Alistair Francis
2017-09-30  0:17 ` [Qemu-devel] [PATCH v2 47/47] target: Replace fprintf(stderr, "*\n" with error_report() Alistair Francis
2017-10-04  7:41   ` Cornelia Huck
     [not found] ` <ade26715c9bde1fe921959823de08da582fce58f.1506730372.git.alistair.francis@xilinx.com>
2017-10-10 14:51   ` [Qemu-devel] [PATCH v2 15/47] hw/i386: " Anthony PERARD

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=331996a3-60ef-52b4-97b0-a8ef24c91cc2@redhat.com \
    --to=thuth@redhat.com \
    --cc=alistair.francis@xilinx.com \
    --cc=alistair23@gmail.com \
    --cc=armbru@redhat.com \
    --cc=proljc@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=shorne@gmail.com \
    /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).