From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_2 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DB075C2B9F4 for ; Mon, 28 Jun 2021 13:50:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C5FA661C78 for ; Mon, 28 Jun 2021 13:50:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232374AbhF1Nw4 (ORCPT ); Mon, 28 Jun 2021 09:52:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:54374 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232301AbhF1Nwn (ORCPT ); Mon, 28 Jun 2021 09:52:43 -0400 Received: from oasis.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5284D61C7E; Mon, 28 Jun 2021 13:50:17 +0000 (UTC) Date: Mon, 28 Jun 2021 09:50:15 -0400 From: Steven Rostedt To: Masami Hiramatsu Cc: LKML , Shuah Khan , Shuah Khan , Peter Zijlstra Subject: selftest/ftrace: Add test results to "-h" help text to ftracetest Message-ID: <20210628095015.4b8b1cb9@oasis.local.home> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Peter Zijlstra recently had to debug jump labels that were failing in the ftracetest script. He became frustrated as there was no easily available documentation on what the meanings of UNSUPPORTED and UNRESOLVED were. The only place they are documented is in the code. At the very least, add the results to the help text, as I find that I also sometimes need to figure out what those terms mean. Now "./ftracetest -h" produces: Usage: ftracetest [options] [testcase(s)] [testcase-directory(s)] Options: -h|--help Show help message -k|--keep Keep passed test logs -v|--verbose Increase verbosity of test messages -vv Alias of -v -v (Show all results in stdout) -vvv Alias of -v -v -v (Show all commands immediately) --fail-unsupported Treat UNSUPPORTED as a failure --fail-unresolved Treat UNRESOLVED as a failure -d|--debug Debug mode (trace all shell commands) -l|--logdir Save logs on the If is -, all logs output in console only Test results: PASS The test succeeded FAIL The test failed, but was expected to succeed. UNRESOLVED The test produced indeterminate results. (e.g. interrupted) UNTESTED The test was not run, currently just a placeholder. UNSUPPORTED The test failed because of lack of feature. XFAIL The test failed, and was expected to fail. Link: https://lore.kernel.org/lkml/YNmflj%2FWpFG5Ivmb@hirez.programming.kicks-ass.net/ Signed-off-by: Steven Rostedt (VMware) --- diff --git a/tools/testing/selftests/ftrace/ftracetest b/tools/testing/selftests/ftrace/ftracetest index 8ec1922e974e..f34580c70650 100755 --- a/tools/testing/selftests/ftrace/ftracetest +++ b/tools/testing/selftests/ftrace/ftracetest @@ -21,6 +21,14 @@ echo " --fail-unresolved Treat UNRESOLVED as a failure" echo " -d|--debug Debug mode (trace all shell commands)" echo " -l|--logdir Save logs on the " echo " If is -, all logs output in console only" +echo "" +echo " Test results:" +echo " PASS The test succeeded" +echo " FAIL The test failed, but was expected to succeed." +echo " UNRESOLVED The test produced indeterminate results. (e.g. interrupted)" +echo " UNTESTED The test was not run, currently just a placeholder." +echo " UNSUPPORTED The test failed because of lack of feature." +echo " XFAIL The test failed, and was expected to fail." exit $1 }