From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 13322A054F; Mon, 15 Mar 2021 11:31:54 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7134C24260B; Mon, 15 Mar 2021 11:31:53 +0100 (CET) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by mails.dpdk.org (Postfix) with ESMTP id 0F5834003C for ; Mon, 15 Mar 2021 11:31:51 +0100 (CET) IronPort-SDR: KTDgAWhB5Ee/kw1BRM7/vlB/9UDU06xBZ8BWp6uYFo7t6gLMLWHFhj7iDKHqNVj80daUr1kBCJ Pp7hK8PAb2ng== X-IronPort-AV: E=McAfee;i="6000,8403,9923"; a="189113369" X-IronPort-AV: E=Sophos;i="5.81,249,1610438400"; d="scan'208";a="189113369" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Mar 2021 03:31:50 -0700 IronPort-SDR: 5tEMngAzXBkoE0wdC5OnS+JTtIrJEAnldgjv6agiwjlqXgPQsvCOGY+0PKlcwbTJp25CdOLNIo Rj4ruY0HgOwQ== X-IronPort-AV: E=Sophos;i="5.81,249,1610438400"; d="scan'208";a="510982104" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.11.180]) by fmsmga001-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 15 Mar 2021 03:31:48 -0700 Date: Mon, 15 Mar 2021 10:31:44 +0000 From: Bruce Richardson To: "Kinsella, Ray" Cc: Thomas Monjalon , dev@dpdk.org, david.marchand@redhat.com, mb@smartsharesystems.com, Neil Horman Message-ID: <20210315103144.GC2040@bricha3-MOBL.ger.corp.intel.com> References: <20210309233116.1934666-1-thomas@monjalon.net> <20210312181720.242252-1-thomas@monjalon.net> <20210312181720.242252-8-thomas@monjalon.net> <44934eac-9808-ada4-fe97-7d24382bced4@ashroe.eu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <44934eac-9808-ada4-fe97-7d24382bced4@ashroe.eu> Subject: Re: [dpdk-dev] [PATCH v3 07/11] eal: add log level help X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, Mar 15, 2021 at 10:19:47AM +0000, Kinsella, Ray wrote: > > > On 12/03/2021 18:17, Thomas Monjalon wrote: > > The option --log-level was not completely described in the usage text, > > and it was difficult to guess the names of the log types and levels. > > > > A new value "help" is accepted after --log-level to give more details > > about the syntax and listing the log types and levels. > > > > The array "levels" used for level name parsing is replaced with > > a (modified) existing function which was used in rte_log_dump(). > > > > The new function rte_log_list_types() is exported in the API > > for allowing an application to give this info to the user > > if not exposing the EAL option --log-level. > > The list of log types cannot include all drivers if not linked in the > > application (shared object plugin case). > > > > Signed-off-by: Thomas Monjalon > > --- > > lib/librte_eal/common/eal_common_log.c | 24 +++++++++--- > > lib/librte_eal/common/eal_common_options.c | 44 +++++++++++++++------- > > lib/librte_eal/common/eal_log.h | 5 +++ > > lib/librte_eal/include/rte_log.h | 11 ++++++ > > lib/librte_eal/version.map | 3 ++ > > 5 files changed, 69 insertions(+), 18 deletions(-) > > > > @@ -1274,6 +1286,11 @@ eal_parse_log_level(const char *arg) > > char *str, *level; > > int priority; > > > > + if (strcmp(arg, "help") == 0) { > > So I think the convention is to support both "?" and "help". > Qemu does this at least. > I've seen "/?" used for help on windows binaries, but "-?" not so much in the linux world, where --help (and often -h for short) seem to be the standard.