From 2ab4b135638ab595fa534d46d8358125d2ae1f6a Mon Sep 17 00:00:00 2001 From: Alistair Francis Date: Mon, 11 Sep 2017 12:52:50 -0700 Subject: Convert single line fprintf(.../n) to warn_report() Convert all the single line uses of fprintf(stderr, "warning:"..."\n"... to use warn_report() instead. This helps standardise on a single method of printing warnings to the user. All of the warnings were changed using this command: find ./* -type f -exec sed -i \ 's|fprintf(.*".*warning[,:] \(.*\)\\n"\(.*\));|warn_report("\1"\2);|Ig' \ {} + Some of the lines were manually edited to reduce the line length to below 80 charecters. The #include lines were manually updated to allow the code to compile. Signed-off-by: Alistair Francis Cc: Kevin Wolf Cc: Max Reitz Cc: "Michael S. Tsirkin" Cc: Igor Mammedov Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Habkost Cc: Gerd Hoffmann Cc: Jason Wang Cc: Michael Roth Cc: James Hogan Cc: Aurelien Jarno Cc: Yongbok Kim Cc: Stefan Hajnoczi Reviewed-by: Markus Armbruster Reviewed-by: James Hogan [mips] Message-Id: Signed-off-by: Paolo Bonzini --- target/mips/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'target/mips') diff --git a/target/mips/kvm.c b/target/mips/kvm.c index 3317905..a23aa43 100644 --- a/target/mips/kvm.c +++ b/target/mips/kvm.c @@ -95,11 +95,11 @@ void kvm_mips_reset_vcpu(MIPSCPU *cpu) CPUMIPSState *env = &cpu->env; if (!kvm_mips_fpu_cap && env->CP0_Config1 & (1 << CP0C1_FP)) { - fprintf(stderr, "Warning: KVM does not support FPU, disabling\n"); + warn_report("KVM does not support FPU, disabling"); env->CP0_Config1 &= ~(1 << CP0C1_FP); } if (!kvm_mips_msa_cap && env->CP0_Config3 & (1 << CP0C3_MSAP)) { - fprintf(stderr, "Warning: KVM does not support MSA, disabling\n"); + warn_report("KVM does not support MSA, disabling"); env->CP0_Config3 &= ~(1 << CP0C3_MSAP); } -- cgit v1.1