linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paul Bolle <pebolle@tiscali.nl>
To: Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 1/2] x86: use stdout if insn decoder test is successful
Date: Tue, 25 Oct 2016 22:56:04 +0200	[thread overview]
Message-ID: <1477428965-20548-2-git-send-email-pebolle@tiscali.nl> (raw)
In-Reply-To: <1477428965-20548-1-git-send-email-pebolle@tiscali.nl>

If the instruction decoder test ran successful it prints a message like
this to stderr:
    Succeed: decoded and checked 1767380 instructions

But, as described in "console mode programming user interface guidelines
version 101" which doesn't exist, programs should use stderr for errors
or warnings. We're told about a successful run here, so the instruction
decoder test should use stdout.

Let's fix the typo too, while we're at it.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
---
The joke about the guidelines is shamelessly copied from commit 55a6e622e66a
("arch/x86/tools/insn_sanity.c: Identify source of messages"). Let's hope
Andrew doesn't mind!

 arch/x86/tools/test_get_len.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/tools/test_get_len.c b/arch/x86/tools/test_get_len.c
index 56f04db0c9c0..ecf31e0358c8 100644
--- a/arch/x86/tools/test_get_len.c
+++ b/arch/x86/tools/test_get_len.c
@@ -167,7 +167,7 @@ int main(int argc, char **argv)
 		fprintf(stderr, "Warning: decoded and checked %d"
 			" instructions with %d warnings\n", insns, warnings);
 	else
-		fprintf(stderr, "Succeed: decoded and checked %d"
+		fprintf(stdout, "Success: decoded and checked %d"
 			" instructions\n", insns);
 	return 0;
 }
-- 
2.7.4

  reply	other threads:[~2016-10-25 20:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-25 20:56 [PATCH 0/2] x86: use stdout for success and stdout for failure Paul Bolle
2016-10-25 20:56 ` Paul Bolle [this message]
2016-10-26  6:54   ` [tip:x86/asm] x86/decoder: Use stdout if insn decoder test is successful tip-bot for Paul Bolle
2016-10-25 20:56 ` [PATCH 2/2] x86: use stderr if insn sanity test fails Paul Bolle
2016-10-26  6:55   ` [tip:x86/asm] x86/decoder: Use " tip-bot for Paul Bolle

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=1477428965-20548-2-git-send-email-pebolle@tiscali.nl \
    --to=pebolle@tiscali.nl \
    --cc=akpm@linux-foundation.org \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /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).